Embedded Sign-Up Flow (V1)
Cloud has the newest features. Some may not be in a release yet; the newest release is Identity & Access Management 7.3.0.
executeEmbeddedSignUpFlow drives a step-by-step registration flow without a browser redirect.
note
For new integrations, prefer executeEmbeddedSignUpFlowV2.
executeEmbeddedSignUpFlow(config)
Execute a step in the embedded registration flow.
import { executeEmbeddedSignUpFlow, EmbeddedFlowType } from '@thunderid/javascript'
const response = await executeEmbeddedSignUpFlow({
baseUrl: 'https://<DATA_PLANE_URL>',
payload: {
flowType: EmbeddedFlowType.Registration,
// step-specific fields
},
})
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
config.url | string | ✅ | Full endpoint URL. Mutually exclusive with baseUrl |
config.baseUrl | string | ✅ | Choreo Identity & Access Management base URL |
config.payload | EmbeddedFlowExecuteRequestPayload | ✅ | Flow step payload |
config.payload.flowType | EmbeddedFlowType | ✅ | Must be EmbeddedFlowType.Registration |
config.payload.flowId | string | ❌ | Flow ID from a previous step response |
config.payload.selectedAuthenticator | object | ❌ | Authenticator selection (for later steps) |
Response: EmbeddedFlowExecuteResponse
| Property | Type | Description |
|---|---|---|
flowId | string | Flow identifier |
flowStatus | EmbeddedFlowStatus | Incomplete or Complete |
type | EmbeddedFlowResponseType | View (render UI) or Redirection |
data | EmbeddedFlowComponent[] | UI component tree to render for the current step |
Enums
EmbeddedFlowType
| Value | Description |
|---|---|
Authentication | Sign-in flow |
Registration | Sign-up flow |
Recovery | Account recovery flow |
UserOnboarding | Post-sign-in onboarding flow |
EmbeddedFlowStatus
| Value | Description |
|---|---|
Incomplete | More steps required |
Complete | Flow has finished |
EmbeddedFlowResponseType
| Value | Description |
|---|---|
View | The data field contains a component tree to render |
Redirection | The user should be redirected to data.redirectUrl |
EmbeddedFlowComponentType
| Value | Description |
|---|---|
Button | Interactive button |
Checkbox | Checkbox input |
Divider | Visual divider |
Form | Form container |
Image | Image element |
Input | Text/password/email input |
Radio | Radio button |
Select | Dropdown select |
Typography | Display text |
Error Response
When a flow step fails, the function throws with an EmbeddedFlowExecuteErrorResponse:
| Property | Type | Description |
|---|---|---|
code | string | Error code |
message | string | Short error message |
description | string | Detailed error description |
flowType | EmbeddedFlowType | The flow type that failed |
Was this page helpful?