Configuration for audio output format.

interface AudioResponseFormat {
    bit_rate?: number;
    delivery?: "inline" | "uri";
    mime_type?:
        | "audio/wav"
        | "audio/mp3"
        | "audio/l16"
        | "audio/alaw"
        | "audio/mulaw"
        | "audio/ogg_opus";
    sample_rate?: number;
    type: "audio";
}

Properties

bit_rate?: number

Bit rate in bits per second (bps). Only applicable for compressed formats (MP3, Opus).

delivery?: "inline" | "uri"

The delivery mode for the audio output.

mime_type?:
    | "audio/wav"
    | "audio/mp3"
    | "audio/l16"
    | "audio/alaw"
    | "audio/mulaw"
    | "audio/ogg_opus"

The MIME type of the audio output.

sample_rate?: number

Sample rate in Hz.

type: "audio"