Below, please find the endpoints and examples:
Purchase Telephone Numbers:
Endpoint:
Method:
GET
Parameters:
AreaCode: Any valid Area Code
Example: 212, 315, 949, etc.
Quantity: The Quantity desired.
Example: 1, 2, 3, etc.
RoutingContainer: The inbound routing container you would like the calls to this number to go to. You may find your routing containers here - https://app.smartcarrier.io/calls/inbound/settings
Example: 1234
Geoproximation: This is an optional parameter and will search neighboring area codes in the event a number is not available in the area codes requested.
Example: 0 or false or 1 or true.
Headers:
x-api-key: Your API key.
Sample Request without Geoproximation: https://api.smartcarrier.io/v2/purchase-numbers?AreaCode=212&Quantity=1&RoutingContainer=1234
Sample Request with Geoproximation: https://api.smartcarrier.io/v2/purchase-numbers?AreaCode=212&Quantity=1&RoutingContainer=1234&Geoproximation=1
Response:
What do the response values mean?
ProviderGuid: a unique identifier assigned to the telephone number's carrier network.
AccountGuid: the account's unique identifier.
LergInformation: Details with respect to the from number's rate center.
AreaCodeRequested: The area code requested.
Quantity: The number of telephone numbers requested.
RoutingContainer: The inbound routing container selected.
Geoproximation: Whether or not Geoproximaton was requested.
DIDResponse: An array containing the telephone numbers requested. If no numbers are available, then 'No Numbers Available' will be displayed.
RequestCost: The amount of money for this request.
DateTimeRequested: The date and time of the request.
ResponseMessage: A friendly representation of the request's status.
ResponseCode:
200: Successful
503: ReturnStatus will contain the reason.