Skip to main content

Responses

Encyption and Decryption

1Kosmos's API responses are encrypted using Elliptic Curve Digital Signature Agorithm (ECDSA) to ensure secure data transmission.

ID Verification Responses

The response displays the generated session URL in the encrypted format. After the document verification API execution is successful, click the Visualization tab in the response to view the result in the decrypted format. Otherwise, you can use your own helper that is compatible with ECDSA to view the result in the decrypted format.

Create Session API

This API is used to create a session for a specific document type. You can generate a session with one of the supported documents.

  • idcard
  • driving license
  • passport

The response is displayed in the decrypted format:

Sample Success Response

note

If you pass an incorrect dvcID to your request body, you would encounter the 404 Not Found error. The following screenshot illustrates the same:

Scenario1: Incorrect dvcID

If you fail to pass the dvcID to your request body, you would encounter the 400 Bad Request error. The following screenshot illustrates the same:

Scenario 2: dvcID is blank

ID Verification Status

1Kosmos's ID Verification has the following types of statuses:

  • Session Status
    • Pending
    • In Progress
    • Completed
    • Expired
    • Declined
  • Verification Status
    • Failed
    • Passed
    • Not performed

The table below outlines the scenarios in which each session status is shown:

When athe session status will be
Session has been created for a user and has not yet started the verification processPending
User clicks on the consent check box and hit “Let’s get started”In Progress
User submits the document and gives selfie (if session is configured for selfie)Completed
Session has expiredExpired
User click the Decline button on the Welcome screenDeclined

Poll API

The /result API displays the complete session details along with the verification status in encrypted format. To view the results in the decrypted format, click the Visualization tab in the response section when you run this API in your postman. Otherwise, you can use your own helper that is compatible with ECDSA to view the result in the decrypted format.

The following section outlines the various verification statuses:

Sample Encrypted Response

Sample Decrypted Response

Decrypted Response parameters

The following parameters are returned in the response:

ParameterTypeDescription
sessionResultstringStatus of the verification result. Displays the status as In Progress.
sessionIDstringsession ID.