# Direct SDK Onboarding

Canonical: https://docs.bluehola.com/docs/onboarding/provider-onboarding
OpenAPI: https://docs.bluehola.com/openapi.yaml

# Direct SDK Onboarding

Use this route when your own Meta SDK page has already obtained the customer’s authorization result. Read the SDK settings from [`GET /v1/onboarding/config`](get-v1-onboarding-config.md). Your backend may submit the result with a customer API Key and `onboarding:write`, identifying the ownership target by **exactly one** of `customerEntityId` (recommended) or `portfolioId`. An authorized portal session remains supported.

Passing `customerEntityId` needs no Business Portfolio in advance: after authorization, the Portfolio is found or created from the WABA owner. To use that same ownership model on the hosted page, [create an invitation](post-v1-onboarding-invitations.md) with `customerEntityId`; that page submits the result automatically.

An onboarding run is a **persisted, resumable** state machine with five fixed steps: `exchange_token` → `subscribe_app` → `register_phone` → `sync_resources` → `persist_assets`.

| Endpoint | Purpose |
| --- | --- |
| [Complete Onboarding](post-v1-onboarding-embedded-signup.md) | Submit `customerEntityId` or `portfolioId` (exactly one), plus `code`, `wabaId` and optional `phoneNumberId`. Returns HTTP 201; inspect the operation status. |
| [List Recent Operations](get-v1-onboarding-embedded-signup.md) | List recent onboarding operations and their status. |
| [Operation Details](get-v1-onboarding-embedded-signup-operationid.md) | The five-step progress, errors and provisioned assets for a single operation. |
| [Resume from Failed Step](post-v1-onboarding-embedded-signup-operationid-retry.md) | Resume from where it stopped. `code` is optional: omit it if the old credential is still valid. |
| [Report ES Session Event](post-v1-onboarding-es-events.md) | Report a session event from inside the Embedded Signup popup, to help diagnose where a customer got stuck. |

:::warning

After a failure, call retry to **resume the same operation** — do not POST to the create endpoint again, which would create a brand-new operation. An operation that completed without registering a phone number at the time can also use retry to run just that registration step later.

:::

For how to choose between the two onboarding routes and what each of the five steps does, see [Customer Onboarding](../guides/customer-onboarding.md).
