phone_number
(string, required): The phone number to purchase in E.164 formatprovider
(string, required): Provider to use ("twilio"
or "telnyx"
)assistant_id
(integer, optional): ID of the assistant to assign this number tofriendly_name
(string, optional): Custom display name for the number200 OK
status with purchase confirmation.
success
(boolean): Whether the purchase completed successfullyphone_number
(string): The purchased phone numberprovider
(string): Provider used for the purchase (“twilio” or “telnyx”)purchase_details
(object): Provider-specific purchase information
sid
(string): Twilio phone number SIDfriendly_name
(string): Display namevoice_url
(string): Configured voice webhook URLsms_url
(string): Configured SMS webhook URLcapabilities
(object): Number capabilitiesdate_created
(string): Purchase timestampid
(string): Telnyx order IDstatus
(string): Order status (“completed”, “pending”, etc.)connection_id
(string): Associated connection IDdate_created
(string): Purchase timestampmessage
(string): Human-readable confirmation messageprovider
value (must be “twilio” or “telnyx”)assistant_id
(assistant doesn’t exist)assistant_id
, the system:
https://yourdomain.com/twiml
https://yourdomain.com/twiml
https://yourdomain.com/telnyx-webhook
Issue | Cause | Solution |
---|---|---|
”Number not available” | Number purchased by someone else | Search for new numbers |
”Insufficient balance” | Account balance too low | Add funds to provider account |
”Invalid credentials” | Wrong API keys | Check provider credentials |
”Assistant not found” | Invalid assistant ID | Verify assistant exists |