Initiate onboarding
curl --request POST \ --url https://welcome.ztlpay.io/onboarding \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "country": "SE", "organizationNumber": "5569994600", "redirectUrl": "https://example.org" }'Authorizations
Section titled “Authorizations”Request Body
Section titled “Request Body”object
Countrycode for the company being onboarded
Example
SEOrganization number for the company being onboarding
Example
5569994600The user is redirected to this URL after the onboarding process has completed as well as if they cancel the onboarding process. Normally this will be the URL of the ERP the end-user originated from. Must start with a protocol (HTTP/HTTPS).
Example
https://example.orgResponses
Section titled “Responses”Onboarding started successfully
object
Id for the started onboarding, used for status
Example
{ "id": "941d1877-73b8-45bf-8c65-47233b58926a", "url": "https://welcome.sandbox.ztlpay-test.io/onboarding/941d1877-73b8-45bf-8c65-47233b58926a"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Bad request
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Forbidden
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Not found
Conflict
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Additional context related to the error
object
The ID of the onboarding used to onboard the existing company.
This onboarding is always in status Accepted and cannot be modified.
onboardingId and additionalInformation can be null
when the original onboarding details are unavailable.
Example
{ "failure": "COMPANY_ALREADY_EXISTS", "ztlRequestId": "d188e4f9-91fa-4fd8-98be-e725dc44090a", "message": "A company with organization number 5569994600 already exists. Initiation of new onboardings is not permitted.", "additionalInformation": { "onboardingId": "9256411a-5c80-40e5-b50c-768dbca443af" }}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Internal server error
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9Service unavailable
object
Unique RequestId, please provide this Id in case of support requests
The underlying reason for the error
Example
{ "ztlRequestId": "3a797348-ef0c-4f52-b821-fdfcdb98c4d9", "message": "Invalid account"}Headers
Section titled “Headers”Unique RequestId, please provide this Id in case of support requests
Example
3a797348-ef0c-4f52-b821-fdfcdb98c4d9