API Reference
Responses
Create multimodal responses with the OpenAI Responses-style API.
The Responses API uses input as a unified input field. It is designed for newer OpenAI Responses-style models and supports streaming, tools, reasoning options and response continuation.
Endpoints
| Method | Path | Description |
|---|---|---|
POST | /v1/responses | Create a response |
POST | /v1/responses/compact | Responses compaction API with fewer fields |
Request Fields
| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model ID |
input | string or array | Yes | Input content. Can include input_text, input_image and input_file |
instructions | string | No | System-level instructions |
stream | boolean | No | Return an SSE stream |
max_output_tokens | integer | No | Maximum output tokens |
temperature, top_p | number | No | Sampling controls |
tools, tool_choice | array/object | No | Tool configuration |
parallel_tool_calls | boolean | No | Allow parallel tool calls |
max_tool_calls | integer | No | Maximum tool calls |
previous_response_id | string | No | Continue from a previous response |
reasoning | object | No | Reasoning options such as effort and summary |
text | object | No | Text output configuration |
include, truncation | any | No | OpenAI Responses extension fields |
metadata, user | any | No | Metadata or user identifier |
store, service_tier, safety_identifier | any | No | OpenAI extension fields; channel settings may filter them |
curl
curl https://api.tensoraxis.ai/v1/responses \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $TENSORAXIS_API_KEY" \
-d '{
"model": "gpt-4o",
"input": "Explain what an API gateway is in two sentences"
}'Multimodal Input
{
"model": "gpt-4o",
"input": [
{
"role": "user",
"content": [
{"type": "input_text", "text": "Describe this image"},
{"type": "input_image", "image_url": "https://example.com/image.png"}
]
}
]
}Compaction API
/v1/responses/compact accepts a smaller request body:
| Field | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Model ID |
input | any | No | Input to compact |
instructions | any | No | Instructions |
previous_response_id | string | No | Previous response ID |
Response Shape
Responses follow the OpenAI Responses-style shape. Core fields include id, model, output and usage. Streaming responses return incremental content as SSE events.