Results

AI Tools

This section provides details on how to retrieve session results for an Age verification session. Two options are available:

Good to know

Webhook notifications should be subscribed as the result API may not always return an immediate result for the doc scan method.

Fetching the session status

GET https://age.yoti.com/api/v1/sessions/<session-id>/result

Header

Description

Authorization

API Key to call the Yoti Age API. Should be sent as a Bearer {{API_TOKEN}} .

Content-Type

application/json

Yoti-SDK-Id

Your unique Yoti-Sdk-Id (uuid)Authorization

Response

{ "sdk_id": "<uuid>", "callback_url": "https://your.callback.url", "callback": { "url": "https://your.callback.url", "auto": false }, "notification_url": "https://your.webhook.url", "cancel_url": "https://your.cancel.url", "type": "OVER", "age_estimation": { "threshold": 25, "allowed": false, "level": "PASSIVE" }, "digital_id": { "threshold": 19, "allowed": false }, "doc_scan": { "threshold": 18, "allowed": true, "level": "PASSIVE" }, "credit_card": { "threshold": 18, "allowed": false }, "mobile": { "threshold": 18, "allowed": false }, "age": 18, "status": "COMPLETE", "method": "DOC_SCAN", "reference_id": "", "created_at": "2021-04-28T14:44:00.263517Z", "expires_at": "2030-10-30T20:04:00.263517Z", "updated_at": "2021-04-28T14:44:36.056933Z", "id": "<uuid>", "evidence_id": "<uuid>", "biometric_consent_required": true }
{ "sdk_id": "<uuid>", "callback_url": "https://your.callback.url", "notification_url": "https://your.webhook.url", "type": "OVER", "age_estimation": { "threshold": 25, "allowed": true, "level": "PASSIVE", "authenticity": "NOT_APPLICABLE" }, "digital_id": { "threshold": 18, "allowed": true }, "doc_scan": { "threshold": 18, "allowed": true, "level": "PASSIVE", "authenticity": "AUTO" }, "status": "PENDING", "reference_id": "", "created_at": "2021-05-20T15:53:22.173259Z", "expires_at": "2030-11-21T21:13:22.173259Z", "updated_at": "2021-05-20T15:53:22.173259Z", "id": "affa597b-84fd-4481-a6c0-d3c30c43155e", "biometric_consent_required": true }

Field

Value

Description

sdk_id

uuid

SDK ID for a given session.

notification_url

string

Configured notification_url property in session creation.

type

AGE / OVER / UNDER

Configured type property in session creation.

age_estimation

object

Configured age_estimation properties in session creation.

age

integer

Returns the actual age if type AGE. Otherwise returns the threshold value.

status

PENDING

IN_PROGRESS

FAIL

COMPLETE

ERROR

CANCELLED

PENDING - User has not started any checks.

IN_PROGRESS - Checks have begun on the session, awaiting result to be returned.

FAIL - The session has been completed, however the user has failed to meet the age threshold. FAIL will be returned only for 'OVER' and 'UNDER' attempts.

COMPLETE - The session has been completed, the user has passed the required threshold or an age has been returned.

ERROR - We could not provide an age result or calculate the threshold. This may be because the face was not recognised during age estimation or if the ID document was processed via Doc Scan, but we do not believe that it is a genuine document.

CANCELLED - The user no longer wishes to prove their age, and aborts the session.

Additional states may be added in future releases and therefore mapping methods should contain default values.

method

string

The AV method used to complete the session.

reference_id

string

Configured reference_id property in session creation.

created_at

timestamp

Timestamp of session creation.

expires_at

timestamp

Timestamp of session expiry.

updated_at

timestamp

Timestamp of last session update.

id

uuid

ID of session.

evidence_id

uuid

An ID relating to a specific Age verification attempt.

biometric_consent_required

boolean

Configured whether biometric consent is required in the session.