Inbound Call Issue: Calls Not Routing Due to Missi...
# support
t
Hello, I am encountering an issue when attempting to assign an assistant to a Twilio number on VAPI Dashboard. The dashboard indicates that the assistant is assigned correctly. However, when I place a call, I receive a message stating that the number is out of reach. Upon reviewing the Twilio dashboard, I noticed that nothing is assigned to the "voice_url". As we know, the "voice_url" is necessary to route the call from Twilio to the VAPI server. Could you please assist me in resolving this issue? Thank you for your help.
v
message has been deleted
@The Dude Hello! I'm here to help you with your issue. It seems like you need to set the "voice_url" on your Twilio number to point to the VAPI server so that calls can be routed correctly. To resolve this, you'll need to update the "voice_url" in your Twilio number's configuration with the URL of your VAPI server. If you have the necessary details, such as your Twilio account credentials and the VAPI server URL, you can do this through the Twilio Console or by using the Twilio API. If you're not sure how to proceed or if you need the exact steps to update the "voice_url", please let me know, and I can provide further assistance. If you need the VAPI server URL, please provide the
serverUrl
or
serverUrlSecret
if it's a secret URL, and I can help you construct the correct "voice_url" to use.
You can continue this conversation by mentioning me in the message.
s
Hey looks like the number is not imported correctly to the vapi.
t
Thank you, i will try this solution. Before trying this solution, I have conducted several tests and discovered something unusual. - When I create a new number and assign an assistant to it, everything works as expected (inbound call is working). 👍 - deleted the assistant (not updated the number), vapi dashboard shows nothing is assigned to that number. 👍 - reassigned assistant to this number, inbound call not working 👎 Note: I am doing all of this using VAPI API's My pipelines : - create assistant > create number > update number with this assistant. - delete assistant > recreate assistant > update number with this new assistant. create number
Copy code
url = "https://api.vapi.ai/phone-number/import/twilio"

    payload = {
        "twilioPhoneNumber": phone_number,
        "name": uuid.uuid4().hex,
        "twilioAccountSid": os.getenv("TWILIO_ACCOUNT_SID"),
        "twilioAuthToken": os.getenv("TWILIO_AUTH_TOKEN"),
        "assistantId": vapi_assistant_id,
    }
    headers = {
        "Authorization": f"Bearer {os.getenv('VAPI_PUBLIC_KEY')}",
        "Content-Type": "application/json",
    }
update number
Copy code
url = f"https://api.vapi.ai/phone-number/{phone_number_id}"

    payload = {
        "name": "",  # this is the name of the number, it is not the name of the assistant
        "assistantId": vapi_assistant_id,
    }
    headers = {
        "Authorization": f"Bearer {os.getenv('VAPI_PUBLIC_KEY')}",
        "Content-Type": "application/json",
    }
s
hey can you create a new ticket for this please.
t
i am now deleting the number and recreating in vapi. In this way i have resolved this issue