Create Response (Responses)
/v1/responsesGenerate text with Nex N2.6 through the Responses API. Both synchronous and streaming responses are supported.
For MOSS-VL, see Create Response (VL).
| Model | Input | Execution mode |
|---|---|---|
| Nex N2.6 | Supports plain text. Use input_image for images, and pass video through video_url (MP4, WebM). file_id is not supported yet. | Synchronous or SSE streaming. The client sends the multi-turn history. |
| MOSS-VL | A text instruction and an image or video must both be provided. Media supports a URL or file_id. | Synchronous. |
Authentication and setup
All valid MOSS API Keys can call it. Use Authorization: Bearer <API Key> and Content-Type: application/json.
Production HTTP requests use https://api.mosi.cn. Before running the examples, set MOSS_API_ORIGIN to https://api.mosi.cn and MOSS_API_KEY to your MOSS API key. Set the OpenAI SDK base_url to https://api.mosi.cn/v1.
Request parameters
Use nex-n2.6 or the pinned snapshot nex-n2.6-2026-11-05.
For text-only input, pass a string. For multi-turn requests, pass the history in an array. Use input_image for images and video_url for MP4 or WebM video.
Output token budget. The production default is 8,192 and the maximum is 131,072.
Set to false for stateless requests.
Set to true to stream the response.
Optional. If supplied, use 2026-11-05 and make sure it matches the snapshot selected by model.
Responses is stateless. Include conversation history in input. previous_response_id, conversation, background: true, server-side sessions, files, and asset library references are currently unsupported. Public media URLs must be accessible to MOSS. The entire request body, including encoded media, must be at most 10 MiB.
Response fields
The model snapshot used to generate the response.
completed means the response finished. incomplete means the output is incomplete.
Read content with type set to output_text from the message item's content array.
Set to max_output_tokens when the output reaches the budget.
Token usage. On successful streaming completion, read it from response.usage in response.completed.
Termination states
For multi-turn requests, the client sends the relevant history. Use store: false and omit previous_response_id.
| Result | Client behavior |
|---|---|
completed / response.completed | Successful completion. Use the accumulated text and the usage supplied in the response. |
incomplete / response.incomplete | Keep any generated content and available usage. If the reason is max_output_tokens, report that the output reached its budget or adjust the budget and retry. |
error / response.failed | Treat this as failure. Before streaming starts, check the HTTP response. After streaming starts, handle the failure event. |