Create a model response
Creates a model response. Provide text or image inputs to generate text or JSON outputs. Have the model call the function tools you define. When stream is true, the response is delivered as a stream of SSE events.
Request
- Base URL: https://api.moonshot.ai
- URL: https://api.moonshot.ai/v1/responses
- Auth: HTTP bearer
Headers
A client-generated random nonce (a UUID v4 is recommended). Sending it enables Request Signature: the Kimi API returns Msh-Request-Timestamp and Msh-Request-Signature in the response headers, which can later be used to prove that the request was handled by the Kimi API. Exactly one non-empty header value is allowed; if the value is invalid, the request proceeds normally but the headers above are not returned. See Verify Request Signature.
Request body
Response
The response was created
Example response
{
"id": "resp_68f0c1c2d3e4f5a6b7c8d9e0",
"output": [
{
"id": "rs_68f0c1c2d3e4f5a6b7c8d9e0"
}
]
}Changes
No recorded changes to this operation across all 1 revision of this API.