Endpoint reference

Generated from olxcore/src/api/schema.json, the same schema the gateway validates requests against. Base URL http://127.0.0.1:8780.

Unknown fields in a turn body are rejected, not ignored. Errors are listed under Auth.

GET /v1/status scope: any

Gateway and core state as this token sees it.

Response: StatusResult

fieldtyperequiredmeaning
api"v1"yes
appstringyes
scopesarrayyes
coreobjectyes
turns_runninginteger

GET /v1/models scope: models

Installed local models by display name, OpenAI list format. `resident` says which are loaded right now.

Response: ModelList

fieldtyperequiredmeaning
object"list"yes
dataarrayyes

POST /v1/chat/completions scope: models

OpenAI-compatible completion on a local model (stream true|false, tools passthrough, sampling). The model's own answer only: olix tools do not run here.

Body

fieldtyperequiredmeaning
modelstring (max 128 chars)
messagesarrayyes
streamboolean
toolsarray
tool_choiceany
temperaturenumber (0..2)
top_pnumber (0..1)
top_knumber (0..1000)
presence_penaltynumber (-2..2)
max_tokensinteger (1..131072)
max_completion_tokensinteger (1..131072)

POST /v1/turns scope: chat

Run one olix turn. With stream true (default) the response is Server-Sent Events: one event per core event, ending at task_complete. With stream false it waits and returns the final task_complete plus the events.

Body

fieldtyperequiredmeaning
type"input"
textstring (max 100000 chars)yesWhat to ask olix.
session_idstringContinue one of this app's sessions. A turn already running in it steers instead.
cwdstring (max 4096 chars)Project folder. Must be inside a folder the owner granted this token (--allow-dir); the default is this app's own workspace folder.
modelstring (max 128 chars)A display name (blink 1.1, flux) or id (olx-1). Default is the owner's chat model.
effortlow | medium | high | xhigh | maxReasoning effort. Values the owner's build does not know are refused by the core.
streambooleanHTTP only. true (default) answers with Server-Sent Events; false waits for the whole turn.
request_idstring (max 128 chars)

Streams the turn's events: see Events.

POST /v1/turns/{id}/interrupt scope: chat

Stop a running turn of this app.

Response: Interrupted

fieldtyperequiredmeaning
interruptedbooleanyes
foundbooleanyes
request_idstring

POST /v1/turns/{id}/answer scope: chat

Answer an open question of the turn. Deny only: an approve is refused with approval_not_allowed.

Body

fieldtyperequiredmeaning
question_idstring (max 200 chars)yes
decision"deny"yes
reasonstring (max 500 chars)

Response: Answered

fieldtyperequiredmeaning
answeredbooleanyes
decision"deny"yes
question_idstring

GET /v1/sessions scope: chat

This app's own sessions.

Response: SessionList

GET /v1/sessions/{id} scope: chat

The saved transcript of one of this app's sessions.

Response: Transcript

fieldtyperequiredmeaning
session_idstringyes
titlestring
pinnedboolean
messagesarrayyes
truncatedbooleanyes

GET /v1/sessions/{id}/changes scope: chat

Files this app's session changed (workspace_changes). Add ?path=relative/file for one file's diff.

Response: Changes

fieldtyperequiredmeaning
oktrueyes
filesarray
fileobject

GET /v1/settings/schema scope: any

The field list of olix's settings (read-only; the API cannot change a setting).

Response: SettingsSchema

fieldtyperequiredmeaning
fieldsarrayyes

GET /v1/history scope: history.read

The owner's saved sessions across projects, newest first. ?limit=N (max 500).

Response: SessionList

GET /v1/history/{id} scope: history.read

The saved transcript of any session.

Response: Transcript

fieldtyperequiredmeaning
session_idstringyes
titlestring
pinnedboolean
messagesarrayyes
truncatedbooleanyes

Examples

curl
curl -s http://127.0.0.1:8780/v1/sessions \
  -H "Authorization: Bearer $OLIX_API_TOKEN" | jq '.[0] | {id, turns}'
Real output
{
  "id": "20261106132214-54f2e5",
  "turns": 1
}