---
title: "Prepare a Spectra-2 session"
method: POST
path: "/v1/audio/sessions"
tags: ["Audio"]
---

# Prepare a Spectra-2 session

`POST /v1/audio/sessions`

## Request

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

Prepare before recording. The session has a 30-second lifetime including setup and uses the same account allowance as ordinary requests. Keep API keys on your server.

## Request body

- object
  - `model` 'oruk-spectra-2', required
  - `id` string, uuid, required: A new UUID v4 for this setup attempt.

## Response `200`

Prepared connection; no inference has run.

- Spectra2PreparedSession
  - `object` 'speech.session', required
  - `model` 'oruk-spectra-2', required
  - `token` string, required: Keep private. Send as X-Oruk-Session with the same API key.
  - `expires_at_ms` integer, required: Unix time in milliseconds; preparation does not extend this deadline.
  - `capacity_seconds` integer: Advisory remaining audio capacity for this new session. Deduct each recording duration rounded up to a whole second before dispatch, including uncertain attempts. The server independently enforces capacity and expiry.
  - `request_ids` string[], required: Use a different supplied ID for each new recording. Retain it if completion is uncertain.

## Other responses

- `400`: Invalid model, task, session, or request ID.
- `401`: An Oruk API bearer key is required.
- `402`: Insufficient account allowance or credits.
- `403`: Account access is unavailable, or a server-only request was made from a browser.
- `404`: Preparation is unavailable for this session. Choose an ordinary speech request before recording.
- `409`: The session expired or direct streaming is unavailable. Choose a new session or an ordinary stream before recording.
- `429`: Session setup is busy. Wait before preparing another recording.
- `503`: Setup could not be confirmed. No inference was requested; an existing reservation can remain until expiry.

---

[API](https://skmtc.dev/oruk/apis/oruk-speech-api.md) · [All operations](https://skmtc.dev/oruk/apis/oruk-speech-api/llms.txt) · [OpenAPI document](https://skmtc.dev/oruk/apis/oruk-speech-api/revisions/c668cecab401?raw)
