c
I would like to enable inbound web-calling in my website. I would like to call an endpoint using javascript from my backend (AWS lambda) and then based on my assistant configuration, make an API call to the VAPI API to connect the call. Can you please help me achieving that? Which endpoint should I call? I would appreciate it if you could send ma link to the relative documentation.
c
there is only one endpoint which is call.
c
Thanks for getting back to me With the call endpoint, it requires the phone number, though for inbound webcalling, we won't need to specify a phone number Here is the error message that I'm facing: Here's a prettified version of the JSON message:
Copy code
json
{
  "message": "Couldn't Get Phone Number. Need Either `phoneNumberId` Or `phoneNumber`.",
  "error": "Bad Request",
  "statusCode": 400
}
Here is the documentation that I'm using for making the call https://docs.vapi.ai/api-reference/calls/create-call
c
you would just remove that it looks like.
c
This is my python lambda code http.request( 'POST', 'https://api.vapi.ai/call', headers={ 'Content-Type': 'application/json', 'Authorization': 'Bearer token' }, body=json.dumps({ 'assistantId': 'id' }) )
s
https://api.vapi.ai/call/web
pass your assistant config to this.
What I have understood is you want to create a unqiue call link for web calls and then setup the communication for the call.
c
Thanks for that Shubham
2 Views