Get Registration Flow
GEThttps://accounts.<domain>/auth/self-service/registration/flows
This endpoint returns a registration flow's context with, for example, error details and other information.
Browser flows expect the anti-CSRF cookie to be included in the request's HTTP Cookie Header. For AJAX requests you must ensure that cookies are included in the request or requests will fail.
If you use the browser-flow for server-side apps, the services need to run on a common top-level-domain and you need to forward the incoming HTTP Cookie header to this endpoint:
pseudo-code example
router.get('/registration', async function (req, res) {
const flow = await client.getRegistrationFlow(req.header('cookie'), req.query['flow'])
res.render('registration', flow)
})
This request may fail due to several reasons. The error.id
can be one of:
session_already_available
: The user is already signed in.
self_service_flow_expired
: The flow is expired and you should request a new one.
Request
Query Parameters
The Registration Flow ID
The value for this parameter comes from flow
URL Query parameter sent to your
application (e.g. /registration?flow=abcde
).
Header Parameters
HTTP Cookies
When using the SDK in a browser app, on the server side you must include the HTTP Cookie Header sent by the client to your server here. This ensures that CSRF and session cookies are respected.
Responses
- 200
- 403
- 404
- 410
- default
registrationFlow
- application/json
- Schema
- Example (from schema)
Schema
Possible values: [password
, totp
, oidc
, webauthn
, lookup_secret
, code
]
and so on.
ExpiresAt is the time (UTC) when the flow expires. If the user still wishes to log in, a new flow has to be initiated.
ID represents the flow's unique ID. When performing the registration flow, this
represents the id in the registration ui's query parameter: http://<selfservice.flows.registration.ui_url>/?flow=
IssuedAt is the time (UTC) when the flow occurred.
OAuth 2.0 Login Challenge.
This value is set using the login_challenge
query parameter of the registration and login endpoints.
If set will cooperate with OAuth2 and OpenID to act as an OAuth2 server / OpenID Provider.
oauth2_login_request object
RequestURL is the initial URL that was requested. It can be used to forward information contained in the URL's path or query for example.
ReturnTo contains the requested return_to URL.
SessionTokenExchangeCode holds the secret code that the client can use to retrieve a session token after the flow has been completed. This is only set if the client has requested a session token exchange code, and if the flow is of type "api", and only on creating the flow.
State represents the state of this request:
choose_method: ask the user to choose a method (e.g. registration with email) sent_email: the email has been sent to the user passed_challenge: the request was successful and the registration challenge was passed.
TransientPayload is used to pass data from the registration to a webhook
The flow type can either be api
or browser
.
ui objectrequired
{
"active": "password",
"expires_at": "2025-04-17T12:10:30.830Z",
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"issued_at": "2025-04-17T12:10:30.830Z",
"oauth2_login_challenge": "string",
"oauth2_login_request": {
"AdditionalProperties": {},
"challenge": "string",
"client": {
"AdditionalProperties": {},
"access_token_strategy": "string",
"allowed_cors_origins": [
"string"
],
"audience": [
"string"
],
"authorization_code_grant_access_token_lifespan": "string",
"authorization_code_grant_id_token_lifespan": "string",
"authorization_code_grant_refresh_token_lifespan": "string",
"backchannel_logout_session_required": true,
"backchannel_logout_uri": "string",
"client_credentials_grant_access_token_lifespan": "string",
"client_id": "string",
"client_name": "string",
"client_secret": "string",
"client_secret_expires_at": 0,
"client_uri": "string",
"contacts": [
"string"
],
"created_at": "2025-04-17T12:10:30.830Z",
"frontchannel_logout_session_required": true,
"frontchannel_logout_uri": "string",
"grant_types": [
"string"
],
"implicit_grant_access_token_lifespan": "string",
"implicit_grant_id_token_lifespan": "string",
"jwks_uri": "string",
"jwt_bearer_grant_access_token_lifespan": "string",
"logo_uri": "string",
"metadata": {},
"owner": "string",
"policy_uri": "string",
"post_logout_redirect_uris": [
"string"
],
"redirect_uris": [
"string"
],
"refresh_token_grant_access_token_lifespan": "string",
"refresh_token_grant_id_token_lifespan": "string",
"refresh_token_grant_refresh_token_lifespan": "string",
"registration_access_token": "string",
"registration_client_uri": "string",
"request_object_signing_alg": "string",
"request_uris": [
"string"
],
"response_types": [
"string"
],
"scope": "string",
"sector_identifier_uri": "string",
"skip_consent": true,
"subject_type": "string",
"token_endpoint_auth_method": "string",
"token_endpoint_auth_signing_alg": "string",
"tos_uri": "string",
"updated_at": "2025-04-17T12:10:30.830Z",
"userinfo_signed_response_alg": "string"
},
"oidc_context": {
"AdditionalProperties": {},
"acr_values": [
"string"
],
"display": "string",
"id_token_hint_claims": {},
"login_hint": "string",
"ui_locales": [
"string"
]
},
"request_url": "string",
"requested_access_token_audience": [
"string"
],
"requested_scope": [
"string"
],
"session_id": "string",
"skip": true,
"subject": "string"
},
"organization_id": "string",
"request_url": "string",
"return_to": "string",
"session_token_exchange_code": "string",
"transient_payload": {},
"type": "string",
"ui": {
"action": "string",
"messages": [
{
"context": {},
"id": 0,
"text": "string",
"type": "info"
}
],
"method": "string",
"nodes": [
{
"attributes": {},
"group": "default",
"messages": [
{
"context": {},
"id": 0,
"text": "string",
"type": "info"
}
],
"meta": {
"label": {
"context": {},
"id": 0,
"text": "string",
"type": "info"
}
},
"type": "text"
}
]
}
}
errorGeneric
- application/json
- Schema
- Example (from schema)
Schema
error objectrequired
{
"error": {
"code": 404,
"debug": "SQL field \"foo\" is not a bool.",
"details": {},
"id": "string",
"message": "The resource could not be found",
"reason": "User with ID 1234 does not exist.",
"request": "d7ef54b1-ec15-46e6-bccb-524b82c035e6",
"status": "Not Found"
}
}
errorGeneric
- application/json
- Schema
- Example (from schema)
Schema
error objectrequired
{
"error": {
"code": 404,
"debug": "SQL field \"foo\" is not a bool.",
"details": {},
"id": "string",
"message": "The resource could not be found",
"reason": "User with ID 1234 does not exist.",
"request": "d7ef54b1-ec15-46e6-bccb-524b82c035e6",
"status": "Not Found"
}
}
errorGeneric
- application/json
- Schema
- Example (from schema)
Schema
error objectrequired
{
"error": {
"code": 404,
"debug": "SQL field \"foo\" is not a bool.",
"details": {},
"id": "string",
"message": "The resource could not be found",
"reason": "User with ID 1234 does not exist.",
"request": "d7ef54b1-ec15-46e6-bccb-524b82c035e6",
"status": "Not Found"
}
}
errorGeneric
- application/json
- Schema
- Example (from schema)
Schema
error objectrequired
{
"error": {
"code": 404,
"debug": "SQL field \"foo\" is not a bool.",
"details": {},
"id": "string",
"message": "The resource could not be found",
"reason": "User with ID 1234 does not exist.",
"request": "d7ef54b1-ec15-46e6-bccb-524b82c035e6",
"status": "Not Found"
}
}
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X GET 'https://accounts.<domain>/auth/self-service/registration/flows' \
-H 'Accept: application/json'