Download OpenAPI specification:Download

Verification queries

Query existing verification requests.

Get verification by ID

Queries the verification result by sending the verification ID. With this query you can get the result of a verification.

Request
Security:
Basic
path Parameters
id
required
string

The ID of the verification.

Responses
200

A sucessful response.

Response Schema: application/json
id
string

Verification identifier used to query for status.

method
string (VerificationMethod)

The type of the verification request.

Enum: Description
sms

Verification by SMS message with a PIN code.

flashCall

Verification by placing a flashcall (missed call) and detecting the incoming calling number (CLI).

callout

Verification by placing a PSTN call to the user's phone and playing an announcement, asking the user to press a particular digit to verify the phone number (only iOS).

seamless

Data verification. Verification by accessing internal infrastructure of mobile carriers to verify if given verification attempt was originated from device with matching phone number.

status
string

The status of the verification request.

Enum: Description
PENDING

The verification is ongoing.

SUCCESSFUL

The verification was successful.

FAIL

The verification attempt was made, but the number wasn't verified.

DENIED

The verification attempt was denied by Sinch or your backend.

ABORTED

The verification attempt was aborted by requesting a new verification.

ERROR

The verification couldn't be completed due to a network error or the number being unreachable.

reason
string

Displays the reason why a verification has FAILED, was DENIED, or was ABORTED.

Enum: "“Fraud”" "Not enough credit" "Blocked" "Denied by callback" "Invalid callback" "Internal error" "Destination denied" "Network error or number unreachable" "Failed pending" "SMS delivery failure" "Invalid CLI" "Invalid code" "Expired" "Hung up without entering valid code"
reference
string

The reference ID that was optionally passed together with the verification request.

source
string

Free text that the client is sending, used to show if the call/SMS was intercepted or not.

Enum: "intercepted" "manual"
400

INVALID_ARGUMENT

get/verification/v1/verifications/id/{id}
Request samples
import fetch from 'node-fetch';

async function run() {
  const id = 'YOUR_id_PARAMETER';
  const resp = await fetch(
    `https://verificationapi-v1.sinch.com/verification/v1/verifications/id/${id}`,
    {
      method: 'GET',
      headers: {
        Authorization: 'Basic ' + Buffer.from('<username>:<password>').toString('base64')
      }
    }
  );

  const data = await resp.text();
  console.log(data);
}

run();
Response samples
application/json
{
  • "id": "1234567890",
  • "method": "sms",
  • "status": "FAIL",
  • "reason": "“Fraud”",
  • "reference": "12345",
  • "source": "intercept"
}

Get verification by Identity

Queries the verification result by sending the verification Identity and its method. With this query you can get the result of a verification.

Request
Security:
Basic
path Parameters
type
required
string

Currently only number type is supported.

endpoint
required
string

For type number use a E.164-compatible phone number.

method
required
string

The method of the verification.

Responses
200

A sucessful response.

Response Schema: application/json
id
string

Verification identifier used to query for status.

method
string (VerificationMethod)

The type of the verification request.

Enum: Description
sms

Verification by SMS message with a PIN code.

flashCall

Verification by placing a flashcall (missed call) and detecting the incoming calling number (CLI).

callout

Verification by placing a PSTN call to the user's phone and playing an announcement, asking the user to press a particular digit to verify the phone number (only iOS).

seamless

Data verification. Verification by accessing internal infrastructure of mobile carriers to verify if given verification attempt was originated from device with matching phone number.

status
string

The status of the verification request.

Enum: Description
PENDING

The verification is ongoing.

SUCCESSFUL

The verification was successful.

FAIL

The verification attempt was made, but the number wasn't verified.

DENIED

The verification attempt was denied by Sinch or your backend.

ABORTED

The verification attempt was aborted by requesting a new verification.

ERROR

The verification couldn't be completed due to a network error or the number being unreachable.

reason
string

Displays the reason why a verification has FAILED, was DENIED, or was ABORTED.

