GEThttp://api-conserver.onlinesim.io/stubs/handler_api.php?action=getRentNumber

Rent virtual number for receiving SMS

This request allows you to order a phone number for rent.

You might want to use this service when you need to receive SMS from multiple different sources (websites, applications, other mobile numbers) or when need to receive SMS from a single one on the same number, but over a longer time (for example over 7 days).

Security

OAuth2
rent-scope
grants access to renting phone numbers from Onlinesim

Parameters

query3
NameTypeDescription
action*string

Method name, in this case getRentNumber

Enum:getRentNumberDefault:getRentNumber
country*integer

Country ID (according to getRentServicesAndCountries response)

Default:0
timeinteger

Desired rental period in hours, which will be converted into days with a rounding-up upon order (e.g. 2h - 1 day, 25h - 2 days)

Default:24

Responses

200

Successful getRentNumber response from the server: either issues a number for rent with specified parameters or throws an exception.

Content-Typeapplication/json
Schema
schemaobject
statusstring

Operation status

Example:success
phoneobject

Virtual number object

Examples

Successfully issued number response example
{
  "status": "success",
  "phone": {
    "id": 22867858,
    "endDate": "2022-07-17T19:54:55+03:00",
    "number": "9912530000"
  }
}

Code Samples

Generating examples...