[
{
"id": 123,
"phone_number": "<string>",
"provider": "<string>",
"twilio_sid": "<string>",
"is_active": true,
"capabilities": {},
"created_at": "2023-11-07T05:31:56Z",
"friendly_name": "<string>",
"is_verified_caller_id": false,
"sip_trunk_id": "<string>",
"allowed_country_codes": [
"<string>"
],
"assistant": {
"id": 123,
"name": "<string>",
"is_active": true
},
"flow": {
"id": 123,
"name": "<string>",
"is_active": true
},
"updated_at": "2023-11-07T05:31:56Z"
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Organization
List Organization Phone Numbers
List all phone numbers in your organization.
Returns phone numbers with their assignment status and assistant information. By default, only active phone numbers are returned.
GET
/
api
/
v1
/
assistants
/
organization
/
phone-numbers
[
{
"id": 123,
"phone_number": "<string>",
"provider": "<string>",
"twilio_sid": "<string>",
"is_active": true,
"capabilities": {},
"created_at": "2023-11-07T05:31:56Z",
"friendly_name": "<string>",
"is_verified_caller_id": false,
"sip_trunk_id": "<string>",
"allowed_country_codes": [
"<string>"
],
"assistant": {
"id": 123,
"name": "<string>",
"is_active": true
},
"flow": {
"id": 123,
"name": "<string>",
"is_active": true
},
"updated_at": "2023-11-07T05:31:56Z"
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}This endpoint retrieves a list of all phone numbers belonging to your organization. It includes information about each number’s assignment status.
Query Parameters
include_assigned(boolean, optional, default: true): Set tofalseto exclude numbers that are currently assigned to an assistant.include_unassigned(boolean, optional, default: true): Set tofalseto exclude numbers that are not currently assigned to any assistant.include_inactive(boolean, optional, default: false): Set totrueto include inactive or deactivated numbers.
Response
The response is a JSON array of phone number objects. If a number is assigned, theassistant field will contain details about the assistant it’s linked to.
Response
[
{
"id": 1,
"phone_number": "+15551234567",
"friendly_name": "Main Support Line",
"provider": "twilio",
"twilio_sid": "PNxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"is_active": true,
"is_verified_caller_id": false,
"capabilities": { "voice": true, "sms": true, "mms": true },
"sip_trunk_id": null,
"allowed_country_codes": null,
"assistant": {
"id": 123,
"name": "Customer Service Bot",
"is_active": true
},
"flow": null,
"created_at": "2023-10-01T10:00:00Z",
"updated_at": "2023-10-26T11:00:00Z"
},
{
"id": 2,
"phone_number": "+15557654321",
"friendly_name": "Sales Department",
"provider": "telnyx",
"twilio_sid": "PNyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy",
"is_active": true,
"is_verified_caller_id": false,
"capabilities": { "voice": true, "sms": false, "mms": false },
"sip_trunk_id": null,
"allowed_country_codes": null,
"assistant": null,
"flow": null,
"created_at": "2023-10-02T12:00:00Z",
"updated_at": null
}
]
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
Include phone numbers assigned to assistants
Include unassigned phone numbers
Include inactive/deactivated phone numbers
Response
Successful Response
Show child attributes
Show child attributes
Minimal assistant info for phone number list.
Show child attributes
Show child attributes
ConversationFlow information for phone number responses.
Show child attributes
Show child attributes
⌘I