Bibek Shah
04/03/2025, 4:48 PMVapi Support Bot
04/03/2025, 4:49 PMtype
parameter. Based on the information available, it seems there's a misunderstanding about how web calls are created in Vapi.
According to the documentation, the /call
endpoint you're using is specifically designed for phone calls (either outbound or inbound), not web calls. That's why you're getting the error message that type
must be one of: outboundPhoneCall, inboundPhoneCall
.
For web calls, you need to use a different approach:
1. Web calls require using the [Web SDK](https://docs.vapi.ai/sdk/web) or web-html-snippet rather than the /call
endpoint
2. The server-side approach you're looking for would likely involve:
- Generating authentication tokens on your server
- Passing those tokens to your client application
- Using the client SDK to initialize and join the call
Could you clarify if you've already looked into using the Web SDK with server-generated tokens? And are you specifically trying to hide prompts from frontend dev tools, or do you have other security concerns as well?
Sources:
- [Vapi Web SDK Documentation](https://docs.vapi.ai/sdk/web)
- [Vapi Web Quickstart Guide](https://docs.vapi.ai/quickstart/web)Shubham Bajaj
04/06/2025, 11:49 AMShubham Bajaj
04/06/2025, 11:55 AM