A callback URL is used to subscribe to events that occur. When an event occurs, a trigger is sent to the callback URL.

Event types

Supported event types:

TypeDescription
numberVerify.stateThe number verify transaction has been updated.

Subscribe to events

To subscribe to the events you need to provide the callbackUrl in the Number Verify request.

Retrieve status callback

The following information is sent when the state of the number verification request changes.

Request headers

Authorization: HMAC MIi9ZMyar2v+o7H7LD7oNolO5LrTJaC+8uKvYUGqJvM=
Content-Type: application/json

The callback request is signed, allowing you to verify the authenticity and integrity of the request. The signature is calculated using HMAC-SHA256, with the request body as the message and the client secret as the secret key. The signature is added to the Authorization header, and can be verified by repeating this step and comparing the value.

Request body

{
    "id": "58128784-9e8d-4424-a89d-08bfe273381c",
    "type": "numberVerify.state",
    "numberVerify": {
        "id": "0662f56b-13e0-4b64-b7ed-7ca75516fb85",
        "state": "completed",
        "match": true
    },
    "created": "2024-01-01T00:00:00+00:00"
}

Response

The status code should be in the 2xx range (between 200 and 300), the response body doesn't matter as it's ignored. In case of status code 5xx, the callback will be retried several times.