简体中文
cURL
curl --request POST \ --url https://proxy.innk.cc/v1/chat/completions \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "model": "<string>", "messages": [ { "role": "user", "content": "Hello, how are you?" } ], "stream": false, "max_completion_tokens": 123, "temperature": 1, "top_p": 1 } '
{ "id": "<string>", "object": "<string>", "created": 123, "model": "<string>", "choices": [ { "index": 123, "message": { "role": "<string>", "content": "<string>" }, "finish_reason": "<string>" } ], "usage": { "prompt_tokens": 123, "completion_tokens": 123, "total_tokens": 123, "prompt_tokens_details": { "cached_tokens": 123, "audio_tokens": 123 }, "completion_tokens_details": { "reasoning_tokens": 123, "audio_tokens": 123, "accepted_prediction_tokens": 123, "rejected_prediction_tokens": 123 } } }
Creates a model response for the given chat conversation.
身份验证标头格式为 Bearer <API_KEY>,其中 <API_KEY> 是您的API令牌。
Bearer <API_KEY>
<API_KEY>
要使用的模型的 ID。
以聊天格式生成聊天完成的消息。
显示 子属性
角色
user
system
developer
assistant
文本内容
"Hello, how are you?"
是否流式对话
最大完成令牌数
温度
核采样
Model response
请求ID标识符
对象类型
创建时间
模型版本
索引
内容
完成原因
用量
提示词令牌数
完成令牌数
总令牌数
此页面对您有帮助吗?