JSON API » numbers » numbers/available/list
Gets a selection of numbers available to purchase.
Input parameters
Authentication is optional.
| Name | Type | Description | Required | Default value | 
|---|---|---|---|---|
| ingroup | Integer | ID of inbound group to get available numbers for. | Yes | |
| auth_username | String | Authentication username. | No | None. | 
| auth_password | String | Authentication password. | No | None. | 
| class | Integer | ID of number class to get available numbers for. 0 for any. | No | 0 | 
| count | Integer | How many numbers to return. | No | 10 | 
| customer | Integer | Prefer numbers previously owned by this customer. Only used if authentication is supplied. | No | Customer of authentication user. | 
| preferred | String | Prefer this number if available. Empty string for none. | No | Empty string. | 
Responses
| Code | Description | 
|---|---|
| 200 | Success. | 
| 400 | Invalid input parameters specified. Check the key and message fields for more details. | 
Data returned
An array of numbers.
Example: With required parameters
http://enswitch.example.com/api/json/numbers/available/list/?ingroup=123{ "responses":[ { "code":"200", "key":"", "message":"OK" } ], "data":[ "2125551234", "2125551235", ... ] ] }
Change history
| Version | Changes | 
|---|---|
| 3.13 | Function added. | 
