Skip to main content

List DID Types

List all available DID (Direct Inward Dialing) number types. These types are used when searching for number groups.

Endpoint

GET https://api.p.2chat.io/open/numbers/did-types

Authentication

Include your API key in the X-User-API-Key header. Learn more about authentication.

Parameters

No parameters required.

Invocation

curl --location --request GET 'https://api.p.2chat.io/open/numbers/did-types' \
--header 'X-User-API-Key: your_api_key_here'

Response

Success

{
"success": true,
"data": {
"did_types": [
{
"id": 1,
"name": "local"
}
]
}
}
FieldDescription
did_types[].idDID type ID
did_types[].nameDID type name

Known DID types

NameDescription
globalInternational numbers accessible from multiple countries
localLocal numbers tied to a specific city or region
mobileMobile phone numbers
nationalNational numbers accessible from anywhere in the country
sharedcostShared-cost numbers where the call charge is split
tollfreeToll-free numbers where the receiver pays for the call

Error

{
"success": false,
"error": true,
"error_message": "Description of what went wrong"
}