Number status
Check a previously used number for the same service.
Authentication
| Name | Location | Type | Required | Description |
|---|---|---|---|---|
apikey | header | string | Yes | Your API key |
Parameters
| Name | Location | Type | Required | Description |
|---|---|---|---|---|
number | path | string | Yes | Phone number without country phone code. (pattern: "^[0-9]{5,}$") |
service | path | string | Yes | Service code. To see all service codes please refer to servicesprices method. |
No request body is required.
How to use this method
Check whether a previously used number can still receive SMS for the same service. This check applies only if you have already received SMS on that number for that service. Send number without its country phone code.
Request examples
Runtime requirements and environment setup. cURL uses a POSIX shell. JavaScript and TypeScript run in Node.js. Java uses the standard HTTP client and prints raw JSON; use your application’s JSON library to inspect the body.
SMSPVA_NUMBER: number (required).
: "${SMSPVA_API_KEY:?Set SMSPVA_API_KEY}"
: "${SMSPVA_NUMBER:?Set SMSPVA_NUMBER to your number}"
curl --fail-with-body --max-time 30 --request GET \
--url "https://api.smspva.com/activation/numberstatus/${SMSPVA_NUMBER}/opt0" \
--header "apikey: $SMSPVA_API_KEY"Responses
The examples below show the response format. Prices, stock and account values are sample data; use the API response for current values.
| HTTP | Description |
|---|---|
| 200 | Successful operation |
| 405 | Invalid number format |
| 406 | Order ID format is invalid or not found |
| 500 | Internal server error. The description may include diagnostic details. |
| 501 | Server failed to process request. |
| 502 | Number not found. |
| 503 | The server is overloaded and experiencing performance issues. Please try later. |
| 504 | av2.resp.504.desc — the source does not provide a resolved description for this response. |
HTTP 200
Successful operation
Illustrative response
{
"statusCode": 200,
"data": {
"number": "98765432",
"orderId": 123456,
"countryCode": "+7"
}
}Response fields
| Name | Type | Description |
|---|---|---|
statusCode | integer | Result status code |
data | object | Response data |
data.number | string | Phone number without country phone code. |
data.orderId | integer | ID of your previous order for this number and service. |
data.countryCode | string | Country phone number code. |
HTTP 405
Invalid number format
Illustrative response
{
"statusCode": 405,
"error": {
"type": "INVALID_NUMBER_FORMAT",
"description": "Number should be integer with more than 5 digits"
}
}Response fields
| Name | Type | Description |
|---|---|---|
statusCode | integer | Result status code |
error | object | Response data |
error.type | string | Error type |
error.description | string | Error description |
HTTP 406
Order ID format is invalid or not found
Illustrative response
{
"statusCode": 406,
"error": {
"type": "ORDER_NOT_FOUND",
"description": "Order not found."
}
}Response fields
| Name | Type | Description |
|---|---|---|
statusCode | integer | Result status code |
error | object | Error data |
error.type | string | Error type |
error.description | string | Error description |
HTTP 500
Internal server error. The description may include diagnostic details.
Illustrative response
{
"statusCode": 500,
"error": {
"type": "SERVER_ERROR",
"description": "An internal error has occurred while processing your request."
}
}Response fields
| Name | Type | Description |
|---|---|---|
statusCode | integer | |
error | object | |
error.type | string | |
error.description | string |
HTTP 501
Server failed to process request.
HTTP 502
Number not found.
HTTP 503
The server is overloaded and experiencing performance issues. Please try later.
HTTP 504
av2.resp.504.desc — the source does not provide a resolved description for this response.
Related guides
If a connection fails during an order-changing request, check the order before trying again.