post
{yourserver}/getServicesPOST /getServices
Get list of available services and countries
This request is sent from Onlinesim server to yours every minute to get a quantity of available numbers. Your server should return a relevant list of available numbers in format described below.
Your partner's API key will be passed in the request in a payload.
Parameters
header1
| Name | Type | Description |
|---|---|---|
Authorization* | string | see more here |
Request Body
Request payload from Onlinesim server
Content-Type
application/jsonSchema
Bodyobject
Bodyobject
actionstringRequired
keystringRequired
Examples
Example payload of Onlinesim server GET_SERVICES request
{
"action": "GET_SERVICES",
"key": "apikey"
}Responses
200The response of your server for GET_SERVICES request must be in
following format:
The response of your server for GET_SERVICES request must be in
following format:
Content-Type
application/jsonHeaders
| Name | Type | Description |
|---|---|---|
Content-Type | string |
|
Schema
Responseobject
Responseobject
countryListobject[]Required
countryListobject[]Required
itemsobject
itemsobject
countrystringRequired
operatorMapobjectRequired
operatorMapobjectRequired
anyobjectRequired
anyobjectRequired
[additionalProperties]integer
[additionalProperties]object
[additionalProperties]object
[additionalProperties]integer
statusstringRequired
Examples
Response example from your server
{
"countryList": [
{
"country": "russia",
"operatorMap": {
"any": {
"vk": 10,
"ok": 25,
"wa": 52
},
"beeline": {
"vk": 10,
"ok": 15,
"wa": 20
},
"megafon": {
"vk": 0,
"ok": 10,
"wa": 32
}
}
},
{
"country": "ukraine",
"operatorMap": {
"any": {
"vk": 10,
"ok": 50,
"wa": 132
},
"life": {
"vk": 0,
"ok": 10,
"wa": 32
},
"vodafone": {
"vk": 10,
"ok": 10,
"wa": 0
},
"kyivstar": {
"vk": 0,
"ok": 30,
"wa": 100
}
}
}
],
"status": "SUCCESS"
}Code Samples
Generating examples...