GET NUMBER
Get information about a single number owned by your account
Using this operation you can select a number already purchased and in your account, using the 11 digit E.164 format. It returns information about that number including status, lease information, configuration, and more.
REQUEST PARAMETERS
Parameter | Data Type | Demo Value | Description |
---|---|---|---|
GetNumber | object | Number request by 11 digit telephone number | |
Number | PhoneNumber | 18185551212 | 11 digit telephone number |
RESPONSE PARAMETERS
Parameter | Data Type | Description |
---|---|---|
Number | Info about Number like Region | |
Number | PhoneNumber | 11 digit E.164 number |
NationalFormat | string | Phone number formatted for local |
TollFree | boolean | Is toll free number |
Region | Region of number represented by city, state, prefix, etc... | |
Prefix | string | 4-7 digit prefix |
City | string | Name of a city |
State | string | State abbreviation |
Zipcode | string | 5 digit zipcode |
Country | string | 2 digit country code |
Lata | string | Lata |
RateCenter | string | |
Latitude | float | Latitude |
Longitude | float | Longitude |
TimeZone | string | |
Status | NumberStatus | [PENDING, ACTIVE, RELEASED, UNAVAILABLE] |
LeaseInfo | Info about Lease | |
LeaseBegin | date | Date lease began |
LeaseEnd | date | Date lease ends |
AutoRenew | boolean | Is lease set to renew each month |
NumberConfiguration | Configure Call and Text features | |
CallFeature | NumberFeature | [UNSUPPORTED, PENDING, DISABLED, ENABLED] |
TextFeature | NumberFeature | [UNSUPPORTED, PENDING, DISABLED, ENABLED] |
InboundCallConfigurationType | InboundType | [TRACKING, IVR] |
InboundCallConfiguration | ||
CallTrackingConfig | ||
Id | long | Unique ID of InboundConfig |
TransferNumber | List[PhoneNumber] | |
Screen | boolean | |
Record | boolean | |
IntroSoundId | long | |
WhisperSoundId | long | |
IvrInboundConfig | ||
Id | long | Unique ID of InboundConfig |
DialplanXml | string |
EXAMPLE
using RestSharp;
namespace [your-namespace]
{
public class [your-class]
{
public string GetNumber()
{
string number = "12132042444"; //Your number
var client = new RestClient("https://www.callfire.com/api/1.1/rest/");
client.Authenticator = new HttpBasicAuthenticator("YourLoginId", "password");
var request = new RestRequest(string.Format("number/{0}", number), Method.GET);
var response = client.Execute(request);
string content = response.Content;
return content;
}
}
}
THE XML returned is:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<r:Resource xmlns="http://api.callfire.com/data" xmlns:r="http://api.callfire.com/resource">
<Number>
<Number>12132042444</Number>
<NationalFormat>12132042444</NationalFormat>
<TollFree>false</TollFree>
<Status>ACTIVE</Status>
<LeaseInfo>
<LeaseBegin>2014-12-02Z</LeaseBegin>
<LeaseEnd>2015-01-02Z</LeaseEnd>
<AutoRenew>true</AutoRenew>
</LeaseInfo>
<NumberConfiguration>
<CallFeature>ENABLED</CallFeature>
<TextFeature>ENABLED</TextFeature>
<InboundCallConfigurationType>TRACKING</InboundCallConfigurationType>
<InboundCallConfiguration>
<CallTrackingConfig id="3630161003">
<TransferNumber>12132042446</TransferNumber>
<Screen>false</Screen>
<Record>true</Record>
</CallTrackingConfig>
</InboundCallConfiguration>
</NumberConfiguration>
</Number>
</r:Resource>