Skip to main content
POST
GPT Responses (All Models, Full Parameters)
BaseURL: The default BaseURL is https://direct.evolink.ai, which has better support for text models and long-lived connections. https://api.evolink.ai is the primary endpoint for multimodal services and serves as a fallback address for text models.
Server-side tools (web_search, code_interpreter, file_search, mcp) run on the server, so results do not need to be sent back by the client, and they are only available on this API. The Chat Completions endpoint supports regular function tool calling only.
Note This API supports synchronous and streaming modes only: the background: true asynchronous mode is not supported, and there are no endpoints for retrieving, cancelling or deleting a response by its ID. For long-running generations, use stream: true to keep the connection open.The built-in image_generation tool is currently supported only by gpt-6-astra / gpt-6.1-sol / gpt-6-sol / gpt-6-luna, and is unavailable on the other models; for standalone image generation, you can also use the image series model APIs.
Generate images directly with gpt-6-astra / gpt-6.1-sol / gpt-6-sol / gpt-6-luna: declare {"type": "image_generation"} in tools, and the model will generate images as needed in the conversation.
  • Choose an image model: use the tool’s model field to select gpt-image-2 (default), gpt-image-2.5-sunburst, or gpt-image-2.5-flare; quality, size, partial_images, and other parameters follow the official image model parameters (xhigh / max are available only for the 2.5 series)
  • Get the image: images are returned as base64 in the result field of an output item with type set to image_generation_call; this is not a URL, so save the image yourself
  • Image editing: include an input_image in input (a public URL or data:image/png;base64,...) and describe the requested changes in the text
  • Multi-turn editing: pass the previous turn’s id as previous_response_id and describe the changes you want
  • Streaming: set partial_images (0–3) to receive preview events through response.image_generation_call.partial_image during generation
  • Image limit: if max_tool_calls is omitted, a single request can generate up to 4 images; set it explicitly if you need more
  • Billing: text and image generation are billed separately by token; image generation token usage is reported in tool_usage.image_gen in the response
Multi-turn conversations: pass the id returned by the previous turn as previous_response_id on the next turn to continue the context. Responses have a retention period; once it expires the ID is no longer valid and the request is handled as a new conversation. For scenarios with strict context-accuracy requirements, maintaining the full input history yourself is recommended.

Authorizations

Authorization
string
header
required

##All APIs require Bearer Token authentication##

Get API Key:

Visit API Key Management Page to get your API Key

Add to request header:

Body

application/json
model
enum<string>
required

Model to call:

Available options:
gpt-6.1-sol,
gpt-6-astra,
gpt-6-sol,
gpt-6-luna,
gpt-5.6-sol,
gpt-5.6-terra,
gpt-5.6-luna,
gpt-5.5,
gpt-5.4,
gpt-5.2,
gpt-5.1
Example:

"gpt-6.1-sol"

input
required

Model input: a plain string, or an array of input items.

The content of an input item supports two block types: input_text (text) and input_image (image):

Image

  • Pass the public URL of the image in image_url
  • image_url must be a string; writing it as { "url": "..." } returns 400
  • detail is a sibling of image_url (not nested inside it): auto (default) / low / high / original
  • The image must be downloadable, otherwise 400 is returned

Tool results

  • The array can also carry back tool result items from the previous turn, such as function_call_output

Note The block types on this API differ from those on the Chat Completions API (which uses text / image_url). They cannot be mixed; using the wrong ones returns 400.

Example:

"Search for AI news from the past week and summarize it in three sentences."

instructions
string

System-level instructions, equivalent to inserting a system message at the very beginning of input. When continuing a conversation with previous_response_id, this parameter is not inherited from the previous turn and must be passed on every turn.

Example:

"You are a concise assistant. Answer in no more than three sentences."

stream
boolean
default:false

Whether to return a streaming response (SSE events, ending with response.completed). Default false.

Example:

false

max_output_tokens
integer

Maximum number of tokens to generate (including reasoning tokens). When the limit is reached, status is incomplete.

GPT-6 Astra / Sol / Luna and GPT-6.1 Sol support up to 128,000 output tokens, including reasoning tokens.

Example:

2048

reasoning
object

Reasoning control.

The allowed values of effort (reasoning depth) vary by model:

summary (reasoning summary): auto / concise / detailed.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

mode (reasoning mode): standard / pro, supported by gpt-6-astra / gpt-6-sol / gpt-6-luna and the gpt-5.6 family.

GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

context (reasoning context scope): auto / current_turn / all_turns, supported by gpt-6-astra and the gpt-5.6 family.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

Reasoning tokens are billed as output tokens and counted in usage.output_tokens_details.reasoning_tokens.

