post
https://{ourserver.com}/v1/PUSH_SMS_RENTWebhook POST /v1/PUSH_SMS_RENT
Send SMS to Onlinesim for rent operation
If you get a response with 200(OK) status, SMS can be marked in your database as successfully delivered (don't send message again).
If response is different from 200, then in 10 seconds another request
with the same context should be sent, unless it's NO_OPERATION or
BAD_SERVICE error.
Following responses with errors are possible:
NO_OPERATION/NO_OP- this error occurs when you try to push SMS for a number that has no active operation;BAD_SERVICE- this error occurs when you try to push SMS from a service that is banned by our server (banks, payment systems, etc.);IGNORED- this error occurs when you try to push SMS from a service that is differs from the one the client has ordered (only appears when filtration is done on our side);SERVICE_BAN- this error occurs when you try to push SMS from the service you've blacklisted (you can add services to the blacklist, it prevents users to order your numbers for these services)
Parameters
header2
| Name | Type | Description |
|---|---|---|
Authorization* | string | see more here |
Content-Type* | string |
Enum: application/json; charset=utf-8 |
Request Body
PUSH_SMS webhook: your server must send this request once an event is triggered (when the ordered number has received a message).
Content-Type
application/jsonSchema
Bodyobject
Bodyobject
smsIdintegerRequired
phoneFromstringRequired
phonestringRequired
textstringRequired
actionstringRequired
keystringRequired
servicestringRequired
Examples
Example payload of your server request (for rental number)
{
"smsId": 124980,
"phoneFrom": "instagram",
"phone": "4605028040",
"text": "784958 is your secret code",
"action": "PUSH_SMS",
"key": "apikey",
"service": "rent"
}Responses
200Onlinesim server response
Onlinesim server response
Content-Type
application/jsonSchema
Responseobject
Responseobject
statusstring
Examples
Onlinesim server response example for PUSH_SMS request (for rental number)
{
"status": "SUCCESS"
}When pushing SMS to a number that has no active operation
NO_OPWhen pushing SMS from a service that is banned by our server (banks, payment systems, etc.)
BAD_SERVICEWhen pushing SMS from a service that is differs from the one the client has ordered (only appears when filtration is done on our side)
IGNOREDWhen pushing SMS from a service you've added to the blacklist
SERVICE_BANWhen rate limit for PUSH_SMS_RENT requests is exceeded
TOO_MANY_ATTEMPTSCode Samples
Generating examples...