Vladimir
03/12/2025, 8:34 AMVapi Support Bot
03/12/2025, 8:35 AMnumber
field. According to our documentation, when associating a phone number with a SIP trunk, you need to include the following fields:
json
{
"provider": "byo-phone-number",
"name": "Your SIP Number Name",
"number": "your-sip-phone-number", // This field is missing in your request
"numberE164CheckEnabled": false,
"credentialId": "your-trunk-credential-id"
}
Additionally, here are some other potential issues that could cause a Bad Request error:
1. The name
field should typically be a descriptive name (like "Telnyx SIP Number") rather than the phone number itself
2. Make sure you're not including any unnecessary properties in your request payload
3. Verify that your SIP trunk configuration is correct and compatible with the phone number you're trying to associate
Could you try adding the number
field with your phone number value and see if that resolves the issue? 😊
Sources:
- [Common causes of a 400 Bad Request error](https://discord.com/channels/1211482211119796234/1211483291191083018/threads/1333747605628391434)
- [Required fields for associating a phone number with a SIP trunk](https://docs.vapi.ai/advanced/sip/telnyx)
- [Restrictions for associating phone numbers with SIP trunks](https://discord.com/channels/1211482211119796234/1211483291191083018/threads/1334336219584135168)Vapi Support Bot
03/12/2025, 8:38 AMPraveen Nair
03/15/2025, 10:48 AM