GPT-6 Sol / Luna are supported: set model to gpt-6-sol or gpt-6-luna. Both have a 1,050,000-token context window and a maximum output of 128,000 tokens, including reasoning. reasoning.effort supports none, low, medium (default), high, xhigh, and max; Astra and 6.1 Sol do not support none. Use this endpoint for reasoning with tools.

text
object

Output text control:

  • format: {"type": "text"} (default), {"type": "json_object"}, or {"type": "json_schema", "name": "...", "schema": {...}, "strict": true} for structured output
  • verbosity: low / medium / high, controls how detailed the answer is

text.verbosity — GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

tools
object[]

Tool declarations. Server-side tools run on the server, so results do not need to be sent back by the client:

Plain function tools (client-side function calls) are supported as well.

Note The built-in image_generation tool is currently supported only by gpt-6-astra / gpt-6.1-sol / gpt-6-sol / gpt-6-luna, and is unavailable on the other models; for standalone image generation, you can also use the image series model APIs.

Example:
tool_choice

Controls tool selection: "auto" (default) / "none" / "required", or an object pinning a specific tool, e.g. {"type": "web_search"}.

Available options:
none,
auto,
required
max_tool_calls
integer

Maximum total number of tool calls allowed in this response (across all built-in tools).

Note When gpt-6-astra / gpt-6.1-sol / gpt-6-sol / gpt-6-luna uses image_generation and this parameter is omitted, a single request can generate up to 4 images; set it explicitly if you need more.

Example:

5

parallel_tool_calls
boolean
default:true

Whether the model may call multiple tools in parallel within one turn. Defaults to true.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note gpt-6-astra, the gpt-5.6 family, and gpt-5.5 support setting this parameter to false; on gpt-5.4 / gpt-5.2 / gpt-5.1, it has no effect and always behaves as true.

Example:

true

previous_response_id
string

The id of the previous response, used to chain multi-turn conversations without re-uploading the history.

Note Must be used together with store: true (the default). Responses have a retention period; once it expires the ID is no longer valid, and the request is handled as a new conversation without inheriting context. For scenarios with strict context-accuracy requirements, maintaining the full input history yourself is recommended.

Example:

"resp_0f5c2b2c20c39e8a006a7ef545443081979e478b10927984b5"

store
boolean
default:true

Whether to store this response on the server; only stored responses can be referenced by previous_response_id. Defaults to true.

GPT-6 Sol / Luna and GPT-6.1 Sol: disabling retention with store: false has not been verified on the available channels. Acceptance of the field alone does not establish that the response was not retained.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note gpt-6-astra, the gpt-5.6 family, and gpt-5.5 support setting this parameter to false; on gpt-5.4 / gpt-5.2 / gpt-5.1, it has no effect and always behaves as true. If you do not want responses stored, choose a model that supports turning it off.

Example:

true

include
string[]

Additional content to return in the response. Allowed values:

  • reasoning.encrypted_content
  • message.output_text.logprobs
  • web_search_call.results
  • web_search_call.action.sources
  • file_search_call.results
  • code_interpreter_call.outputs
  • message.input_image.image_url
  • computer_call_output.output.image_url

Note message.output_text.logprobs is not supported by gpt-6-astra or gpt-6.1-sol.

GPT-6: Astra and 6.1 Sol do not support output logprobs. For Sol / Luna, use them only with reasoning effort none. At other levels, remove logprobs, top_logprobs, and message.output_text.logprobs from Responses include.

Example:
temperature
number

Sampling temperature, ranging from 0 to 2. Lower values make the output more deterministic.

GPT-6: omit this parameter for gpt-6-astra and gpt-6.1-sol. For gpt-6-sol / gpt-6-luna, adjust it only with reasoning effort set to none; omit it at other effort levels. Omitting effort selects medium, not none.

Existing models: gpt-5.4 / gpt-5.2 / gpt-5.1 treat temperature: 0 as the default 1; use a positive value such as 0.01 for more deterministic output.

Required range: 0 <= x <= 2
Example:

1

top_p
number

Nucleus sampling parameter, ranging from 0 to 1. Adjusting it together with temperature is not recommended.

GPT-6: omit this parameter for gpt-6-astra and gpt-6.1-sol. For gpt-6-sol / gpt-6-luna, adjust it only with reasoning effort set to none; omit it at other effort levels. Omitting effort selects medium, not none.

Required range: 0 <= x <= 1
Example:

1

top_logprobs
integer

Number of candidate tokens returned at each position, ranging from 0 to 20; must be used together with include: ["message.output_text.logprobs"].

