Skip to content
For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation
Theme

Accept call

client.live.sessions.accept(sessionID, body, options?): void
POST
/live/sessions/{session_id}/accept

Accept an incoming SIP call. Supply session with type live, the model, and startup configuration. Before accepting calls, follow the Live prompting guide to write frontend conversation instructions and a separate backend prompt. SIP media format is negotiated; omit audio.format.

Parameters
sessionID: string
body: SessionAcceptParams { session }

Accept call

import OpenAI from 'openai';

const client = new OpenAI({
  apiKey: process.env['OPENAI_API_KEY'], // This is the default and can be omitted
});

await client.live.sessions.accept('session_id', { session: { model: 'gpt-live-1', type: 'live' } });
Returns Examples