Type Alias LiveClientEvent
LiveClientEvent:
| {
event_id: string;
session: {
audio?: {
format?: { rate?: number; type: string };
output?: { voice?: string };
};
delegation?: {
responses?: {
max_output_tokens?: number;
model: string;
reasoning?: { effort?: string };
tools?: {
description?: string;
name: string;
parameters?: Record<string, unknown>;
type: "function";
}[];
};
type: "client"
| "responses";
};
instructions?: string;
model: string;
parallel_tool_calls?: boolean;
};
type: "session.start";
}
| { audio: string; event_id: string; type: "session.input_audio.append" }
| {
content: string;
delegation_id: string | null;
event_id: string;
type: "session.commentary.append";
}
| {
content: string;
delegation_id: string
| null;
event_id: string;
type: "session.thinking.append";
}
| {
event_id: string;
instructions: string;
type: "session.instructions.append";
}
| {
event_id: string;
item: { call_id: string; output: string; type: "function_call_output" };
type: "response.item.create";
}
| { event_id: string; type: "response.create" }
| { event_id: string; type: "session.close" }
Wire client events for OpenAI Live Realtime API.