Phone Numbers API - List Your Leased Numbers

❗️

WARNING:

This product is deprecated.

After you lease numbers from TeleSign, you may want to review all their details. Use this method to retrieve a list containing all the phone numbers you have leased.

Reference Page

GET /v1/phone_numbers/leases

Request

GET /v1/phone_numbers/leases?page=1&page_size=2 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": 2
  },
  "data": [
    {
      "phone_number": "12133202170",
      "recurring_price": 0.8,
      "number_type": "local",
      "setup_price": 0.8,
      "price_currency": "USD",
      "country_iso2": "US",
      "lease": {
        "lease_id": 3914,
        "created_on_utc": "2019-10-21T17:37:01.260000Z",
        "expires_on_utc": null
      },
      "capabilities": {
        "sms": true,
        "voice": true
      },
      "recurrence_period": 1
    },
    {
      "phone_number": "18006481111",
      "recurring_price": 0.7,
      "number_type": "toll-free",
      "setup_price": 0.7,
      "price_currency": "USD",
      "country_iso2": "US",
      "lease": {
        "lease_id": 3915,
        "created_on_utc": "2019-10-21T17:37:01.260000Z",
        "expires_on_utc": null
      },
      "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 to see how retrieving a list of leased numbers works. 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 Send.
  3. Click the Code Generation tab and use the Language and Library menus to choose the language you want your code snippet in.

📘

NOTE:

Create at least one lease before trying out this feature, otherwise nothing is returned!