n8n flows
New Brand Onboarding
End-to-end provisioning of a new brand: credentials, warehouses, vendors, webhooks, users, and initial pulls.
The onboarding orchestrator. It provisions a new brand (account) end-to-end: it stores the brand and its ShipHero credentials, imports warehouses and vendors, registers ShipHero webhooks, invites portal users, and kicks off the initial SKU and historical-shipment pulls.
At a glance
- Status: Active
- Trigger: Webhook (
New Brand Attempt,POST /webhook/create-new-brand), answered by a Respond-to-Webhook node. - Runs on: A new-brand submission from the portal's create-connection wizard.
- Talks to: Supabase (Brands, warehouses, vendors, userRoles and junction tables); ShipHero (credential vault, warehouse/vendor lookups, webhook registration); three sibling n8n workflows over HTTP.
How it works
- The webhook payload is validated and normalized.
- ShipHero credentials are stored in the vault, then
Add New Brand Recordinserts the brand. - Warehouses are fetched from ShipHero and looped to create warehouse and brand-to-warehouse records.
- Vendors are fetched and looped similarly, creating the vendor or adding the brand to an existing one.
- ShipHero GraphQL webhooks are registered for shipments and purchase orders.
- A
userRolerow is created and the flow calls the Invite Users workflow. - It triggers Pull Brand SKUs and starts a historical-shipment backfill, then returns OK or a structured error keyed by failure point.
Notes
- Orchestrator that fans out to multiple downstream scenarios, sequenced with a
Waitnode. - Includes a
(TEST) Delete Brand Recordcleanup node. - Shared
error-handlerset as the error workflow.