Docs

Get Phone Number Parameters

/accounts/{accountSID}/numbers/{numberSID}

Overview

To get information on the phone number, make the GET request to /accounts/{accountSID}/numbers/{numberSID}.

Request example

The following cURL example demonstrates getting the number details.

curl –X GET ‘https://api.apico.net/v2/accounts/{accountSID}/numbers/{numberSID}’ \
-u {accountSID}:{authToken}

Response example

{
    "number_sid": "{numberSID}",
    "account_sid": "{accountSID}",
    "number": "+447860041755",
    "country_code": "uk",
    "type": "mobile",
    "controller": "http://myapp.apico.net/incom.php",
    "method": "GET",
    "created": "Wed, 27 May 2015 08:11:11 +0000",
    "updated": "Wed, 27 May 2015 08:12:11 +0000",
    "voice": true,
    "messaging": true
}

Response parameters

Parameter

Description

account_sid

Account identifier.

number_sid

Number identifier.

number

Phone number in E.164 format.

country_code

Either country code according to ISO 3166-1 alpha-2 (for conventional numbers) or international (for virtual numbers).

country_name

The full name of the country or international (for virtual numbers).

type

Number type.

One of the following: local, mobile, toll_free or sip.

voice

Availability of voice communications for the number.

Either true or false.

messaging

Availability of messaging for the number.

Either true or false.

created

Rental date.

updated

Phone number details last updated date.

controller

URL to make a request for an XML controller file.

method

The request method.