> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anyfast.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# gpt-6-astra

> Create GPT-6 Astra text, vision, file-analysis, structured-output, and tool-using responses.

GPT-6 Astra uses the Responses API for text, image and file input, Structured Outputs, and tool workflows. Select a tab for the request shape you need.

<Info>
  `gpt-6-astra` also accepts text requests through `POST /v1/chat/completions`. Use this Responses API reference for reasoning controls, tools, image and file input, Structured Outputs, streaming, and prompt caching.
</Info>

<Tabs sync={false}>
  <Tab title="Text and reasoning">
    ## Create response

    `POST /v1/responses`

    <div className="kling-api-example-panel">
      ```bash cURL theme={null}
      curl --request POST \
        --url https://www.anyfast.ai/v1/responses \
        --header 'Authorization: Bearer YOUR_API_KEY' \
        --header 'Content-Type: application/json' \
        --data '{
          "model": "gpt-6-astra",
          "instructions": "Act as a senior reliability engineer.",
          "input": "Review this retry design and propose a safe implementation plan.",
          "reasoning": { "effort": "high", "summary": "auto" },
          "text": { "verbosity": "medium" },
          "max_output_tokens": 4096,
          "store": true
        }'
      ```
    </div>

    ## Request headers

    <ParamField header="Authorization" type="string" required>Bearer authentication in the form `Bearer YOUR_API_KEY`.</ParamField>
    <ParamField header="Content-Type" type="string" default="application/json" required>Data exchange format.</ParamField>

    ## Request body

    <ParamField body="model" type="string" required>AnyFast model ID. Use `gpt-6-astra`.</ParamField>
    <ParamField body="input" type="string | object[]" required>Text or an ordered list of message, image, file, and tool-result items.</ParamField>
    <ParamField body="instructions" type="string">System or developer instructions inserted into the model context.</ParamField>
    <ParamField body="reasoning" type="object">Reasoning configuration.</ParamField>
    <ParamField body="reasoning.effort" type="string">`low`, `medium`, `high`, `xhigh`, or `max`. `none` and `minimal` are not supported.</ParamField>
    <ParamField body="reasoning.summary" type="string">`auto`, `concise`, or `detailed`.</ParamField>
    <ParamField body="reasoning.context" type="string">`auto`, `current_turn`, or `all_turns`.</ParamField>
    <ParamField body="reasoning.mode" type="string">Use `standard`. The current AnyFast route does not expose GPT-6 Astra Pro mode.</ParamField>
    <ParamField body="max_output_tokens" type="integer">Maximum visible-output and reasoning tokens. Maximum: `128000`.</ParamField>
    <ParamField body="text.verbosity" type="string">`low`, `medium`, or `high`.</ParamField>
    <ParamField body="include" type="string[]">Additional response data. Use `reasoning.encrypted_content` for encrypted reasoning items. Do not use `message.output_text.logprobs`.</ParamField>
    <ParamField body="prompt_cache_key" type="string">Stable key that improves cache matching for related requests.</ParamField>
    <ParamField body="prompt_cache_options" type="object">Prompt-cache options. `mode` selects implicit or explicit breakpoints; `ttl` currently supports `30m`; `comparison_response_id` requests comparison diagnostics.</ParamField>
    <ParamField body="prompt_cache_options.mode" type="string">`implicit` or `explicit`.</ParamField>
    <ParamField body="prompt_cache_options.ttl" type="string" default="30m">Currently only `30m` is supported.</ParamField>
    <ParamField body="input[].content[].prompt_cache_breakpoint" type="object">Marks an explicit reusable-prefix boundary. Use `{ "mode": "explicit" }`.</ParamField>
    <ParamField body="metadata" type="object">Application-defined string key-value pairs.</ParamField>
    <ParamField body="stream" type="boolean" default={false}>Stream response events over SSE.</ParamField>
    <ParamField body="stream_options.include_obfuscation" type="boolean">Controls event obfuscation for streaming responses.</ParamField>
    <ParamField body="store" type="boolean" default={true}>Controls upstream response storage. AnyFast does not expose response retrieval.</ParamField>
    <ParamField body="truncation" type="string" default="disabled">Use `disabled` on the current AnyFast route.</ParamField>

    <Warning>Do not send `temperature`, `top_p`, or `top_logprobs`. GPT-6 Astra also does not support `message.output_text.logprobs` in `include`.</Warning>
    <Warning>AnyFast does not expose Responses retrieval, Conversations, or Vector Stores management. Do not use `background`, `conversation`, `previous_response_id`, stored prompt references, or `configuration_update`.</Warning>

    ## Response

    <div className="kling-api-example-panel">
      ```json 200 theme={null}
      {
        "id": "resp_01astraexample",
        "object": "response",
        "created_at": 1788460800,
        "completed_at": 1788460802,
        "model": "gpt-6-astra",
        "status": "completed",
        "output": [
          { "id": "rs_01reasoning", "type": "reasoning", "summary": [] },
          {
            "id": "msg_01astraexample",
            "type": "message",
            "status": "completed",
            "role": "assistant",
            "content": [{
              "type": "output_text",
              "text": "Use bounded exponential backoff, idempotency keys, and a single retry owner.",
              "annotations": []
            }]
          }
        ],
        "output_text": "Use bounded exponential backoff, idempotency keys, and a single retry owner.",
        "usage": {
          "input_tokens": 38,
          "input_tokens_details": { "cached_tokens": 0, "cache_write_tokens": 0 },
          "output_tokens": 124,
          "output_tokens_details": { "reasoning_tokens": 82 },
          "total_tokens": 162
        },
        "error": null,
        "incomplete_details": null
      }
      ```
    </div>

    <ResponseField name="id" type="string">Response ID.</ResponseField>
    <ResponseField name="object" type="string">Always `response`.</ResponseField>
    <ResponseField name="status" type="string">`queued`, `in_progress`, `completed`, `incomplete`, `failed`, or `cancelled`.</ResponseField>
    <ResponseField name="output" type="object[]">Ordered reasoning, message, and tool-call output items.</ResponseField>
    <ResponseField name="output_text" type="string">Convenience aggregation of text output when available.</ResponseField>
    <ResponseField name="usage" type="object">Input, output, cached, cache-write, and reasoning token usage.</ResponseField>
    <ResponseField name="incomplete_details" type="object | null">Why a response ended incomplete.</ResponseField>
    <ResponseField name="error" type="object | null">Error details for a failed response.</ResponseField>
  </Tab>

  <Tab title="Image and file input">
    ## Create response

    `POST /v1/responses`

    <div className="kling-api-example-panel">
      ```bash cURL theme={null}
      curl --request POST \
        --url https://www.anyfast.ai/v1/responses \
        --header 'Authorization: Bearer YOUR_API_KEY' \
        --header 'Content-Type: application/json' \
        --data '{
          "model": "gpt-6-astra",
          "input": [{
            "role": "user",
            "content": [
              { "type": "input_text", "text": "Compare the diagram with the deployment notes and list conflicts." },
              { "type": "input_image", "image_url": "data:image/png;base64,<BASE64_IMAGE_DATA>", "detail": "high" },
              { "type": "input_file", "filename": "deployment-notes.pdf", "file_data": "data:application/pdf;base64,<BASE64_PDF_DATA>" }
            ]
          }],
          "reasoning": { "effort": "high" }
        }'
      ```
    </div>

    ## Request body

    <ParamField body="model" type="string" required>Use `gpt-6-astra`.</ParamField>
    <ParamField body="input" type="object[]" required>Ordered Responses API input items.</ParamField>
    <ParamField body="input[].role" type="string" required>`user`, `assistant`, `system`, or `developer`.</ParamField>
    <ParamField body="input[].content" type="string | object[]" required>Text, image, or file content parts.</ParamField>
    <ParamField body="input[].content[].type" type="string" required>`input_text`, `input_image`, or `input_file`.</ParamField>
    <ParamField body="input[].content[].text" type="string">Text for an `input_text` part.</ParamField>
    <ParamField body="input[].content[].image_url" type="string">Public URL or data URL for an `input_image` part.</ParamField>
    <ParamField body="input[].content[].detail" type="string">`auto`, `low`, or `high`.</ParamField>
    <ParamField body="input[].content[].filename" type="string">Filename for inline file data.</ParamField>
    <ParamField body="input[].content[].file_data" type="string">Data URL containing Base64-encoded inline file data.</ParamField>

    <Info>Public image URLs must allow server-side downloads. Data URLs and inline files are supported. Audio and video are not supported GPT-6 Astra input modalities.</Info>

    ## Response

    <div className="kling-api-example-panel">
      ```json 200 theme={null}
      {
        "id": "resp_01visionexample",
        "object": "response",
        "model": "gpt-6-astra",
        "status": "completed",
        "output": [{
          "id": "msg_01visionexample",
          "type": "message",
          "status": "completed",
          "role": "assistant",
          "content": [{
            "type": "output_text",
            "text": "The diagram uses two retry owners, while the notes require one.",
            "annotations": []
          }]
        }],
        "usage": { "input_tokens": 842, "output_tokens": 67, "total_tokens": 909 }
      }
      ```
    </div>

    <ResponseField name="output[].type" type="string">Output item type, such as `message` or `reasoning`.</ResponseField>
    <ResponseField name="output[].content[].type" type="string">Content type, such as `output_text`.</ResponseField>
    <ResponseField name="output[].content[].text" type="string">Generated text.</ResponseField>
    <ResponseField name="output[].content[].annotations" type="object[]">Citations and annotations when present.</ResponseField>
  </Tab>

  <Tab title="Structured output">
    ## Create response

    `POST /v1/responses`

    <div className="kling-api-example-panel">
      ```bash cURL theme={null}
      curl --request POST \
        --url https://www.anyfast.ai/v1/responses \
        --header 'Authorization: Bearer YOUR_API_KEY' \
        --header 'Content-Type: application/json' \
        --data '{
          "model": "gpt-6-astra",
          "input": "Classify the deployment risk.",
          "text": {
            "format": {
              "type": "json_schema",
              "name": "deployment_risk",
              "strict": true,
              "schema": {
                "type": "object",
                "properties": {
                  "risk": { "type": "string", "enum": ["low", "medium", "high"] },
                  "reason": { "type": "string" }
                },
                "required": ["risk", "reason"],
                "additionalProperties": false
              }
            }
          }
        }'
      ```
    </div>

    ## Request body

    <ParamField body="model" type="string" required>Use `gpt-6-astra`.</ParamField>
    <ParamField body="input" type="string | object[]" required>Prompt and optional context.</ParamField>
    <ParamField body="text.format.type" type="string" required>Use `json_schema` or `text`.</ParamField>
    <ParamField body="text.format.name" type="string">Schema name.</ParamField>
    <ParamField body="text.format.description" type="string">Description of the expected output.</ParamField>
    <ParamField body="text.format.schema" type="object" required>JSON Schema that defines the response.</ParamField>
    <ParamField body="text.format.strict" type="boolean">Enforce strict schema adherence.</ParamField>

    ## Response

    <div className="kling-api-example-panel">
      ```json 200 theme={null}
      {
        "id": "resp_01structuredexample",
        "object": "response",
        "model": "gpt-6-astra",
        "status": "completed",
        "output": [{
          "id": "msg_01structuredexample",
          "type": "message",
          "status": "completed",
          "role": "assistant",
          "content": [{
            "type": "output_text",
            "text": "{\"risk\":\"medium\",\"reason\":\"Retries are not idempotent.\"}",
            "annotations": []
          }]
        }]
      }
      ```
    </div>

    <ResponseField name="output[].content[].text" type="string">JSON text that conforms to the supplied schema.</ResponseField>
  </Tab>

  <Tab title="Tool workflows">
    ## Create response

    `POST /v1/responses`

    <div className="kling-api-example-panel">
      ```bash cURL theme={null}
      curl --request POST \
        --url https://www.anyfast.ai/v1/responses \
        --header 'Authorization: Bearer YOUR_API_KEY' \
        --header 'Content-Type: application/json' \
        --data '{
          "model": "gpt-6-astra",
          "input": "Check the deployment status for service api-gateway.",
          "tools": [{
            "type": "function",
            "name": "get_deployment_status",
            "description": "Return the current deployment status for a service.",
            "parameters": {
              "type": "object",
              "properties": { "service": { "type": "string" } },
              "required": ["service"],
              "additionalProperties": false
            },
            "strict": true,
            "async": true
          }],
          "tool_choice": "auto",
          "parallel_tool_calls": true,
          "max_tool_calls": 4
        }'
      ```
    </div>

    ## Request body

    <ParamField body="model" type="string" required>Use `gpt-6-astra`. Tool calling requires the Responses API.</ParamField>
    <ParamField body="tools" type="object[]" required>Function, custom, or supported built-in tool definitions.</ParamField>
    <ParamField body="tools[].type" type="string" required>`function`, `custom`, `web_search`, `code_interpreter`, `shell`, `apply_patch`, `computer`, or `mcp`.</ParamField>
    <ParamField body="tools[].name" type="string">Function or custom-tool name.</ParamField>
    <ParamField body="tools[].description" type="string">When and how to use the tool.</ParamField>
    <ParamField body="tools[].parameters" type="object">JSON Schema for function arguments.</ParamField>
    <ParamField body="tools[].strict" type="boolean">Strict function-argument validation.</ParamField>
    <ParamField body="tools[].async" type="boolean">Allow independent work while your application runs a function or custom tool.</ParamField>
    <ParamField body="tools[].allowed_callers" type="string[]">Use `direct` for direct model tool calls.</ParamField>
    <ParamField body="tools[].output_schema" type="object">Optional JSON Schema for Function output.</ParamField>
    <ParamField body="tools[].search_context_size" type="string">Web Search context size, such as `low`.</ParamField>
    <ParamField body="tools[].filters.allowed_domains" type="string[]">Domains allowed for Web Search.</ParamField>
    <ParamField body="tools[].container" type="object">Code Interpreter container configuration. Use `{ "type": "auto" }`; `memory_limit` is supported.</ParamField>
    <ParamField body="tools[].environment" type="object">Shell environment configuration. Use `{ "type": "container_auto" }`; `memory_limit` is supported.</ParamField>
    <ParamField body="tools[].server_label" type="string">Label for an MCP server.</ParamField>
    <ParamField body="tools[].server_url" type="string">HTTPS endpoint for an MCP server.</ParamField>
    <ParamField body="tools[].require_approval" type="string | object">MCP approval policy, such as `never`.</ParamField>
    <ParamField body="tool_choice" type="string | object">`none`, `auto`, or a forced-tool object.</ParamField>
    <ParamField body="parallel_tool_calls" type="boolean">Allow multiple tool calls in one turn.</ParamField>
    <ParamField body="max_tool_calls" type="integer">Maximum total built-in tool calls.</ParamField>
    <ParamField body="include" type="string[]">Tool details to return, such as `web_search_call.action.sources` or `code_interpreter_call.outputs`.</ParamField>

    <Warning>Your application executes Function and Custom Tool calls. File Search requires a Vector Store created in the same upstream resource, but AnyFast does not currently expose the Vector Stores management endpoint.</Warning>

    ## Tool-call response

    <div className="kling-api-example-panel">
      ```json 200 theme={null}
      {
        "id": "resp_01toolexample",
        "object": "response",
        "model": "gpt-6-astra",
        "status": "completed",
        "output": [{
          "id": "fc_01deployment",
          "type": "function_call",
          "call_id": "call_01deployment",
          "name": "get_deployment_status",
          "arguments": "{\"service\":\"api-gateway\"}",
          "status": "completed",
          "async": true
        }]
      }
      ```
    </div>

    <ResponseField name="output[].type" type="string">`function_call` for this workflow.</ResponseField>
    <ResponseField name="output[].call_id" type="string">Tool-call correlation ID.</ResponseField>
    <ResponseField name="output[].name" type="string">Function name.</ResponseField>
    <ResponseField name="output[].arguments" type="string">JSON-encoded arguments.</ResponseField>
    <ResponseField name="output[].async" type="boolean">Whether the call can complete asynchronously.</ResponseField>
    <Warning>Do not rely on cross-request response or tool-item references. Requests routed to different upstream resources can reject those references.</Warning>
  </Tab>

  <Tab title="Chat Completions">
    ## Create text completion

    `POST /v1/chat/completions`

    <div className="kling-api-example-panel">
      ```bash cURL theme={null}
      curl --request POST \
        --url https://www.anyfast.ai/v1/chat/completions \
        --header 'Authorization: Bearer YOUR_API_KEY' \
        --header 'Content-Type: application/json' \
        --data '{
          "model": "gpt-6-astra",
          "messages": [{ "role": "user", "content": "Return a concise deployment checklist." }],
          "reasoning_effort": "low",
          "max_completion_tokens": 1024
        }'
      ```
    </div>

    ## Request body

    <ParamField body="model" type="string" required>Use `gpt-6-astra`.</ParamField>
    <ParamField body="messages" type="object[]" required>Ordered Chat Completions messages.</ParamField>
    <ParamField body="messages[].role" type="string" required>Message role.</ParamField>
    <ParamField body="messages[].content" type="string" required>Text message content.</ParamField>
    <ParamField body="reasoning_effort" type="string">`low`, `medium`, `high`, `xhigh`, or `max`.</ParamField>
    <ParamField body="max_completion_tokens" type="integer">Maximum completion and reasoning tokens.</ParamField>

    <Warning>Use Chat Completions for text requests only. GPT-6 Astra tool calling requires Responses API. Do not send `temperature`, `top_p`, `top_logprobs`, or `logprobs`.</Warning>

    ## Response

    <ResponseField name="id" type="string">Chat completion ID.</ResponseField>
    <ResponseField name="choices[].message.content" type="string">Generated text.</ResponseField>
    <ResponseField name="choices[].finish_reason" type="string">Why generation stopped.</ResponseField>
    <ResponseField name="usage" type="object">Prompt, completion, and total token usage.</ResponseField>
  </Tab>
</Tabs>

## Common errors

<ResponseField name="400" type="error">Invalid input, unsupported reasoning or sampling parameter, incompatible state fields, or invalid tool/schema configuration.</ResponseField>
<ResponseField name="401" type="error">Missing or invalid API key.</ResponseField>
<ResponseField name="429" type="error">Rate or quota limit reached.</ResponseField>

## Official references

* [GPT-6 Astra model page](https://developers.openai.com/api/docs/models/gpt-6-astra)
* [Using GPT-6 Astra](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-6-astra)
* [Responses API create reference](https://developers.openai.com/api/reference/resources/responses/methods/create)

<script src="/public/feedback.js" />
