Create session

If you have an API username and API password you can create an enrolment token. This token will be used to identify your user.

Create a new enrolment session

The API currently supports basic authentication. All endpoints require an Authentication header in the following form:

Authorization: 'Basic ' + Base64.encode(username + ':' + password)

Send a HTTP POST request to:

  • /api/v1/enrolment/initialize

The following parameters are used for requests and responses:

ParameterDirectionDescription
sessionIdrequestunique, short-lived GUID to be generated by the client to track specific sessions
returnUrlrequestcustom page to be displayed by the client solution after completion of the onboarding process, usually the progress bar should be displayed waiting for one of the available verification results: HIGH, MEDIUM, LOW (meaning and expected workflow described in Trust Factors section)
externalIdrequestoptional text field (up to 512 characters) that can be used for filtering purposes later on. For example, it could be used to pass an external solution session ID or an external user ID.
accessTokenresponseJWT access token to be used in the enrolment process during Enrolment
sessionIdresponsethe same unique code sent in request, returned for the traceability
webEnrolmentUrlresponseredirection URL, i.e. next step of the onboarding, contains full URL including access token
Request:
{
  "sessionId": "ad90c821-e5ea-4385-be5b-4fc9f9ea24ee",
  "returnUrl": "{A url where end user will be redirected after enrolment}",
  "externalId": "53421526A"
}

Response:
{
  "accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzZXNzaW9uSWQiOiJhZDkwYzgyMS1lNWVhLTQzODUtYmU1Yi00ZmM5ZjllYTI0ZWU
  iLCJjdXN0b21lciI6IjEyZjUwMjM1LWFkNmYtNDVmNi1iOGM1LTE2ZGM1N2QwOTI1MyIsIm5iZiI6MTY0Mzk3NDMyMywiZXhwIjoxNjQzOTc3OTIzfQ.t5zU
  PHZjpo-q3Rl5ZibyKSaBXAdItuCRdTBMS2JW8gQ",
  "sessionId": "ad90c821-e5ea-4385-be5b-4fc9f9ea24ee"
 "webEnrolmentUrl": "https://<domain name>/web-enrolment/?token=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzZXNzaW9uSWQiOiJhZ
 DkwYzgyMS1lNWVhLTQzODUtYmU1Yi00ZmM5ZjllYTI0ZWU
 iLCJjdXN0b21lciI6IjEyZjUwMjM1LWFkNmYtNDVmNi1iOGM1LTE2ZGM1N2QwOTI1MyIsIm5iZiI6MTY0Mzk3NDMyMywiZXhwIjoxNjQzOTc3OTIzfQ.t5zU"
}

Example:
curl -X POST "
/api/v1/enrolment/initialize" -H "accept: text/plain" -H
"Authorization: Basic aW5ub3ZhdHJpY3M6aW5ub3ZhdHJpY3M=" -H "Content-Type: application/json" -d "{\"sessionId\":\"ad90c82
1-e5ea-4385-be5b-4fc9f9ea24ee\",\"returnUrl\":\"your url\"}"