Repository navigation
feat(eventbrite): add Eventbrite integration - #233
Open
RishadAlam wants to merge 15 commits into
Open
RishadAlam wants to merge 15 commits into
RishadAlam wants to merge 15 commits into
Conversation
EventbriteController uses a bearer-token connection (the Eventbrite private token), runs the action, and serves the dropdown lists: organizations, venues, events, ticket classes, ticket groups, categories, subcategories and formats, following Eventbrite's continuation pagination. RecordApiHelper builds the mapped fields and the node settings and fires one Pro hook per action, then logs the response. Every Eventbrite action is Pro.
staticData lists the 34 Pro actions with their mapped fields, required selects and optional Utilities. IDs of the record an action changes are mapped fields; organization, venue, category, ticket group and discount event choices are fetched dropdowns; fixed lists are selects. The helpers load each dropdown from its route, pass the parent value (organization, category or event) it depends on, and check the required selects and mapped fields before the next step.
…components The connection step uses the shared bearer-token connection form and says where to find the private token. The Utilities list opens a select (single or multiple) for each optional setting of the chosen action.
…screens The layout renders the action's selects, field map and Utilities from staticData. Changing a parent select clears and reloads the selects that depend on it, and switching actions clears the previous action's settings. The edit screen reloads the dropdown labels of a saved integration.
Register the Eventbrite screens in the new, edit and info routes, add it to the action list as a Pro app, and add its logo and tutorial link entry.
When two fetched items share a name, such as two venues called the same in one city, add the item ID to their labels so the right one can be picked.
✅ WordPress Plugin Check Report
📊 ReportAll checks passed! No errors or warnings found. 🤖 Generated by WordPress Plugin Check Action • Learn more about Plugin Check |
Rebuild the 128px logo from Eventbrite's own brand mark (the logo-e-brand SVG on eventbrite.com, #FF5E30 on transparent) instead of the traced favicon. 2 KB.
Yes/no Utilities no longer open a Yes/No modal. Ticking the box stores the value and unticking removes it, so nothing is sent and Eventbrite keeps its default. Settings that Eventbrite turns on by default use the opposite label (Unlisted, Hide Map, Save as Draft, Add-on Tier, and so on) so a ticked box always changes something. Utilities with real choices (time zone, currency, locale, ...) keep their modal.
Eventbrite rejects event currencies outside its 25 supported codes (INR, BDT and others fail with "event.currency - INVALID"). The currency dropdown now lists only those 25.
Eventbrite answers "delivery_methods - INVALID" for standard_shipping and third_party_shipping on free and paid tickets alike. Only Electronic and Will call remain.
…tier Eventbrite treats capacity_total as quantity plus holds, so sending both with different values fails with "inventory_tier.quantity_total - INVALID". Update Inventory Tier now maps only the quantity.
It can only copy an existing seat map, and seat maps need Eventbrite's reserved seating, which none of the test accounts has.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds Eventbrite to Bit Integrations: 34 write actions covering events, recurring dates, event settings, ticket classes and groups, inventory tiers, order questions, discounts, venues, text overrides, seat maps and image uploads. Free holds the connection, the dropdown data and the screens; every call to Eventbrite happens in Pro. Pairs with Bit-Apps-Pro/bit-integrations-pro#155.
Motivation & Context
Ported from the Bit Flows (bit-pi) Eventbrite integration (Bit-Apps-Pro/bit-pi#865), following the SureContact and Flodesk shape for SaaS APIs: Free builds the
ApiClientfrom a bearer-token connection and hands it, with the node settings, to the Pro handler.Only write operations ship as actions; the read endpoints back the dropdowns instead. Eventbrite's triggers are external webhooks rather than WordPress hooks, so they are out of scope. The integration uses the Controller + RecordApiHelper shape because
mainhas noActionResolveryet.Type of Change
Key Changes
Backend
EventbriteControllerwith the bearer-token connection config, theApiClientfactory and eight dropdown fetchers (organizations, venues, events, ticket classes, ticket groups, categories, subcategories, formats) that follow Eventbrite's continuation pagination. Venues come from every organization when none is picked.RecordApiHelper, which builds the field data, flattens the node's dropdown values and Utilities into settings, fires one hook per action and logs every path throughLogHandler.Content-Type: application/json, because Eventbrite ignores the query string of a GET that carries one. Pro adds the header to non-GET requests.Frontend
staticData.js. Every action is pro-gated.Checklist
Testing
Driven in the browser against the live Eventbrite API with a real private token. Each of the 34 actions was configured in the edit screen, saved, and run by posting to a Webhook trigger with mapped fields. All succeed except Create Seat Map for Event, which was checked on its error path only because the test account has no seat map to copy.
Also checked in the browser: the new-integration wizard (connection, Create Event, save, run), the edit and info screens, the organization → event → ticket class dropdown chain, required-select validation, multi-select Utilities and saved-value reloading. Prettier and eslint pass on the new folder; PHP syntax, php-cs-fixer and the PHP 7.4 compatibility check pass.
NewInteg.jsx,IntegInfo.jsxandSelectAction.jsxalready fail prettier onmain, andEditInteg.jsxalready has an eslint error there; this PR only adds lines to them.Changelog
🤖 Generated with Claude Code