lume-3.5.
Each call stands on its own. To continue, send the earlier messages again, with the new question at the end.
Before you start
Create an API key in the dashboard withchat:completions for Chat Completions or messages:create for Messages. If your key has a model allowlist, include lume-3.5. Keep the key on your server and set it in the shell where you run the examples:
Authorization: Bearer or x-api-key. Supplying both with values returns HTTP 401.
For SDK examples, install the client you use. cURL examples do not need an SDK.
.py file. Save Node.js examples as .mjs files to use import and top-level await.
Messages accepts an optional anthropic-version header. If supplied, it must be one valid calendar date in YYYY-MM-DD form. It is a compatibility hint and does not change the supported features. The SDK supplies its version header automatically.
Chat Completions
POST /v1/chat/completions needs the scope chat:completions. Send your key as Authorization: Bearer $OVERCONTROL_API_KEY, or as x-api-key. Authentication covers scopes and what a rejected key looks like.
A system or developer message is the instruction from your application. A user message is the person’s question. An assistant message is a reply from an earlier turn, which you include so the model can see it. tool and function messages are for function calling.
The example asks for a short follow-up. max_tokens is 256, so the call reserves a short reply on lume-3.5.
choices[0].message.content. finish_reason is stop when the model finishes inside max_tokens. The counts below are an illustration.
X-Request-Id.
temperature runs from 0 to 2. You set the length of the reply with max_tokens or max_completion_tokens. Send only one of those output parameters. On lume-3.5 the ceiling is 32,768 tokens. A larger value is reduced to that ceiling. If you omit both output parameters, the model maximum applies. stop is one string, or up to four, where the reply should end.
The output budget is also reduced to the estimated remaining space in the 400,000-token context window. Input that leaves no room for output is rejected with HTTP 400:
Messages
POST /v1/messages needs the scope messages:create. The instruction goes in the top-level system field. messages holds the turns: the person’s question, the assistant reply, and the new question.
max_tokens is required. The official Python SDK adds /v1/messages itself, so its base URL is https://api.overcontrolgroup.com.
content, as a text block. stop_reason is end_turn when the model finishes on its own. The counts below are an illustration.
X-Request-Id and request-id.
temperature and top_p each run from 0 to 1. Supply a positive integer max_tokens. On lume-3.5, the output budget is capped at 32,768 tokens and reduced further to fit the estimated remaining context space. stop_sequences takes up to four strings, and each one can be at most 1,024 bytes.
The context window is 400,000 tokens. If the input leaves no room for output, you get HTTP 400. The body has no error.code:
Read the finish reason
A normal text answer ends with Chatfinish_reason: "stop" or Messages stop_reason: "end_turn". Chat length or Messages max_tokens means the answer reached its output budget and may be incomplete. Increase the explicit budget or split the task if you need more room. A tool call uses Chat tool_calls or Messages tool_use; your application must handle the tool result before expecting a final answer.
Lume 2 supports 200,000 tokens of context and up to 16,384 output tokens. Lume 3.5, Lume 3.5 Max, and Lume Omni support 400,000 tokens of context and up to 32,768 output tokens. All four models support these text workflows.
Usage and common errors
Chat reports token counts inusage.prompt_tokens, usage.completion_tokens, and usage.total_tokens. Messages reports usage.input_tokens and usage.output_tokens, with separate cache counts when present. Each follow-up processes the conversation you send, so longer history can use more allowance. Pricing explains how usage is calculated.
OverControl temporarily reserves usage before a request runs and releases unused reserved usage afterward. A smaller output budget can reduce the amount needed to start.
Keep
X-Request-Id when reporting a failed request. Messages also returns the same identifier as request-id and, on errors, request_id in the JSON body.
Next
Streaming
Read the reply as it is written.
Function calling
Let the model call a function in your application.
Structured outputs
Extract JSON with a schema on either API.
Models
Compare context windows and output caps.

