Integration sandbox and enable prerequisite

Rehearse text, tool-call, structured-output and error flows deterministically without calling a provider.

Also available as Markdown · all agent guides in one file

Key points

  • The server operator must set AETHER_SANDBOX_ENABLED=true; a client cannot enable it. Public production enablement is not asserted here.
  • Use a regular API key and the explicit /v1/sandbox path. It never calls a provider, consumes credits or changes usage aggregates.
  • A sandbox success verifies client transport, tool-cycle bookkeeping and parsing only, not a live model.

Enablement and authentication

Operator prerequisite

The server operator must explicitly set AETHER_SANDBOX_ENABLED=true for the running backend. This is a server configuration prerequisite; a client cannot enable it with a request header, body or model name. Public production enablement is not asserted here.

Endpoints

Run one simulated request

The following requires curl, jq and AETHER_API_KEY. It uses AETHER_ORIGIN if an operator supplies a separate test server. It makes no changes to server configuration.

origin="$AETHER_ORIGIN"
if [ -z "$origin" ]; then origin="https://api.aetherapi.dev"; fi
jq -n '{model: "aether-sandbox", messages: [{role: "user", content: "Hello"}],
        sandbox: {scenario: "success"}}' \
  | curl --fail-with-body --silent --show-error \
      "$origin/v1/sandbox/chat/completions" \
      -H "Authorization: Bearer $AETHER_API_KEY" \
      -H 'Content-Type: application/json' --data-binary @-

A successful chat response contains [Aether Sandbox] Simulated response. No provider was called. and zero token usage. Response headers include x-aether-sandbox: true and x-aether-sandbox-scenario. Inspect those headers to confirm the intended mode.

Scenarios and limits

ScenarioResult
success (default)Fixed text, normal JSON or SSE completion.
rate_limitHTTP 429, sandbox_simulated_429, Retry-After: 1.
timeoutHTTP 504, sandbox_simulated_timeout; this is a simulated error, not a real hanging provider connection.
provider_unavailableHTTP 503, sandbox_simulated_provider_unavailable, Retry-After: 1.
stream_errorRequires stream: true; emits partial text or tool-call arguments and sandbox_simulated_stream_error, then ends without a successful completion (no [DONE] on chat). Use it to test incomplete output handling.

Rehearse a tool-call cycle

ProtocolAccepted tool_choiceReturn the synthetic result asOutput schema
Chatauto, none, required or {type: function, function: {name}}a role: tool message with tool_call_idresponse_format {type: json_schema, json_schema: {name, strict, schema}}
Responsesthe same strings or {type: function, name}the returned output items followed by {type: function_call_output, call_id, output}text.format {type: json_schema, name, strict, schema}
Messages{type: auto}, {type: none}, {type: any} or {type: tool, name}a user tool_result block with tool_use_idoutput_config.format {type: json_schema, schema}

This Chat Completions body declares one tool and an output schema. POST it to /v1/sandbox/chat/completions: the answer has finish_reason: tool_calls and one weather call with arguments {"city":"Berlin"}. Append that assistant message and {role: "tool", tool_call_id: <call id>, content: "synthetic result"} to messages, then send the body again: the assistant content is {"simulated":true} with finish_reason: stop.

{
  "model": "aether-sandbox",
  "messages": [{ "role": "user", "content": "What is the weather in Berlin?" }],
  "tools": [{ "type": "function", "function": {
    "name": "weather",
    "parameters": { "type": "object", "properties": { "city": { "type": "string", "enum": ["Berlin"] } },
      "required": ["city"], "additionalProperties": false }
  } }],
  "response_format": { "type": "json_schema", "json_schema": {
    "name": "result", "strict": true,
    "schema": { "type": "object", "properties": { "simulated": { "type": "boolean" } },
      "required": ["simulated"], "additionalProperties": false }
  } }
}

Structured output and the supported schema subset

Schemas for output and tool arguments:

LimitMaximum
Per schema8192 bytes, 128 nodes, 8 levels and 32 properties per object
Per generated value or submitted arguments16384 bytes
Per request16 tool definitions and 128 conversation items
Tool names64 characters (Messages: 128)

What a sandbox success proves

A sandbox success verifies client transport, tool-cycle bookkeeping and parsing only. It does not prove a live model's availability, tool support, schema guarantees, context size, pricing or authorization for that model, and sandbox behaviour is not reflected in the production capability catalogue.