GPT-6: Astra and 6.1 Sol do not support output logprobs. For Sol / Luna, use them only with reasoning effort none. At other levels, remove logprobs, top_logprobs, and message.output_text.logprobs from Responses include.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note Supported only by the gpt-5.6 family and gpt-5.5; other models do not support this parameter.

Required range: 0 <= x <= 20
Example:

2

frequency_penalty
number

Frequency penalty, ranging from -2 to 2, reducing the likelihood of repeated content.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note Adjustable on the gpt-5.6 family; the other existing models do not support this parameter. GPT-6 Astra does not allow adjustment and accepts only the default value 0; passing any other value returns 400.

Required range: -2 <= x <= 2
Example:

0

presence_penalty
number

Presence penalty, ranging from -2 to 2, encouraging the model to talk about new topics.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note Adjustable on the gpt-5.6 family; the other existing models do not support this parameter. GPT-6 Astra does not allow adjustment and accepts only the default value 0; passing any other value returns 400.

Required range: -2 <= x <= 2
Example:

0

truncation
enum<string>
default:disabled

How to handle context that exceeds the window: disabled (default, returns an error) or auto (automatically truncates the middle of the context).

Available options:
auto,
disabled
Example:

"auto"

context_management
object[]

Automatic compaction configuration for long conversations, for example [{"type": "compaction", "compact_threshold": 100000}]: the history is compacted automatically once the context exceeds the threshold.

Note Supported only by gpt-6-astra / gpt-6-sol / gpt-6-luna and the gpt-5.6 family; other models do not support this parameter.

GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

prompt_cache_key
string

Cache grouping key. GPT-6 / GPT-5.6 route cache traffic automatically; this field is not needed to optimize routing. Separate keys can distinguish cache reuse and accounting for customers or users. Keep the key stable for requests that should reuse a prefix. Earlier models can use stable keys to help cache routing.

Example:

"app-agent-v1"

prompt_cache_retention
enum<string>

Legacy model cache retention. For GPT-6 / GPT-5.6, use prompt_cache_options.ttl: "30m"; do not use 24h in the new field.

Available options:
in_memory,
24h
Example:

"in_memory"

prompt
object

References an already created prompt template, in the form {"id": "pmpt_xxx", "version": "1", "variables": {...}}.

metadata
object

Custom key-value pairs returned as-is with the response, convenient for tagging on the business side. Both keys and values are strings.

Example:
safety_identifier
string

Stable identifier of the end user, used for abuse tracking.

GPT-6 Sol / Luna and GPT-6.1 Sol: support for this parameter has not been confirmed; omit it from basic requests.

Rules for existing models below exclude GPT-6 Sol / Luna and GPT-6.1 Sol:

Note Supported only by gpt-6-astra and the gpt-5.6 family; other models do not support this parameter.

Example:

"user-1024"

user
string

End-user identifier, used to distinguish the source of calls.

Example:

"user-1024"

prompt_cache_options
object

Prompt caching options for GPT-6 and GPT-5.6. Implicit breakpoints are the default. mode: "explicit" uses only explicit breakpoints; without one, no caching occurs.

Example:

Response

Response generated successfully (JSON object, or an SSE event stream ending with response.completed when stream=true)

id
string

Unique ID of this response, which can be used as previous_response_id for the next turn

Example:

"resp_0f5c2b2c20c39e8a006a7ef545443081979e478b10927984b5"

object
enum<string>

Response type

Available options:
response
Example:

"response"

status
enum<string>

Response status: completed for a normal ending, incomplete when generation stopped early for reasons such as reaching max_output_tokens, failed when generation failed

Available options:
completed,
incomplete,
failed
Example:

"completed"

model
string

Actual model name used

Example:

"gpt-6.1-sol"

created_at
integer

Creation timestamp

Example:

1786705221

output
object[]

Output items in generation order: the reasoning item (reasoning summary / encrypted reasoning content), tool call items (such as web_search_call, code_interpreter_call, and image_generation_call), and finally the message item containing output_text content.

incomplete_details
object

Explains the reason when status is incomplete

usage
object

Token usage statistics. Prompt caching applies automatically, and cached input tokens are billed at the lower cached rate.

GPT-6 bills uncached input, cache reads, cache writes, and output separately. Above 272,000 input tokens, the entire request uses 2× the regular input and cache rates and 1.5× the output rate. Built-in image generation is billed separately. See current model pricing.

tool_usage
object

Built-in tool usage. When using image_generation, image_gen records the tokens consumed by image generation, tracked separately from usage and billed separately by token

metadata
object

Custom key-value pairs passed in the request, returned as-is