Skip to main content

DID Object

This section outlines the DID object.

DID Object Attributes

The fields listed in the table below will be returned in a JSON object when a successful request has been made.

AttributeData TypeDescription
active_capabilities
read only
integerThe phone number enabled (activated) capabilities. Criteria are similar to the capabilities attribute below. Note that this attribute is fully managed by the system and its status depends on whether SMS/MMS is enabled for a DID. To activate the SMS/MMS capabilities of your rented DIDs, you need to enable them. See also SMS/MMS enablement.
attributesobjectCustom DID attributes. Can be used for various additional purposes.
callback_urlstringThe callback URL to receive events for SMS.
campaign_sid
read only
stringThe secure ID of the 10DLC campaign associated with the DID.
capabilities
read only
integer

The phone number supported capabilities. Capabilities represent what this DID is potentially capable of: receiving, sending SMS, MMS, voice calls, etc. This field accepts numerical values. To enable more than one capability, add the corresponding integers together. The following are the numerical values for each capability:

  • 1 for receiving SMS
  • 2 for sending SMS
  • 4 for voice
  • 8 for receiving MMS
  • 16 for sending MMS

To enable receiving SMS and voice, add 1 and 4 together to make 5. The maximum value for this field is 31 (1 + 2 + 4 + 8 + 16) for all capabilities: SMS (receiving and sending), voice, and MMS (receiving and sending). Note, that by default, SMS/MMS messaging capabilities are disabled for all rented DIDs. To enable these capabilities, you need to have them activated. With non-activated capabilities an error will be returned when trying to send an SMS/MMS. See also the active_capabilities attribute above.

classification_sid
read only
stringThe phone number classification secure ID, which can be set to one of the DID Classification object secure IDs.
country_code
read only
stringThe ISO 3166-1 alpha-3 code of this DID. This field is assigned automatically.
did_group_sidstringThe DID group secure ID.
did_sid
read only
stringThe DID secure ID.
in_country_format
read only
stringThe DID in a national format.
international_format
read only
stringThe DID in an international format.
lata
read only
stringLATA: Local Access and Transport Area, a geographic code representing the location of the call origination.
locality
read only
stringThe locality or city of the DID.
lrn_sid
read only
stringThe secure ID of the Location Routing Number assigned to this DID.
namestringThe DID name. The default value is N/A.
ocn
read only
stringThe operating company number used with this DID.
partner
read only
objectThe Partner object associated with the DID. This field is displayed if with_related is set to true when performing the GET queries.
partner_sid
read only
stringThe secure ID of the partner associated with the DID.
phonenumberstringThe phone number for the DID in the E.164 format.
porting_pinstringA random 6-digit PIN code automatically assigned to a DID when it is rented. The porting PIN is used to verify requests for DID porting. The PIN code can be changed at any time.
price
read only
numberThe price of the DID.
state
read only
stringThe state or province of the DID.
status
read only
string

The current DID status.When the DID status changes, a new DID history entry is inserted into the database. Values accepted in this field are:

  • aging for DIDs released but not yet available.
  • assigned for DIDs assigned to the partner.
  • available for DIDs available for renting.
  • deleted for DIDs that have been deleted from the system.
string_key_1stringA user-defined string key.
string_key_2stringA user-defined string key.
transformationsarray of objectsThe transformations that are applied to the DID. Refer to the transformations section for more information.
trunk_group_sidstringThe secure ID of the trunk group associated with the DID.

Sample DID Object

{
"active_capabilities": 4,
"attributes": {},
"callback_url": null,
"campaign_sid": null,
"capabilities": 7,
"classification_sid": "17f4d954-d635-4cda-912b-c2a2fa3a6860",
"country_code": "USA",
"did_group_sid": null,
"did_sid": "f448e2c3-88c1-4cd1-8cf2-3567c16e0794",
"in_country_format": "(516) 206-5575",
"international_format": "+1 516-206-5575",
"lata": null,
"locality": "NEW YORK",
"lrn_sid": null,
"name": "N/A",
"ocn": "251F",
"partner_sid": "e00430c3-a7d0-4666-ab5c-f7202448382f",
"phonenumber": "15162065575",
"porting_pin": null,
"price": "0.6",
"state": "NY",
"status": "assigned",
"string_key_1": null,
"string_key_2": null,
"transformations": [],
"trunk_group_sid": null
}
note

When determining the callback URL, the system will use the first non-empty value from:

  1. the callback_url field of the DID object;
  2. the callback_url field of the DID Group object;
  3. the callbacks.sms field of the Partner object.