Aug '24 (edited) • Support Needed 💻
Hi - New here and have a question already! Twilio + Vapi?
I have set up Vapi and purchased a new Australian number through Twilio. Imported the number fine, created an assistant, tried the conversation in the web page fine, got it to make outbound web calls to my mobile fine with the assistant.....
BUT if I ring the new number I have I get a Telstra mesage about number not connected.
Everything I read prior said that once the number was imported to VAPI it would work, but it doesn't so I've spent some hours researcing the issue.
In Twilio, in the number settings it says I need to set a URL for the incoming calls to route to, (see screenshot) - so when I look in my Vapi console for the assistant the Server URL is blank, same for the Server URL in my organistion settings, as I read all about the various places this can be...but blank.
The AI help in Vapi then says I can retrieve the URL for the phone number using a GET request, and I need the phone number ID and a bearer token for that. I have the phone number ID, but apparently for the bearer token, it tells me it is a JWT and I need to generate one as per below:
----
The bearer token for Vapi API authentication is a JWT (JSON Web Token) that you need to generate yourself. Here's how you can create it:
Prerequisites
Before generating the token, ensure you have:
  • An environment that supports JWT generation and API calls
  • A Vapi account
  • Environment variables set up for your organization ID and private key (both found in your Vapi portal)
Generating the JWT Token
To generate the JWT token:
  • Define the payload with your orgId.
  • Retrieve your private key from your environment variables.
  • Set token options, including expiration time.
  • Use a JWT library or built-in functionality to generate the token.
----------
and this is where my skills run out as I don't understand exactly what I have to do as described in these steps above...
Am I on the right track, or just going down the wrong rabbit hole with all of this? I've spent hours on just this part and starting to lose my mind, but will work out the above if I have to, it just seems ridiculously complicated compared to other aspects of this whole configuration.
Any input or advice would be appreciated greatly. 🙏
thanks
Ian
6
8 comments
Ian Brown
2
Hi - New here and have a question already! Twilio + Vapi?
Brendan's AI Community
skool.com/brendan
Learn To Make Money With AI!
- 50+ Free AI Agent Templates
- 60+ Free AI Course Videos
(n8n, Make, Vapi, Voiceflow)
- AI Software Discounts 💰
Leaderboard (30-day)
Powered by