Start new verification requests and report on existing verification requests.
Start verification
This method is used by the mobile and web Verification SDKs to start a verification. It can also be used to request a verification from your backend, by making an request.
Request
Security:
Basic
Request Body schema: application/json
required
object (Identity)
Specifies the type of endpoint that will be verified and the particular endpoint. number is currently the only supported endpoint type.
method
required
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.
reference
string
Used to pass your own reference in the request for tracking purposes.
custom
string
Can be used to pass custom data in the request.
object
An optional object for flashCall verifications. It allows you to specify dial time out parameter for flashCall. FlashCallOptions object can be specified optionally, and only if the verification request was triggered from your backend (no SDK client) through an Application signed request.
Responses
200
A successful response.
Response Schema: application/json
One of:
id
required
string
Verification identifier used to query for status.
required
object
The response contains the template of the SMS to be expected and intercepted.
400
INVALID_ARGUMENT
post/verification/v1/verifications
Request samples
Payload
Node.js
C#
Java
Python
curl
application/json
{
"identity": {
"type": "number",
"endpoint": "+46700000000"
},
"method": "sms"
}
Response samples
200
400
application/json
{
"id": "1234567890",
"sms": {
"template": "Your verfication code is {{CODE}}"
}
}
Report back on a started verification
Verify verification code by Identity. After the SMS or flashcall is received (and intercepted, in the case of Android), the client needs to report to the Sinch Verification service either the PIN (for SMS) or CLI (for flashCall).
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.
Request Body schema: application/json
One of:
method
required
string
The type of verification.
required
object
Contains information about the SMS verification.
Responses
200
A successful 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.
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.