SIM Verification

Common objects & errors

Every SIM Verification response carries the same errors array alongside data, and every call fails the same way at the transport layer — both defined once here and referred to by name from each endpoint page.

Error envelope

When data.status is "failure", errors tells you why the request failed. In case of any other errors, data is empty and errors carries the code the server sent alongside the HTTP status.

JSON
{
    "errors": [
            {
                "code": string,
                "message": string,
                "detail": {
                    "field": string, // optional, which parameter is invalid.
                    ... // any other information that can be useful for client
                },
            },
            ... // other errors
        ]
}

Each entry contains:

NameTypeDescription
codestringwhich error occurred — see Shared transport errors, or the failure codes on the endpoint's own page
messagestringthe message that accompanies the code
detailjson_objectfield is optional and says which parameter is invalid, plus any other information that can be useful for client

Shared transport errors

In case of any other errors, the data field will be empty, and the server sends one of the following HTTP status codes with an error code. These are the same on every SIM Verification call.

HTTP codeerror codedescription
401access_denied_exceptionYou are not authorized to perform the action.
400invalid_parameter_exceptionInput parameter violates a constraint.
400request_time_too_skewedThe X-TV-Timestamp header is expired, need a newer one.
408request_timeout_exceptionRequest takes too long to process
429rate_limit_exceptionThe number of requests exceeded your throughput limit.
500internal_server_errorSome unexpected error occurs while processing the request

A code that arrives with HTTP 200 and data.status: "failure" belongs to the endpoint that returned it, and is documented under Failure codes on that endpoint's own page.