Create Onboarding Requisition

Creates an onboarding requisition whose form is filled in your application. The response carries the liveness link the end user must complete and the access token required by every other endpoint of this journey.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Endpoint

POST /v3/onboarding/form
📘

Your application renders the registration form. The only page the end user opens on our side is liveness_url.

Headers

ParameterTypeDescriptionRequired or OptionalExample
Content-TypeStringMedia type of the request body. Must be application/json.requiredapplication/json
🔑

This endpoint takes no authentication header. It returns an access_token that identifies the requisition. Every later call requires that value in the X-Onboarding-Token header.

Body Details

{
  "document_legal_id": "11222333000181",
  "email": "[email protected]",
  "onboarding_type": "PJ",
  "representative_document": "111.444.777-35",
  "whitelabel_sigla": "EXAMPLE"
}
FieldTypeDescriptionRequired or Optional
document_legal_idStringCPF (individual) or CNPJ (company) being onboarded. Between 11 and 14 characters. A masked value is accepted — dots, slashes and dashes are removed before processing — and the check digits are validated.required
emailStringContact email of the person or company being onboarded. Must be a valid email address; it is stored in lower case.required
onboarding_typeStringType of onboarding: PF for an individual (the document must be a valid CPF) or PJ for a company (the document must be a valid CNPJ).required
representative_documentStringCPF of the legal representative who will perform the liveness. Required for PJ. A masked value is accepted and the check digits are validated. Do not send it for PF.required for PJ / omit for PF
whitelabel_siglaStringCode of the white-label brand that runs the journey, up to 50 characters. The code must match an existing brand. When it is not sent, the default brand is used.optional

Request Examples

Individual (PF):

POST /v3/onboarding/form
Content-Type: application/json

{
  "document_legal_id": "123.456.789-09",
  "email": "[email protected]",
  "onboarding_type": "PF"
}

Company (PJ) with a white-label brand:

POST /v3/onboarding/form
Content-Type: application/json

{
  "document_legal_id": "11222333000181",
  "email": "[email protected]",
  "onboarding_type": "PJ",
  "representative_document": "111.444.777-35",
  "whitelabel_sigla": "EXAMPLE"
}

Response Details

Success Status Codes

HTTP CodeWhen it is returned
201A new onboarding requisition was created. The body carries the access_token.
200The document already has an onboarding in progress. The existing requisition is returned and the body carries no access_token — reuse the one you stored when the requisition was created.

201 Created:

{
  "worked": true,
  "onboarding_requisition_id": 12345,
  "onboarding_link": null,
  "liveness_url": "https://links.example.com/liveness/example_journey_id",
  "liveness_status": "PENDING",
  "access_token": "kJ3xQ9example_access_token_value",
  "status": "PENDING"
}

Document with an onboarding already in progress (200 OK):

{
  "worked": true,
  "onboarding_requisition_id": 12345,
  "onboarding_link": null,
  "liveness_url": "https://links.example.com/liveness/example_journey_id",
  "liveness_status": "PENDING",
  "access_token": null,
  "status": "IN_PROGRESS"
}
FieldTypeDescription
workedBooleanAlways true for successful requests.
onboarding_requisition_idIntegerUnique identifier of the onboarding requisition. Use it in the path of every other endpoint of this journey.
onboarding_linkStringAlways null. The only link the end user opens is liveness_url.
liveness_urlStringLink where the end user completes the proof of life. Only returned while liveness_status is PENDING.
liveness_statusStringStatus of the proof of life. PENDING right after creation. Possible values: PENDING, PASSED, FAILED.
access_tokenStringOpaque token of this requisition, returned only when the requisition is created. Send it in the X-Onboarding-Token header of every other endpoint. null when an existing requisition is returned with 200.
statusStringCurrent status of the requisition. PENDING on a newly created requisition. Possible values: PENDING, IN_PROGRESS, APPROVED, REPROVED, COMPLETED.

Requisition status (status):

ValueDescription
PENDINGThe requisition was created and the journey has not been analysed yet
IN_PROGRESSThe journey is being processed
APPROVEDThe journey was approved
REPROVEDThe journey was rejected
COMPLETEDThe journey is finished

Liveness status (liveness_status):

ValueDescription
PENDINGThe proof of life was opened and is waiting for the end user
PASSEDThe end user completed the proof of life successfully
FAILEDThe proof of life was not successful; a new attempt may be started