Enum: "“Fraud”" "Not enough credit" "Blocked" "Denied by callback" "Invalid callback" "Internal error" "Destination denied" "Network error or number unreachable" "Failed pending" "SMS delivery failure" "Invalid CLI" "Invalid code" "Expired" "Hung up without entering valid code"
reference
string

The reference ID that was optionally passed together with the verification request.

source
string

Free text that the client is sending, used to show if the call/SMS was intercepted or not.

Enum: "intercepted" "manual"
400

INVALID_ARGUMENT

get/verification/v1/verifications/{method}/{type}/{endpoint}
Request samples
import fetch from 'node-fetch';

async function run() {
  const type = 'YOUR_type_PARAMETER';
  const endpoint = 'YOUR_endpoint_PARAMETER';
  const method = 'YOUR_method_PARAMETER';
  const resp = await fetch(
    `https://verificationapi-v1.sinch.com/verification/v1/verifications/${method}/${type}/${endpoint}`,
    {
      method: 'GET',
      headers: {
        Authorization: 'Basic ' + Buffer.from('<username>:<password>').toString('base64')
      }
    }
  );

  const data = await resp.text();
  console.log(data);
}

run();
Response samples
application/json
{
  • "id": "1234567890",
  • "method": "sms",
  • "status": "FAIL",
  • "reason": "“Fraud”",
  • "reference": "12345",
  • "source": "intercept"
}

Get verification by Reference

Queries the verification result by sending the verification Reference. With this query you can get the result of a verification.

Request
Security:
Basic
path Parameters
reference
required
string

The custom reference of the verification.

Responses
200

A sucessful response.

Response Schema: application/json
id
string

Verification identifier used to query for status.

method
string (VerificationMethod)

The type of the verification request.

Enum: Description
sms

Verification by SMS message with a PIN code.

flashCall

Verification by placing a flashcall (missed call) and detecting the incoming calling number (CLI).

callout

Verification by placing a PSTN call to the user's phone and playing an announcement, asking the user to press a particular digit to verify the phone number (only iOS).

seamless

Data verification. Verification by accessing internal infrastructure of mobile carriers to verify if given verification attempt was originated from device with matching phone number.

status
string

The status of the verification request.

Enum: Description
PENDING

The verification is ongoing.

SUCCESSFUL

The verification was successful.

FAIL

The verification attempt was made, but the number wasn't verified.

DENIED

The verification attempt was denied by Sinch or your backend.

ABORTED

The verification attempt was aborted by requesting a new verification.

ERROR

The verification couldn't be completed due to a network error or the number being unreachable.

reason
string

Displays the reason why a verification has FAILED, was DENIED, or was ABORTED.

Enum: "“Fraud”" "Not enough credit" "Blocked" "Denied by callback" "Invalid callback" "Internal error" "Destination denied" "Network error or number unreachable" "Failed pending" "SMS delivery failure" "Invalid CLI" "Invalid code" "Expired" "Hung up without entering valid code"
reference
string

The reference ID that was optionally passed together with the verification request.

source
string

Free text that the client is sending, used to show if the call/SMS was intercepted or not.

Enum: "intercepted" "manual"
400

INVALID_ARGUMENT

get/verification/v1/verifications/reference/{reference}
Request samples
import fetch from 'node-fetch';

async function run() {
  const reference = 'YOUR_reference_PARAMETER';
  const resp = await fetch(
    `https://verificationapi-v1.sinch.com/verification/v1/verifications/reference/${reference}`,
    {
      method: 'GET',
      headers: {
        Authorization: 'Basic ' + Buffer.from('<username>:<password>').toString('base64')
      }
    }
  );

  const data = await resp.text();
  console.log(data);
}

run();
Response samples
application/json
{
  • "id": "1234567890",
  • "method": "sms",
  • "status": "FAIL",
  • "reason": "“Fraud”",
  • "reference": "12345",
  • "source": "intercept"
}