// Browserconst pc = new RTCPeerConnection();const mic = await navigator.mediaDevices.getUserMedia({ audio: true });mic.getAudioTracks().forEach((t) => pc.addTrack(t, mic));pc.createDataChannel('control');pc.ontrack = (e) => { audioEl.srcObject = e.streams[0]; };await pc.setLocalDescription(await pc.createOffer());await new Promise((resolve) => { if (pc.iceGatheringState === 'complete') return resolve(); pc.onicegatheringstatechange = () => pc.iceGatheringState === 'complete' && resolve();});const res = await fetch('/my-backend/talk', { method: 'POST', body: JSON.stringify({ offer: pc.localDescription.sdp }) });const { answer, callId } = await res.json();await pc.setRemoteDescription({ type: 'answer', sdp: answer });// Your server: forward the offer with your API key, return { answer, callId: data.call.id }
Start a live voice call between a browser and an agent. The browser creates a WebRTC offer (an SDP string); you send it here and get back an answer that the browser uses to finish connecting. The response is 201 Created with the call and the answer.
Send the offer from your server, never from the browser. The request needs your API key (scope agents). Have your frontend send the offer to your backend, call this endpoint from there, and return only the answer and the call id to the browser.
Costs: AI credits for speech, LLM and memory, like a phone call. No Dialer balance or phone line is used. The workspace must have an active plan.
The finished SDP offer from the browser, 1 to 32,768 characters, starting with v=0. It must contain an audio track and a data channel, and ICE gathering must be complete (wait for iceGatheringState === "complete" before reading localDescription)
The call is trimmed above; see Get call for every field. Pass answer to RTCPeerConnection.setRemoteDescription({ type: "answer", sdp }). The call moves to in_progress when the browser connects, and finishes with the usual call.completed event. Browser calls are not shown by polling the runtime, so use Get call or the events.
// Browserconst pc = new RTCPeerConnection();const mic = await navigator.mediaDevices.getUserMedia({ audio: true });mic.getAudioTracks().forEach((t) => pc.addTrack(t, mic));pc.createDataChannel('control');pc.ontrack = (e) => { audioEl.srcObject = e.streams[0]; };await pc.setLocalDescription(await pc.createOffer());await new Promise((resolve) => { if (pc.iceGatheringState === 'complete') return resolve(); pc.onicegatheringstatechange = () => pc.iceGatheringState === 'complete' && resolve();});const res = await fetch('/my-backend/talk', { method: 'POST', body: JSON.stringify({ offer: pc.localDescription.sdp }) });const { answer, callId } = await res.json();await pc.setRemoteDescription({ type: 'answer', sdp: answer });// Your server: forward the offer with your API key, return { answer, callId: data.call.id }
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"60db","colors":{"primary":"#4A3228","light":"#F5EFE8","dark":"#4A3228"},"logo":{"light":"https://mintcdn.com/60db-c848165a/83Hv-Y-hnK8ZdMCS/logo/60db-logo.svg?fit=max\u0026auto=format\u0026n=83Hv-Y-hnK8ZdMCS\u0026q=85\u0026s=7334adf60f84684685b34f6455a5a071","dark":"https://mintcdn.com/60db-c848165a/83Hv-Y-hnK8ZdMCS/logo/60db-logo-dark.svg?fit=max\u0026auto=format\u0026n=83Hv-Y-hnK8ZdMCS\u0026q=85\u0026s=2912d99ca05c091678a2f08253d2bf5e"},"favicon":"https://mintcdn.com/60db-c848165a/83Hv-Y-hnK8ZdMCS/logo/60db-logo.svg?fit=max\u0026auto=format\u0026n=83Hv-Y-hnK8ZdMCS\u0026q=85\u0026s=7334adf60f84684685b34f6455a5a071","api":{"playground":{"display":"interactive"},"mdx":{"auth":{"method":"bearer"},"server":"https://api.60db.ai"}},"background":{"color":{"light":"#F5EFE8","dark":"#4A3228"}},"navbar":{"links":[{"href":"mailto:[email protected]","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://app.60db.ai"}},"footer":{"socials":{"twitter":"https://x.com/60dbAi","github":"https://github.com/60db-ai","linkedin":"https://www.linkedin.com/company/60-db"}},"styling":{"latex":true},"navigation":{"global":{"anchors":[{"anchor":"Dashboard","icon":"book-open-cover","href":"https://app.60db.ai"}]},"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"60db-c848165a","hasAudioNarration":false,"actualSubdomain":"60db-c848165a","customDomains":["docs.60db.ai"],"gitSource":{"type":"github","owner":"60db-ai","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ae973fd988bfc85bcd3acf3","collectionId":"8ae2ba82-414a-4678-8055-7b1682e35ca9","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ae973fd988bfc85bcd3acf3"},"entitlements":{},"buildId":"6aeac7b8f37847210ba393b6","clientVersion":"0.0.4054","searchFilterCounts":[{"language":"default","tag":"API Reference","count":136},{"language":"default","tag":"Dialer","count":25},{"language":"default","tag":"CLI Reference","count":23},{"language":"default","tag":"Documentation","count":22},{"language":"default","tag":"Agents","count":21},{"language":"default","tag":"MCP Server","count":19},{"language":"default","tag":"Core Features","count":16},{"language":"default","tag":"Judge","count":14},{"language":"default","tag":"CLI Commands","count":13},{"language":"default","tag":"Music","count":9}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/agents/start-web-call","slug":"/api-reference/agents/start-web-call","pageMetadata":{"title":"Start Browser Call","api":"POST /agents/{agentId}/web-calls","description":"Let someone talk to an agent from a browser over WebRTC. No phone line needed.","href":"/api-reference/agents/start-web-call"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,ParamField,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Start a live voice call between a browser and an agent. The browser creates a WebRTC `,_jsx(_components.strong,{children:`offer`}),` (an SDP string); you send it here and get back an `,_jsx(_components.strong,{children:`answer`}),` that the browser uses to finish connecting. The response is `,_jsx(_components.strong,{children:`201 Created`}),` with the call and the answer.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Send the offer from your server, never from the browser.`}),` The request needs your API key (scope `,_jsx(_components.code,{children:`agents`}),`). Have your frontend send the offer to your backend, call this endpoint from there, and return only the `,_jsx(_components.code,{children:`answer`}),` and the call `,_jsx(_components.code,{children:`id`}),` to the browser.`]})}),`\n`,_jsx(_components.p,{children:`Costs: AI credits for speech, LLM and memory, like a phone call. No Dialer balance or phone line is used. The workspace must have an active plan.`}),`\n`,_jsx(Heading,{level:`2`,id:`request`,children:`Request`}),`\n`,_jsx(Heading,{level:`3`,id:`headers`,children:`Headers`}),`\n`,_jsx(ParamField,{header:`Authorization`,type:`string`,required:true,id:`param-authorization`,children:_jsxs(_components.p,{children:[`Bearer token with your API key (scope `,_jsx(_components.code,{children:`agents`}),`)`]})}),`\n`,_jsx(ParamField,{header:`Content-Type`,type:`string`,required:true,id:`param-content-type`,children:_jsx(_components.p,{children:`application/json`})}),`\n`,_jsx(Heading,{level:`3`,id:`path`,children:`Path`}),`\n`,_jsx(ParamField,{path:`agentId`,type:`string`,required:true,id:`param-agent-id`,children:_jsxs(_components.p,{children:[`The agent `,_jsx(_components.code,{children:`id`}),` (UUID)`]})}),`\n`,_jsx(Heading,{level:`3`,id:`body`,children:`Body`}),`\n`,_jsx(ParamField,{body:`offer`,type:`string`,required:true,id:`param-offer`,children:_jsxs(_components.p,{children:[`The finished SDP offer from the browser, 1 to 32,768 characters, starting with `,_jsx(_components.code,{children:`v=0`}),`. It must contain an audio track and a data channel, and ICE gathering must be complete (wait for `,_jsx(_components.code,{children:`iceGatheringState === \"complete\"`}),` before reading `,_jsx(_components.code,{children:`localDescription`}),`)`]})}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`201 Created`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`19`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"success\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"data\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"call\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"6b1f0c52-4d7e-4b8a-9d3e-2a1c8e7f0a11\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"9c2e1d7a-0b3f-4e6a-8f1d-5a7b9c0e2d44\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Front desk\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"phone_line_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"direction\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"web\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"to\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"browser\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"from\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"browser\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"dialing\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"duration_secs\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"record\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"source\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"api\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"answer\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"v=0`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\r\\\\n`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`o=- ...\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The call is trimmed above; see `,_jsx(_components.a,{href:`/api-reference/agents/get-call`,children:`Get call`}),` for every field. Pass `,_jsx(_components.code,{children:`answer`}),` to `,_jsx(_components.code,{children:`RTCPeerConnection.setRemoteDescription({ type: \"answer\", sdp })`}),`. The call moves to `,_jsx(_components.code,{children:`in_progress`}),` when the browser connects, and finishes with the usual `,_jsx(_components.code,{children:`call.completed`}),` event. Browser calls are not shown by polling the runtime, so use `,_jsx(_components.a,{href:`/api-reference/agents/get-call`,children:`Get call`}),` or the events.`]}),`\n`,_jsx(Heading,{level:`2`,id:`limits`,children:`Limits`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Up to 3 browser calls at once per workspace.`}),`\n`,_jsx(_components.li,{children:`A call lasts up to 5 minutes.`}),`\n`,_jsx(_components.li,{children:`No call transfer and no keypad (DTMF). Audio is phone quality.`}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`errors`,children:`Errors`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Code`}),_jsx(_components.th,{children:`Meaning`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`400`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`VALIDATION_ERROR`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`offer`}),` is missing, too long, or not an SDP. `,_jsx(_components.code,{children:`field`}),` names it`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`402`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`INSUFFICIENT_CREDITS`})}),_jsx(_components.td,{children:`Not enough AI credits to start a call`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`403`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`POLICY_DENY`})}),_jsxs(_components.td,{children:[`No active plan, or the API key lacks the `,_jsx(_components.code,{children:`agents`}),` scope`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`404`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AGENT_NOT_FOUND`})}),_jsx(_components.td,{children:`No agent with this ID in your workspace`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`429`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`TOO_MANY_WEB_CALLS`})}),_jsx(_components.td,{children:`3 browser calls are already running. Wait for one to end`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`503`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`WEB_CALLS_UNAVAILABLE`})}),_jsx(_components.td,{children:`Browser calls are not available right now. Retry shortly`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`502`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AGENTS_UPSTREAM_UNAVAILABLE`})}),_jsx(_components.td,{children:`The call runtime failed or did not answer`})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`example`,children:`Example`})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Start Browser Call","api":"POST /agents/{agentId}/web-calls","description":"Let someone talk to an agent from a browser over WebRTC. No phone line needed.","href":"/api-reference/agents/start-web-call"}}},"mdxSourceWithNoJs":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,ParamField,RequestExample,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!ParamField)_missingMdxReference(`ParamField`,true);if(!RequestExample)_missingMdxReference(`RequestExample`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Start a live voice call between a browser and an agent. The browser creates a WebRTC `,_jsx(_components.strong,{children:`offer`}),` (an SDP string); you send it here and get back an `,_jsx(_components.strong,{children:`answer`}),` that the browser uses to finish connecting. The response is `,_jsx(_components.strong,{children:`201 Created`}),` with the call and the answer.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`Send the offer from your server, never from the browser.`}),` The request needs your API key (scope `,_jsx(_components.code,{children:`agents`}),`). Have your frontend send the offer to your backend, call this endpoint from there, and return only the `,_jsx(_components.code,{children:`answer`}),` and the call `,_jsx(_components.code,{children:`id`}),` to the browser.`]})}),`\n`,_jsx(_components.p,{children:`Costs: AI credits for speech, LLM and memory, like a phone call. No Dialer balance or phone line is used. The workspace must have an active plan.`}),`\n`,_jsx(Heading,{level:`2`,id:`request`,children:`Request`}),`\n`,_jsx(Heading,{level:`3`,id:`headers`,children:`Headers`}),`\n`,_jsx(ParamField,{header:`Authorization`,type:`string`,required:true,id:`param-authorization`,children:_jsxs(_components.p,{children:[`Bearer token with your API key (scope `,_jsx(_components.code,{children:`agents`}),`)`]})}),`\n`,_jsx(ParamField,{header:`Content-Type`,type:`string`,required:true,id:`param-content-type`,children:_jsx(_components.p,{children:`application/json`})}),`\n`,_jsx(Heading,{level:`3`,id:`path`,children:`Path`}),`\n`,_jsx(ParamField,{path:`agentId`,type:`string`,required:true,id:`param-agent-id`,children:_jsxs(_components.p,{children:[`The agent `,_jsx(_components.code,{children:`id`}),` (UUID)`]})}),`\n`,_jsx(Heading,{level:`3`,id:`body`,children:`Body`}),`\n`,_jsx(ParamField,{body:`offer`,type:`string`,required:true,id:`param-offer`,children:_jsxs(_components.p,{children:[`The finished SDP offer from the browser, 1 to 32,768 characters, starting with `,_jsx(_components.code,{children:`v=0`}),`. It must contain an audio track and a data channel, and ICE gathering must be complete (wait for `,_jsx(_components.code,{children:`iceGatheringState === \"complete\"`}),` before reading `,_jsx(_components.code,{children:`localDescription`}),`)`]})}),`\n`,_jsx(Heading,{level:`2`,id:`response`,children:`Response`}),`\n`,_jsx(_components.p,{children:_jsx(_components.strong,{children:`201 Created`})}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`19`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`19`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"success\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"data\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"call\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"6b1f0c52-4d7e-4b8a-9d3e-2a1c8e7f0a11\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"9c2e1d7a-0b3f-4e6a-8f1d-5a7b9c0e2d44\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"agent_name\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Front desk\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"phone_line_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"direction\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"web\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"to\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"browser\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"from\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"browser\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"status\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"dialing\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"duration_secs\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`null`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"record\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`false`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"source\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"api\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` },`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"answer\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"v=0`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:`\\\\r\\\\n`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`o=- ...\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The call is trimmed above; see `,_jsx(_components.a,{href:`/api-reference/agents/get-call`,children:`Get call`}),` for every field. Pass `,_jsx(_components.code,{children:`answer`}),` to `,_jsx(_components.code,{children:`RTCPeerConnection.setRemoteDescription({ type: \"answer\", sdp })`}),`. The call moves to `,_jsx(_components.code,{children:`in_progress`}),` when the browser connects, and finishes with the usual `,_jsx(_components.code,{children:`call.completed`}),` event. Browser calls are not shown by polling the runtime, so use `,_jsx(_components.a,{href:`/api-reference/agents/get-call`,children:`Get call`}),` or the events.`]}),`\n`,_jsx(Heading,{level:`2`,id:`limits`,children:`Limits`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsx(_components.li,{children:`Up to 3 browser calls at once per workspace.`}),`\n`,_jsx(_components.li,{children:`A call lasts up to 5 minutes.`}),`\n`,_jsx(_components.li,{children:`No call transfer and no keypad (DTMF). Audio is phone quality.`}),`\n`]}),`\n`,_jsx(Heading,{level:`2`,id:`errors`,children:`Errors`}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Status`}),_jsx(_components.th,{children:`Code`}),_jsx(_components.th,{children:`Meaning`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`400`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`VALIDATION_ERROR`})}),_jsxs(_components.td,{children:[_jsx(_components.code,{children:`offer`}),` is missing, too long, or not an SDP. `,_jsx(_components.code,{children:`field`}),` names it`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`402`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`INSUFFICIENT_CREDITS`})}),_jsx(_components.td,{children:`Not enough AI credits to start a call`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`403`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`POLICY_DENY`})}),_jsxs(_components.td,{children:[`No active plan, or the API key lacks the `,_jsx(_components.code,{children:`agents`}),` scope`]})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`404`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AGENT_NOT_FOUND`})}),_jsx(_components.td,{children:`No agent with this ID in your workspace`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`429`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`TOO_MANY_WEB_CALLS`})}),_jsx(_components.td,{children:`3 browser calls are already running. Wait for one to end`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`503`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`WEB_CALLS_UNAVAILABLE`})}),_jsx(_components.td,{children:`Browser calls are not available right now. Retry shortly`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{\"data-numeric\":`true`,children:`502`}),_jsx(_components.td,{children:_jsx(_components.code,{children:`AGENTS_UPSTREAM_UNAVAILABLE`})}),_jsx(_components.td,{children:`The call runtime failed or did not answer`})]})]})]}),`\n`,_jsx(Heading,{level:`2`,id:`example`,children:`Example`}),`\n`,_jsxs(RequestExample,{children:[_jsx(CodeBlock,{filename:`cURL`,numberOfLines:`4`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`4`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://api.60db.ai/agents/AGENT_ID/web-calls`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer your-api-key\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{ \"offer\": \"v=0\\\\r\\\\no=- ...\" }'`})]}),`\n`]})})}),_jsx(CodeBlock,{filename:`Browser + your server`,numberOfLines:`16`,language:`javascript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`javascript`,children:_jsxs(_components.code,{language:`javascript`,numberOfLines:`16`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Browser`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` pc`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` RTCPeerConnection`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` mic`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` navigator`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`mediaDevices`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`getUserMedia`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`audio:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` true`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`mic`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`getAudioTracks`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`().`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`forEach`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`t`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`addTrack`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`t`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`mic`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`));`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`createDataChannel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'control'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`);`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`ontrack`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`e`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`audioEl`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`srcObject`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` e`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`streams`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`[`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`0`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`]; };`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`setLocalDescription`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`createOffer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`());`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`await`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` new`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` Promise`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`((`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#9CDCFE`},children:`resolve`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`iceGatheringState`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ===`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'complete'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`return`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` resolve`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`onicegatheringstatechange`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` () `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`=>`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`iceGatheringState`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` ===`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'complete'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u0026\u0026`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` resolve`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`});`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` res`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` fetch`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`'/my-backend/talk'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, { `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`method:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'POST'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`body:`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:` JSON`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`stringify`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`offer:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`localDescription`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sdp`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }) });`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`const`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` { `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`answer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4FC1FF`},children:`callId`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` } `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` res`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`json`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`();`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`await`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` pc`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`.`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`setRemoteDescription`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`({ `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`type:`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'answer'`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`sdp:`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` answer`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` });`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#6E7781`,\"--shiki-dark\":`#6A9955`},children:`// Your server: forward the offer with your API key, return { answer, callId: data.call.id }`})}),`\n`]})})})]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Start Browser Call","api":"POST /agents/{agentId}/web-calls","description":"Let someone talk to an agent from a browser over WebRTC. No phone line needed.","href":"/api-reference/agents/start-web-call"}}}},"mdxExtracts":{"tableOfContents":[{"title":"Request","slug":"request","depth":2,"children":[{"title":"Headers","slug":"headers","depth":3,"children":[]},{"title":"Path","slug":"path","depth":3,"children":[]},{"title":"Body","slug":"body","depth":3,"children":[]}]},{"title":"Response","slug":"response","depth":2,"children":[]},{"title":"Limits","slug":"limits","depth":2,"children":[]},{"title":"Errors","slug":"errors","depth":2,"children":[]},{"title":"Example","slug":"example","depth":2,"children":[]}],"codeExamples":{"request":{"type":"RequestExample","children":[{"filename":"cURL","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"shellscript\">\u003ccode language=\"shellscript\" numberOfLines=\"4\">\u003cspan class=\"line\">\u003cspan style=\"color:#953800;--shiki-dark:#DCDCAA\">curl\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -X\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> POST\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> https://api.60db.ai/agents/AGENT_ID/web-calls\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -H\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Authorization: Bearer your-api-key\"\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -H\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> \"Content-Type: application/json\"\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D7BA7D\"> \\\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> -d\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> '{ \"offer\": \"v=0\\r\\no=- ...\" }'\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"},{"filename":"Browser + your server","html":"\u003cpre class=\"shiki shiki-themes github-light-default dark-plus\" style=\"background-color:#ffffff;--shiki-dark-bg:#0B0C0E;color:#1f2328;--shiki-dark:#D4D4D4\" language=\"javascript\">\u003ccode language=\"javascript\" numberOfLines=\"16\">\u003cspan class=\"line\">\u003cspan style=\"color:#6E7781;--shiki-dark:#6A9955\">// Browser\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> pc\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> new\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> RTCPeerConnection\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">();\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> mic\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> navigator\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">mediaDevices\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">getUserMedia\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">({ \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">audio:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#569CD6\"> true\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> });\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">mic\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">getAudioTracks\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">().\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">forEach\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">((\u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">t\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">) \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">=>\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">addTrack\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">t\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">mic\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">));\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">createDataChannel\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'control'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">);\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">ontrack\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> (\u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">e\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">) \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">=>\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> { \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">audioEl\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">srcObject\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> e\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">streams\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">[\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#B5CEA8\">0\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">]; };\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">setLocalDescription\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">createOffer\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">());\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">await\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\"> new\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4EC9B0\"> Promise\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">((\u003c/span>\u003cspan style=\"color:#953800;--shiki-dark:#9CDCFE\">resolve\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">) \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">=>\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> {\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> if\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> (\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">iceGatheringState\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> ===\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'complete'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">) \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">return\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> resolve\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">();\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">onicegatheringstatechange\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> () \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">=>\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">iceGatheringState\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> ===\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'complete'\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> \u0026#x26;\u0026#x26;\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> resolve\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">();\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">});\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> res\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\"> =\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\"> fetch\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">(\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\">'/my-backend/talk'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, { \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">method:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'POST'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">body:\u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\"> JSON\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">stringify\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">({ \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">offer:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">localDescription\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">sdp\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> }) });\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#569CD6\">const\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> { \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\">answer\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#0550AE;--shiki-dark:#4FC1FF\">callId\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> } \u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#D4D4D4\">=\u003c/span>\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\"> await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> res\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">json\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">();\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#CF222E;--shiki-dark:#C586C0\">await\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> pc\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">.\u003c/span>\u003cspan style=\"color:#8250DF;--shiki-dark:#DCDCAA\">setRemoteDescription\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">({ \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">type:\u003c/span>\u003cspan style=\"color:#0A3069;--shiki-dark:#CE9178\"> 'answer'\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\">, \u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\">sdp:\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#9CDCFE\"> answer\u003c/span>\u003cspan style=\"color:#1F2328;--shiki-dark:#D4D4D4\"> });\u003c/span>\u003c/span>\n\u003cspan class=\"line\">\u003c/span>\n\u003cspan class=\"line\">\u003cspan style=\"color:#6E7781;--shiki-dark:#6A9955\">// Your server: forward the offer with your API key, return { answer, callId: data.call.id }\u003c/span>\u003c/span>\n\u003c/code>\u003c/pre>"}],"attributes":[]}},"endpoint":{"title":"Start Browser Call","path":"/agents/{agentId}/web-calls","servers":[{"url":"https://api.60db.ai"}],"method":"post","request":{"security":[{"title":"Bearer Auth","parameters":{"header":{"Authorization":{"type":"http","scheme":"bearer","description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token."}},"query":{},"cookie":{}}}],"parameters":{"query":{},"header":{"Authorization":{"schema":[{"type":"string","description":"Bearer token with your API key (scope `agents` )","required":true}]},"Content-Type":{"schema":[{"type":"string","description":"application/json","required":true}]}},"cookie":{},"path":{"agentId":{"schema":[{"type":"string","description":"The agent `id` (UUID)","required":true}]}}},"body":{"application/json":{"schemaArray":[{"type":"object","properties":{"offer":[{"type":"string","description":"The finished SDP offer from the browser, 1 to 32,768 characters, starting with `v=0` . It must contain an audio track and a data channel, and ICE gathering must be complete (wait for `iceGatheringState === \"complete\"` before reading `localDescription` )","required":true}]}}],"examples":{"example":{"value":{"offer":"\u003cstring>"}}}}}},"response":{},"deprecated":false}},"jsLinks":[],"subdomain":"60db-c848165a","siteName":"60db","title":"Start Browser Call - 60db","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-04T05:50:55.751Z","originalFileLocation":"api-reference/agents/start-web-call.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\">\u003cmeta data-mint-head name=\"application-name\" content=\"60db\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Start Browser Call - 60db\">\u003cmeta data-mint-head property=\"og:description\" content=\"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"60db\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.60db.ai/api-reference/agents/start-web-call\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://60db-c848165a.mintlify.app/_mintlify/api/og/v2?division=Agents\u0026amp;title=Start+Browser+Call\u0026amp;description=Let+someone+talk+to+an+agent+from+a+browser+over+WebRTC.+No+phone+line+needed.\u0026amp;theme=285fc077b6c10621f332e454\u0026amp;signature=1faf4393619acba6015102f2288a351ca1e0a256d2ba461b86a7b0020ed7823b\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Start Browser Call - 60db\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://60db-c848165a.mintlify.app/_mintlify/api/og/v2?division=Agents\u0026amp;title=Start+Browser+Call\u0026amp;description=Let+someone+talk+to+an+agent+from+a+browser+over+WebRTC.+No+phone+line+needed.\u0026amp;theme=285fc077b6c10621f332e454\u0026amp;signature=1faf4393619acba6015102f2288a351ca1e0a256d2ba461b86a7b0020ed7823b\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/60db-c848165a/CC00PK6eC4HKg2Rz/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"60db\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#4A3228\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.60db.ai/api-reference/agents/start-web-call\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/agents/start-web-call.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.60db.ai/#organization\",\"name\":\"60db\",\"url\":\"https://docs.60db.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/60db-c848165a/83Hv-Y-hnK8ZdMCS/logo/60db-logo.svg?fit=max\u0026auto=format\u0026n=83Hv-Y-hnK8ZdMCS\u0026q=85\u0026s=7334adf60f84684685b34f6455a5a071\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.60db.ai#website\",\"name\":\"60db\",\"url\":\"https://docs.60db.ai\",\"publisher\":{\"@id\":\"https://docs.60db.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.60db.ai/api-reference/agents/start-web-call#webpage\",\"url\":\"https://docs.60db.ai/api-reference/agents/start-web-call\",\"name\":\"Start Browser Call\",\"description\":\"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\",\"dateModified\":\"2026-11-04T05:50:55.751Z\",\"isPartOf\":{\"@id\":\"https://docs.60db.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.60db.ai/api-reference/agents/start-web-call#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.60db.ai/api-reference/agents/start-web-call#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Agents\",\"item\":\"https://docs.60db.ai/api-reference/agents/list-agents\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Start Browser Call\",\"item\":\"https://docs.60db.ai/api-reference/agents/start-web-call\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.60db.ai/api-reference/agents/start-web-call#apireference\",\"headline\":\"Start Browser Call\",\"name\":\"Start Browser Call\",\"description\":\"Let someone talk to an agent from a browser over WebRTC. No phone line needed.\",\"url\":\"https://docs.60db.ai/api-reference/agents/start-web-call\",\"mainEntityOfPage\":{\"@id\":\"https://docs.60db.ai/api-reference/agents/start-web-call#webpage\"},\"dateModified\":\"2026-11-04T05:50:55.751Z\",\"publisher\":{\"@id\":\"https://docs.60db.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.60db.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"60db\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"60db","nav":{"global":{"anchors":[{"anchor":"Dashboard","icon":"book-open-cover","href":"https://app.60db.ai"}]},"tabs":[{"tab":"Documentation","pages":[{"title":"Documentation","href":"/introduction"}]},{"tab":"WebSocket API","pages":[{"title":"WebSocket API","href":"/websocket-api"}]},{"tab":"API Reference","groups":[{"group":"API Documentation","pages":[{"title":"API Reference","href":"/api-reference/introduction"},{"title":"API Playground Troubleshooting","href":"/api-reference/troubleshooting"}]},{"group":"WebSocket Reference","pages":[{"title":"WebSocket Introduction","href":"/api-reference/websocket/introduction"},{"title":"STT WebSocket","api":"WebSocket /ws/stt","href":"/api-reference/websocket/stt"},{"title":"TTS WebSocket","api":"WebSocket /ws/tts","href":"/api-reference/websocket/tts"}]},{"group":"Text-to-Speech","pages":[{"title":"Text to Speech","api":"POST /tts-synthesize","href":"/api-reference/tts/text-to-speech"},{"title":"Text to Speech Stream","api":"POST /tts-stream","href":"/api-reference/tts/text-to-speech-stream"},{"title":"Enhance Text","api":"POST /tts/enhance","href":"/api-reference/tts/enhance-text"},{"title":"Get TTS Languages","api":"GET /tts/languages","href":"/api-reference/tts/text-to-speech-languages"}]},{"group":"Speech-to-Text","pages":[{"title":"Speech to Text","api":"POST /stt","href":"/api-reference/stt/speech-to-text"},{"title":"Get Languages","api":"GET /stt/languages","href":"/api-reference/stt/get-languages"}]},{"group":"LLM \u0026 Chat","pages":[{"title":"Chat","api":"POST /v1/chat/completions","href":"/api-reference/llm/chat-completion"}]},{"group":"Memory \u0026 RAG","pages":[{"title":"Ingest Memory","api":"POST /memory/ingest","href":"/api-reference/memory/ingest"},{"title":"Upload Document","api":"POST /memory/documents/extract","href":"/api-reference/memory/extract-document"},{"title":"Search Memories","api":"POST /memory/search","href":"/api-reference/memory/search"},{"title":"Assemble Context (RAG)","api":"POST /memory/context","href":"/api-reference/memory/context"},{"title":"Collections","href":"/api-reference/memory/collections"},{"title":"Get Memory Usage","api":"GET /memory/usage","href":"/api-reference/memory/usage"},{"title":"Pricing \u0026 Billing","href":"/api-reference/memory/pricing"}]},{"group":"Judge","pages":[{"title":"Evaluate","api":"POST /v1/systemone","href":"/api-reference/judge/systemone"},{"title":"Extract","api":"POST /v1/extract","href":"/api-reference/judge/extract-v1"},{"title":"List models","api":"GET /judge/models","href":"/api-reference/judge/models"},{"title":"List rubrics","api":"GET /judge/rubrics","href":"/api-reference/judge/list-rubrics"},{"title":"Create rubric","api":"POST /judge/rubrics","href":"/api-reference/judge/create-rubric"},{"title":"Get rubric","api":"GET /judge/rubrics/{id}","href":"/api-reference/judge/get-rubric"},{"title":"Update rubric","api":"PATCH /judge/rubrics/{id}","href":"/api-reference/judge/update-rubric"},{"title":"Delete rubric","api":"DELETE /judge/rubrics/{id}","href":"/api-reference/judge/delete-rubric"},{"title":"List runs","api":"GET /judge/evaluations","href":"/api-reference/judge/list-runs"},{"title":"Get run","api":"GET /judge/evaluations/{id}","href":"/api-reference/judge/get-run"},{"title":"Delete run","api":"DELETE /judge/evaluations/{id}","href":"/api-reference/judge/delete-run"},{"title":"Usage","api":"GET /judge/usage","href":"/api-reference/judge/usage"},{"title":"Health","api":"GET /judge/health","href":"/api-reference/judge/health"},{"title":"Pricing \u0026 Billing","href":"/api-reference/judge/pricing"}]},{"group":"Models","pages":[{"title":"Get TTS Models","api":"GET /tts/models","href":"/api-reference/models/get-models"},{"title":"Get STT Models","api":"GET /stt/models","href":"/api-reference/models/get-stt-models"}]},{"group":"Voices","pages":[{"title":"Get Voices","api":"GET /voices","href":"/api-reference/voices/get-voices"},{"title":"Get My Voices","api":"GET /myvoices","href":"/api-reference/voices/get-my-voices"},{"title":"Get Voice by ID","api":"GET /voices/:id","href":"/api-reference/voices/get-voice"},{"title":"Create Voice","api":"POST /voices","href":"/api-reference/voices/create-voice"},{"title":"Update Voice","api":"PUT /voices/:id","href":"/api-reference/voices/update-voice"},{"title":"Delete Voice","api":"DELETE /voices/:id","href":"/api-reference/voices/delete-voice"},{"title":"Get Voice Limits","api":"GET /voices/quota","href":"/api-reference/voices/get-voice-quota"},{"title":"List Professional Voices","api":"GET /voices/professional/jobs","href":"/api-reference/voices/list-professional-voices"},{"title":"Get Marketplace Eligibility","api":"GET /voices/professional/marketplace-eligibility","href":"/api-reference/voices/get-marketplace-eligibility"}]},{"group":"Music","pages":[{"title":"Create Song","api":"POST /songs","href":"/api-reference/music/create-song"},{"title":"List Songs","api":"GET /songs","href":"/api-reference/music/list-songs"},{"title":"Get Song","api":"GET /songs/:id","href":"/api-reference/music/get-song"},{"title":"Update Song","api":"PATCH /songs/:id","href":"/api-reference/music/update-song"},{"title":"Delete Song","api":"DELETE /songs/:id","href":"/api-reference/music/delete-song"},{"title":"Download Song","api":"GET /songs/:id/download","href":"/api-reference/music/download-song"},{"title":"List Voices","api":"GET /songs/voices","href":"/api-reference/music/list-voices"},{"title":"Create Voice","api":"POST /songs/voices","href":"/api-reference/music/create-voice"},{"title":"Health Check","api":"GET /songs/health","href":"/api-reference/music/health"}]},{"group":"Dialer","pages":[{"title":"Get Status","api":"GET /dialer/status","href":"/api-reference/dialer/get-status"},{"title":"Search Numbers","api":"GET /dialer/pool","href":"/api-reference/dialer/search-numbers"},{"title":"Buy Number","api":"POST /dialer/pool/allocate","href":"/api-reference/dialer/buy-number"},{"title":"List Numbers","api":"GET /dialer/numbers","href":"/api-reference/dialer/list-numbers"},{"title":"Release Number","api":"DELETE /dialer/numbers/:e164","href":"/api-reference/dialer/release-number"},{"title":"Set Caller ID","api":"PUT /dialer/caller-id","href":"/api-reference/dialer/set-caller-id"},{"title":"List Calls","api":"GET /dialer/logs","href":"/api-reference/dialer/list-calls"},{"title":"Get Call","api":"GET /dialer/calls/:id","href":"/api-reference/dialer/get-call"},{"title":"Live Calls","api":"GET /dialer/live","href":"/api-reference/dialer/live-calls"},{"title":"Line Status","api":"GET /dialer/calls/line-status","href":"/api-reference/dialer/line-status"},{"title":"Reserve Call","api":"POST /dialer/calls","href":"/api-reference/dialer/reserve-call"},{"title":"List Recordings","api":"GET /dialer/recordings","href":"/api-reference/dialer/list-recordings"},{"title":"Get Playback URL","api":"POST /dialer/recordings/:id/playback-url","href":"/api-reference/dialer/recording-playback-url"},{"title":"Get Transcript","api":"POST /dialer/recordings/:id/transcript","href":"/api-reference/dialer/recording-transcript"},{"title":"Delete Recording","api":"DELETE /dialer/recordings/:id","href":"/api-reference/dialer/delete-recording"},{"title":"Toggle Recording","api":"PUT /dialer/recording","href":"/api-reference/dialer/toggle-recording"},{"title":"List Subscriptions","api":"GET /dialer/subscriptions","href":"/api-reference/dialer/list-subscriptions"},{"title":"Get Usage","api":"GET /dialer/usage","href":"/api-reference/dialer/get-usage"},{"title":"List Webhooks","api":"GET /dialer/webhooks","href":"/api-reference/dialer/list-webhooks"},{"title":"Create Webhook","api":"POST /dialer/webhooks","href":"/api-reference/dialer/create-webhook"},{"title":"Update Webhook","api":"PATCH /dialer/webhooks/:id","href":"/api-reference/dialer/update-webhook"},{"title":"Delete Webhook","api":"DELETE /dialer/webhooks/:id","href":"/api-reference/dialer/delete-webhook"},{"title":"Rotate Webhook Secret","api":"POST /dialer/webhooks/:id/rotate-secret","href":"/api-reference/dialer/webhook-rotate-key"},{"title":"Test Webhook","api":"POST /dialer/webhooks/:id/test","href":"/api-reference/dialer/test-webhook"},{"title":"List Deliveries","api":"GET /dialer/webhooks/:id/deliveries","href":"/api-reference/dialer/list-webhook-deliveries"}]},{"group":"Agents","pages":[{"title":"List Agents","api":"GET /agents","href":"/api-reference/agents/list-agents"},{"title":"Create Agent","api":"POST /agents","href":"/api-reference/agents/create-agent"},{"title":"Get Agent","api":"GET /agents/{agentId}","href":"/api-reference/agents/get-agent"},{"title":"Update Agent","api":"PATCH /agents/{agentId}","href":"/api-reference/agents/update-agent"},{"title":"Delete Agent","api":"DELETE /agents/{agentId}","href":"/api-reference/agents/delete-agent"},{"title":"Rotate Webhook Signing Secret","api":"POST /agents/{agentId}/rotate-webhook-secret","href":"/api-reference/agents/rotate-webhook-signing"},{"title":"Place Call","api":"POST /agents/{agentId}/calls","description":"Place an outbound call as an agent. This rings a real phone and costs money.","href":"/api-reference/agents/place-call"},{"title":"Start Browser Call","api":"POST /agents/{agentId}/web-calls","href":"/api-reference/agents/start-web-call"},{"title":"Hang Up Browser Call","api":"DELETE /agents/web-calls/{callId}","description":"End a browser call started with Start Browser Call.","href":"/api-reference/agents/hang-up-web-call"},{"title":"List Calls","api":"GET /agents/calls","href":"/api-reference/agents/list-calls"},{"title":"Get Call","api":"GET /agents/calls/{callId}","href":"/api-reference/agents/get-call"},{"title":"Get Transcript","api":"GET /agents/calls/{callId}/transcript","href":"/api-reference/agents/get-transcript"},{"title":"Get Recording","api":"GET /agents/calls/{callId}/recording","href":"/api-reference/agents/get-recording"},{"title":"Delete Recording","api":"DELETE /agents/calls/{callId}/recording","href":"/api-reference/agents/delete-recording"},{"title":"List Tool Events","api":"GET /agents/{agentId}/tool-events","href":"/api-reference/agents/list-tool-events"},{"title":"List Phone Lines","api":"GET /agents/phone-lines","href":"/api-reference/agents/list-phone-lines"},{"title":"Create Phone Line","api":"POST /agents/phone-lines","href":"/api-reference/agents/create-phone-line"},{"title":"Get Phone Line","api":"GET /agents/phone-lines/{lineId}","href":"/api-reference/agents/get-phone-line"},{"title":"Update Phone Line","api":"PATCH /agents/phone-lines/{lineId}","href":"/api-reference/agents/update-phone-line"},{"title":"Delete Phone Line","api":"DELETE /agents/phone-lines/{lineId}","href":"/api-reference/agents/delete-phone-line"},{"title":"List Available Numbers","api":"GET /agents/phone-lines/available-numbers","href":"/api-reference/agents/list-available-numbers"}]},{"group":"60db Flow","pages":[{"title":"Get Flow plan","api":"GET /60db/flow/plan","href":"/api-reference/flow/get-plan"},{"title":"List seats","api":"GET /60db/license/:license_id/seats","href":"/api-reference/flow/list-seats"},{"title":"Invite by email","api":"POST /60db/license/:license_id/seats","href":"/api-reference/flow/invite-seat"},{"title":"Remove seat","api":"DELETE /60db/license/:license_id/seats/:user_id","href":"/api-reference/flow/remove-seat"},{"title":"List my invites","api":"GET /60db/license/invites","href":"/api-reference/flow/list-invites"},{"title":"Accept invite","api":"POST /60db/license/:license_id/seats/accept","href":"/api-reference/flow/accept-invite"},{"title":"Decline invite","api":"POST /60db/license/:license_id/seats/decline","href":"/api-reference/flow/decline-invite"}]},{"group":"Click-to-Call","pages":[{"title":"Place Click-to-Call","api":"POST /dialer/click2call","href":"/api-reference/click2call/place-call"},{"title":"Get Click-to-Call","api":"GET /dialer/click2call/{id}","href":"/api-reference/click2call/get-call"},{"title":"List Click-to-Calls","api":"GET /dialer/click2call","href":"/api-reference/click2call/list-calls"},{"title":"List Call Events","api":"GET /dialer/click2call/{id}/events","href":"/api-reference/click2call/list-events"},{"title":"Get Recording URL","api":"POST /dialer/click2call/{id}/recording","href":"/api-reference/click2call/recording-url"},{"title":"Get Click-to-Call Config","api":"GET /dialer/click2call/config","href":"/api-reference/click2call/get-config"},{"title":"Click-to-Call Webhook Events","href":"/api-reference/click2call/webhook-events"}]},{"group":"WhatsApp","pages":[{"title":"Send WhatsApp message","api":"POST /whatsapp/messages","href":"/api-reference/whatsapp/send-message"},{"title":"WhatsApp attachments","href":"/api-reference/whatsapp/media"},{"title":"WhatsApp assistant","href":"/api-reference/whatsapp/assistant"},{"title":"WhatsApp broadcasts","href":"/api-reference/whatsapp/broadcasts"},{"title":"WhatsApp resources","href":"/api-reference/whatsapp/resources"},{"title":"WhatsApp webhook events","href":"/api-reference/whatsapp/webhook-events"}]},{"group":"API Keys","pages":[{"title":"Get API Keys","api":"GET /developer/api","href":"/api-reference/api-keys/get-api-keys"},{"title":"Create API Key","api":"POST /developer/api","href":"/api-reference/api-keys/create-api-key"},{"title":"Delete API Key","api":"DELETE /developer/api/:id","href":"/api-reference/api-keys/delete-api-key"}]},{"group":"Webhooks","pages":[{"title":"Get Webhooks","api":"GET /webhooks","href":"/api-reference/webhooks/get-webhooks"},{"title":"Create Webhook","api":"POST /webhooks","href":"/api-reference/webhooks/create-webhook"},{"title":"Delete Webhook","api":"DELETE /webhooks/:id","href":"/api-reference/webhooks/delete-webhook"}]},{"group":"Workspaces","pages":[{"title":"Get Workspaces","api":"GET /workspaces","href":"/api-reference/workspaces/get-workspaces"},{"title":"Create Workspace","api":"POST /workspaces","href":"/api-reference/workspaces/create-workspace"}]},{"group":"Billing","pages":[{"title":"List Plans","api":"GET /plans","href":"/api-reference/billing/plans"},{"title":"Subscribe to a Plan","api":"POST /billing/subscribe","href":"/api-reference/billing/subscribe"},{"title":"Current Plan","api":"GET /billing/current-plan","href":"/api-reference/billing/current-plan"},{"title":"Top-up Info","api":"GET /billing/topup","href":"/api-reference/billing/topup-info"},{"title":"Top-up Quote","api":"GET /billing/topup/quote","href":"/api-reference/billing/topup-quote"},{"title":"Add Funds","api":"POST /billing/add-funds","href":"/api-reference/billing/add-funds"},{"title":"Usage Logs","api":"GET /billing/usage-logs","href":"/api-reference/billing/usage-logs"},{"title":"Payment Transactions","api":"GET /billing/transactions","href":"/api-reference/billing/transactions"}]},{"group":"Analytics","pages":[{"title":"Get Usage","api":"GET /analytics/usage","href":"/api-reference/analytics/get-usage"}]}]},{"tab":"CLI Reference","pages":[{"title":"CLI Reference","href":"/cli-reference/introduction"}]},{"tab":"MCP Server","pages":[{"title":"MCP Server","href":"/mcp-server/introduction"}]},{"tab":"Codex / Claude","pages":[{"title":"Codex / Claude","href":"/skills/introduction"}]},{"tab":"Integrations","pages":[{"title":"Integrations","href":"/integrations/livekit"}]},{"tab":"Changelog","pages":[{"title":"Changelog","href":"/changelog"}]}]},"basePath":"","title":"Start Browser Call - 60db","buildId":"dpl_345ReqzYaAjzS9QpeJemsKdb7KDj","deploymentId":"dpl_345ReqzYaAjzS9QpeJemsKdb7KDj","dynamics":["c2aa737661","2b790eda92","b0f84f53ff"],"chunks":["OpenApiReferenceProvider-C8RPHPxo.js","utils-0BK-9q6z.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-DfjzsUJT.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-B4v9psJ4.js","snippetPresets-CpTQv-Ez.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-BNP-Fvr0.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-BSgu6h1D.js","shallow-Biv1i9Gs.js","getApiPlaygroundDisplay-BoGOXhtF.js","CodeSnippet-DvQoT18_.js","CodeSnippets-Dnpa15xT.js","Page-Buji1S4J.js","getPastedJson-xAIyhUFE.js","icon-S6FBih11.js","MethodPill-SaYeUZyk.js","DuplicateIcon-Cs-p3v2Q.js","createIcon-DjCFEoHq.js","DynamicMarkdown-BcnBltEQ.js","SectionHeading-BUBl0eEF.js","axios-vUo_bRtp.js"]}