发送对话消息
创建会话消息。
POST
Authorizations
API-Key 鉴权。所有 API 请求都应在 Authorization HTTP Header 中包含您的 API-Key,格式为:Bearer {API_KEY}。强烈建议开发者把 API-Key 放在后端存储,而非客户端,以免泄露。
Body
application/json
发送对话消息的请求体。
The body is of type object
.
Response
200
application/json
请求成功。响应的内容类型和结构取决于请求中的 response_mode
参数。
- 当
response_mode
为blocking
时,返回application/json
格式的ChatCompletionResponseCn
对象。 - 当
response_mode
为streaming
时,返回text/event-stream
格式的ChunkChatEventCn
对象流式序列。
阻塞模式下的完整 App 结果。