Whitelabel Demo Mode
# support
n
I am trying to create an API where a user can whitelabel their configuration in the demo mode. I see that to make a call, webCall is not an option for the type. Is there a provision for this use case, to make an api call work for a web session, and not a phone number?
k
There is actually a dedicated endpoint for creating web calls. Here's how you can create a web call:
Copy code
const createWebCall = async (config: CreateWebCallDTO) => {
  const response = await fetch('https://api.vapi.ai/call/web', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'Authorization': 'Bearer YOUR_API_KEY'
    },
    body: JSON.stringify(config)
  });
  return response.json();
};
Let me know if you require further help.
n
Great! Thank you
Just a note of reference (I may be missing it), but I believe that is not documented in the API Docs
k
Thanks for letting me know.