Tools aren't called when using web calling.
# support
a
Hi, when I use a react app to do a web call using an existing asistant (with installed tools), it's not calling the tools at all. When I use the Vapi UI to test the same assistant, it does call the installed tools. Why would this be?
v
@arbstate Hello! It sounds like there might be an issue with how the web call is being made from your React app. Here are a few things to check: 1. **Endpoint URL**: Ensure that the React app is using the correct server URL to make the call to your assistant. 2. **HTTP Method**: Verify that the React app is using the correct HTTP method (GET, POST, etc.) as expected by your server for calling the tools. 3. **Request Headers**: Check if the necessary headers, such as
Content-Type
, are set correctly in the web call from your React app. 4. **Request Body**: If the tools require parameters, make sure that the React app is sending the correct JSON payload in the request body. 5. **CORS Policy**: If your server and React app are on different domains, ensure that Cross-Origin Resource Sharing (CORS) is properly configured on your server. 6. **Error Handling**: Implement error handling in your React app to catch any issues during the web call and log them for further investigation. 7. **Network Issues**: Use browser developer tools to inspect the network request and response to see if there are any obvious issues. If you've checked all of these and the issue persists, it might be helpful to compare the successful request from the Vapi UI with the failing request from your React app to spot any differences. If you're unable to resolve the issue, please provide more specific details or error messages you're encountering, and I'll do my best to assist you further.
You can continue this conversation by mentioning me in the message.
s
can you share call id with timestamp and a loom video.