---
title: "Create a realtime voice session"
method: POST
path: "/audio/realtime/sessions"
tags: ["audio"]
---

# Create a realtime voice session

`POST /audio/realtime/sessions`

## Request

- Base URL: `https://api.krater.ai/v1`
- URL: `https://api.krater.ai/v1/audio/realtime/sessions`
- Auth: HTTP bearer

Create an ephemeral realtime voice session. Returns a short-lived client secret for the WebRTC connection plus a reservation_id that must be settled with finalizeRealtimeSession when the call ends.

## Request body

- object
  - `voice` 'alloy' | 'ash' | 'coral' | 'echo' | 'shimmer' | 'verse': Voice for the assistant's audio output.
  - `instructions` string: System instructions for the voice assistant.

## Response `200`

Ephemeral session credentials.

- object
  - `client_secret` string: Ephemeral key used as Bearer auth for the WebRTC SDP exchange.
  - `reservation_id` string: Credit reservation to settle via /audio/realtime/finalize when the session ends.
  - `session_id` string
  - `expires_at` integer: Unix timestamp when the client secret expires.
  - `created_at` string, date-time
  - `voice` string
  - `model` string
  - `webrtc_url` string, uri: WebRTC SDP exchange endpoint.

## Other responses

- `400`: Invalid request body or parameters.
- `401`: Missing or invalid API key. Pass Authorization: Bearer kr_live_...
- `402`: Not enough credits, or the API key's daily credit cap is reached.
- `429`: Rate limit exceeded (default 60 requests per minute per key). Includes a Retry-After header.

---

[API](https://skmtc.dev/krater/apis/krater-api.md) - [All operations](https://skmtc.dev/krater/apis/krater-api/llms.txt) - [OpenAPI document](https://skmtc.dev/krater/apis/krater-api/revisions/66005541188c?raw)
