Skip to main content
POST
/
api
/
phone-numbers
/
create
cURL
curl --request POST \
  --url http://localhost:8080/api/phone-numbers/create \
  --header 'Content-Type: application/json' \
  --header 'X-API-KEY: <api-key>' \
  --header 'X-API-SECRET: <api-key>' \
  --data '
{
  "phone_number": "+14157774444",
  "area_code": 415,
  "nickname": "Customer Service Line",
  "inbound_agent_id": "agent_abc123",
  "outbound_agent_id": "agent_xyz789",
  "inbound_agent_version": 1,
  "outbound_agent_version": 1,
  "inbound_webhook_url": "https://example.com/webhook",
  "number_provider": "twilio",
  "outbound_trunk_id": "ST_4Xo2mZgQsfyQ",
  "phone_number_type": "zudu-twilio"
}
'
{
  "message": "Phone number created successfully",
  "status": "success",
  "error": null,
  "data": {
    "phone_number": "+14157774444",
    "organization_id": "org_123",
    "phone_number_pretty": "+1 (415) 777-4444",
    "area_code": 415,
    "nickname": "Customer Service Line",
    "phone_number_type": "zudu-twilio",
    "inbound_agent_id": "agent_abc123",
    "outbound_agent_id": "agent_xyz789",
    "inbound_agent_version": 1,
    "outbound_agent_version": 1,
    "inbound_webhook_url": "https://example.com/webhook",
    "number_provider": "twilio",
    "outbound_trunk_id": "ST_4Xo2mZgQsfyQ",
    "created_at": "2024-01-15T10:30:00Z",
    "updated_at": "2024-01-15T10:30:00Z",
    "last_modification_timestamp": 1703413636133
  }
}

Authorizations

X-API-KEY
string
header
required

API Key for MCP server and external service authentication

X-API-SECRET
string
header
required

API Secret for MCP server and external service authentication

Body

application/json
phone_number
string
required

E.164 format phone number

area_code
integer

3-digit area code (US/Canada)

nickname
string
inbound_agent_id
string
outbound_agent_id
string
inbound_agent_version
integer
default:1
outbound_agent_version
integer
default:1
inbound_webhook_url
string
number_provider
string
default:twilio
outbound_trunk_id
string
phone_number_type
string

Response

200 - application/json

Phone number created successfully

message
string
status
string
error
string | null
data
object