Skip to content
Niu DocsNiu 牛元文档
Dashboard控制台

ChatCompletionResponse

Generated from the checked-in source. Do not edit this reference by hand.

SDK source. All SDK types.

TypeScript
export type ChatCompletionResponse = {
id: string;
object: string;
model: string;
choices: Array<{
index: number;
message: ChatMessage & {
tool_calls?: ChatToolCall[];
refusal?: string | null;
};
finish_reason: string | null;
}>;
usage?: {
prompt_tokens: number;
completion_tokens: number;
total_tokens?: number;
};
};