provider Realtime POST
/realtime/sessions @utdk/openai
/realtime/sessions Create an ephemeral API token for use in client-side applications with the
Realtime API. Can be configured with the same session parameters as the
`session.update` client event.
It responds with a session object, plus a `client_secret` key which contains
a usable ephemeral API token that can be used to authenticate browser clients
for the Realtime API.
Try it
Authentication
Configure credentials for OpenAI API
Gateway
The gateway proxies requests and injects credentials server-side. Configure credentials above, then enter your gateway URL.
Saved automatically to browser storage.
Code snippet
Updates live as you fill in the form above.
TypeScript
import openai from '@utdk/openai';
await openai.createRealtimeSession({
"input_audio_format": "pcm16",
"output_audio_format": "pcm16",
"input_audio_noise_reduction": "null",
"tool_choice": "auto",
"temperature": 0.8
})