Error Responses

HTTP CodeError MessageDescription
400Seu cadastro está em análise interna.The document already has a registration that was approved by the journey and is waiting for the internal review. A new requisition cannot be created while the review is open.
400Cadastro aprovado. Sua conta está ativa.The document already has an approved registration and an active account, so a new onboarding is not needed.
400Não foi possível prosseguir com seu cadastro.The document is in a state that does not allow a new onboarding requisition.
400Documento já possui cadastro. Para atualização cadastral, use o fluxo de registration-update.The document already went through a registration update. Use the registration update flow instead of creating a new onboarding requisition.
400Whitelabel não encontrada para a sigla informada.The whitelabel_sigla sent does not match any existing white-label brand. Check the code with your account manager.
400No onboarding layout configured for type PJ_FORM.There is no active own-form layout for the onboarding_type sent. Confirm the type with your account manager.
422Validation errorRequest validation failed: invalid CPF or CNPJ (format, length or check digits), invalid email address, missing required field, a document_legal_id that does not match the onboarding_type, or — on PJ — a missing, empty or invalid representative_document.

Business Rules

Request Path:

  • Use POST /v3/onboarding/form to start the journey.

Document Validation:

  • document_legal_id must have between 11 and 14 characters after the mask is removed.
  • onboarding_type PF requires a valid CPF; onboarding_type PJ requires a valid CNPJ.
  • Check digits are validated. An invalid CPF or CNPJ is rejected with 422.
  • Masked documents are accepted (123.456.789-09, 11.222.333/0001-81) and normalised before processing.

Legal representative (PJ):

  • representative_document is required when onboarding_type is PJ. A missing, empty or invalid CPF is rejected with 422 (Invalid representative CPF).
  • Do not send the field for PF.
  • Masked values are accepted (111.444.777-35) and stored as digits only.
  • The partner is created at this step, with that CPF and is_legal_representative as true. That is the person who must complete the liveness — the CAF no longer reads an identity document to identify who is on camera.
  • When you later submit the form, the partner marked as legal representative must be this same CPF.

One Requisition per Document:

  • A document that already has an onboarding in progress does not create a second requisition: the existing one is returned with HTTP 200.
  • The 200 response does not repeat the access_token. Store the token from the 201 response — it is the only time it is returned.
  • A document whose previous onboarding was rejected can start a new requisition: a new 201 is returned, with a new access_token.
  • A document whose registration is already approved, or is waiting for the internal review, is refused with 400 and a message explaining the situation.
  • A document that already went through a registration update is refused with 400 and must use the registration update flow.

Access Token:

  • The access_token is returned once, when the requisition is created.
  • Store it together with the onboarding_requisition_id: it is required in the X-Onboarding-Token header of every other endpoint (status, form submission, liveness retry and liveness refresh).
  • A missing or wrong token answers 404 Onboarding requisition not found. on those endpoints — the requisition is never disclosed to a caller that cannot present its token.

Journey:

  • The response carries liveness_url and liveness_status: "PENDING". onboarding_link comes back null.
  • Send the end user to liveness_url and poll GET /v3/onboarding/{onboarding_requisition_id} until liveness_status becomes PASSED before submitting the form.
  • liveness_url is only available while the proof of life is pending. Once it is completed or fails, the link is no longer returned.
  • For a company (PJ) onboarding, the official registry data is looked up in the background right after creation and becomes available in the status endpoint, together with representative_document.

White-Label Brand:

  • whitelabel_sigla selects the brand that appears in the journey.
  • The code must match an existing brand, otherwise the request is refused with 400.
  • When the field is not sent, the default brand is used.
Body Params

CPF for individual onboarding or CNPJ for company onboarding. The mask is removed and the check digits are validated.

string
required

Contact email for the onboarding journey.

string
enum
required

PF for an individual, PJ for a company.

Allowed:
string | null

Brand code of the white-label experience used for this journey. Must match an existing brand.

string | null

CPF of the legal representative who will perform the liveness. Required for PJ. Do not send for PF. The mask is removed and the check digits are validated.

Responses

400

The document cannot start a new onboarding requisition

422

Validation error - a field is missing or has an invalid value

Language
LoadingLoading…
Response
Choose an example:
application/json