O.K got it working on my desktop but in IOS I get an error:
An error occured
Undefined is not an object (evaluating 'navigator.mediaDevices.getUserMedia')
Here is the event code (Note I changed the agent id as I don't want folks reading this to burn through my credits:
if (!document.getElementById("budo-voice")) {
const convoDiv = document.createElement("elevenlabs-convai");
convoDiv.setAttribute("agent-id", "jusandexample");
convoDiv.id = "budo-voice";
// ✨ Centering the widget in the screen
convoDiv.style.position = "fixed";
convoDiv.style.top = "50%";
convoDiv.style.left = "50%";
convoDiv.style.transform = "translate(-50%, -50%)";
convoDiv.style.zIndex = "9999";
convoDiv.style.width = "300px"; // optional
convoDiv.style.height = "auto"; // optional
document.body.appendChild(convoDiv);
const script = document.createElement("script");
script.src = "https://elevenlabs.io/convai-widget/index.js";
script.async = true;
script.type = "text/javascript";
document.body.appendChild(script);
}