Phone Numbers API - Search for a Phone Number to Lease

If you want to use a specific caller or sender ID for your messages or use inbound SMS through TeleSign, you must lease a phone number from TeleSign. This method can be used to review phone numbers and choose the one that suits your needs.

📘

NOTE:

Due to regulatory restrictions, phone numbers from some countries will not be visible in our inventory when using this method. You may still be able to obtain numbers in these countries using the Create a Direct Order method.

Reference Page

GET /v1/phone_numbers/numbers

Example

Request

GET /v1/phone_numbers/numbers?page_size=1&country_iso2=US&number_type=local&number_pattern=1203 HTTP/1.1
Content-Type: application/x-www-form-urlencoded
Authorization: Basic pPF9MAXw9ssP0rkk8sbWf18Fny5Vgqi4F1owcHADr8LXk8PMWIvWqeg419NNXmBtMkaTJi3U5IOhOrNOY1ZXdBv3pLZxn08Rah8mMTGv623wYqmmNRcI5adDVnYbm1ejt2E4JCiMmOFahwcNcy844cpz8dTEWMVo1XthlYf=
Host: rest-ww.telesign.com

Response

{
  "pagination": {
    "page": 1,
    "total_pages": 1,
    "page_size": 1
  },
  "data": [
    {
      "phone_number": 12039022808,
      "recurring_price": 0.8,
      "number_type": "local",
      "setup_price": 0.8,
      "price_currency": "USD",
      "country_iso2": "US",
      "capabilities": {
        "sms": true,
        "voice": true
      },
      "recurrence_period": 1
  ]
}

Try It

If you have been granted access and credentials for the Phone Numbers API, you can try a test request in the API Explorer. You can also get a code snippet for the request.

  1. Click the Auth tab and for Username add your Customer ID. For Password add your API key.
  2. Click the Query tab to modify your request parameters, if desired. The API Explorer is pre-populated with parameter values to request SMS-capable, US mobile numbers (see the reference page GET /v1/phone_numbers/numbers for full parameter details).
  3. Click Send.
  4. Click the Code Generation tab and use the Language and Library menus to choose the language you want your code snippet in.

Did this page help you?