API reference
Responses
POST /v1/responses. The OpenAI responses format, answered from the record within the caller's clearance.
POST https://YOUR-DOOR-ADDRESS/v1/responsesRequests and responses follow the OpenAI responses API. Use the OpenAI SDK with base_url set to your door address plus /v1, and your credential headers as default headers. See Doors and credentials.
Request fields the door reads
Section titled “Request fields the door reads”| Field | Type | Notes |
|---|---|---|
model |
string, required | A model alias configured for your organization. See Models. |
input |
string or array, required | A string, or a non-empty array of input items. |
instructions |
string | System instructions, as in the standard API. |
max_output_tokens |
integer | Upper bound on generated tokens. |
temperature |
number | As in the standard API. |
tools |
array | Function tools, as in the standard API. |
tool_choice |
string or object | As in the standard API. |
metadata |
object | As in the standard API. |
stream |
boolean | true streams server-sent events in the standard event format. |
A request body can’t include organization or principal identity. The door limits the number of messages and tools per request.
Example
Section titled “Example”import osfrom openai import OpenAIfrom syderial_headers import load_headers # helper from the Quickstart
client = OpenAI( base_url=os.environ["SYDERIAL_DOOR_URL"] + "/v1", api_key="unused", default_headers=load_headers(),)
response = client.responses.create( model=os.environ["SYDERIAL_MODEL"], instructions="Answer from the record. Say when the record is silent.", input="Which decisions changed the V-204 maintenance plan?", max_output_tokens=800,)
print(response.output_text)import OpenAI from "openai";import { loadHeaders } from "./syderial-headers"; // helper from the Quickstart
const client = new OpenAI({ baseURL: `${process.env.SYDERIAL_DOOR_URL}/v1`, apiKey: "unused", defaultHeaders: loadHeaders(),});
const response = await client.responses.create({ model: process.env.SYDERIAL_MODEL!, instructions: "Answer from the record. Say when the record is silent.", input: "Which decisions changed the V-204 maintenance plan?", max_output_tokens: 800,});
console.log(response.output_text);curl "$SYDERIAL_DOOR_URL/v1/responses" \ -H @syderial-headers.txt \ -H "content-type: application/json" \ -d '{ "model": "'"$SYDERIAL_MODEL"'", "instructions": "Answer from the record. Say when the record is silent.", "input": "Which decisions changed the V-204 maintenance plan?", "max_output_tokens": 800 }'Response
Section titled “Response”A standard response object, or a standard event stream when stream is true. Syderial adds the evidence and a receipt reference alongside the standard fields. See What Syderial adds to a response.