EU GPT logo
EU GPT

English documentation — We currently provide our documentation only in English. This helps us keep the information as accurate and up-to-date as possible during the rapid development of the API.

API

API reference

Interactive OpenAPI 3.1 reference for /v1/responses.

This is the live OpenAPI 3.1 reference for the EU GPT public API. Use the panels below to explore endpoints, see schemas, and try requests against your environment.

For a top-to-bottom prose walkthrough of the same surface, see Create a response.

EU GPT — Public API

v1.0.0
Download openapi.yaml

External-facing API for programmatic access to EU GPT.

Authenticate every request with an API key issued from the EU GPT web app:

Authorization: Bearer eugpt_<token>

Keys are managed in the chat UI (Settings → API Keys). They have no rotating refresh — revoke and reissue when needed.

Base URL

https://chat.eugpt.ai Production

Authenticatie

apiKey http · bearer

Bearer-formaat eugpt_<token>

EU GPT API key. Issue from the web app; pass as Authorization: Bearer eugpt_<token>.

Endpoints

POST /v1/responses

Create a response

Generate an AI response from a user message. Two modes:

  • Streaming (stream: true, default) — returns Server-Sent Events with OpenAI-compatible event payloads. Each event is delivered as event: message\ndata: <json>\n\n. Stream completion is signalled by a response.completed event.
  • Non-streaming (stream: false) — collects all output and returns a single JSON document.

Conversations are optional. Omit conversation_id for stateless requests; pass an existing UUID to append to a thread that belongs to the authenticated user. Tools (web search, web fetch, calculator, etc.) are auto-approved for API requests — there is no interactive approval gate.

Request body Verplicht

  • modelstring
    Accepted for OpenAI-SDK compatibility but ignored — the router always selects the model. Pass "auto" (the default and only meaningful value); any concrete id you send has no effect. The actual model used is reported in the response model field.
    StandaardautoVoorbeeldauto
  • inputstring | ContentItem[]Verplicht
    Either a plain string (single user message) or a list of structured ContentItem objects for multi-modal / file input.
  • streamboolean
    Stream as SSE (true, default) or return a single JSON response (false).
    Standaardtrue
  • instructionsstringNullable
    System prompt for this response (or conversation, if new).
  • conversation_iduuidNullable
    Append to an existing conversation. Omit for a stateless request — an ephemeral conversation is created and returned in the response.
  • project_iduuidNullable
    Project context for RAG retrieval. Caller must be a member of the project.
  • max_output_tokensintegerNullable
    Upper bound on the number of tokens the model may generate for this response. Omit for no explicit cap (the model's own maximum applies). Values above the model's maximum are clamped to it.
    Voorbeeld1024

Responses

200
Either an SSE stream (stream: true) or a single JSON response (stream: false).
application/json · text/event-stream
  • iduuidVerplicht
  • object"response"Verplicht
  • created_atintegerVerplicht
    Unix epoch milliseconds (zero if the chain didn't emit).
  • status"completed"Verplicht
  • modelstringVerplicht
    Concrete model id used (resolved from "auto" when needed).
  • outputobject[]Verplicht
    Structured output items (text blocks, tool calls, etc.) in the same shape as the SSE response.output_item.added events.
  • output_textstringVerplicht
    Concatenated text deltas — convenience for plain-text consumers.
400
Input message is required or otherwise invalid.
application/json
  • detailstring | object
  • errorobject
401
Missing, expired, or revoked API key.
application/json
  • detailstring | object
  • errorobject
403
License or organization policy denies the request — for example, user is not a member of the requested project, or the organization's plan disallows the operation.
application/json
  • detailstring | object
  • errorobject
404
Referenced conversation or project does not exist.
application/json
  • detailstring | object
  • errorobject
429
Daily or monthly token usage limit exceeded.
application/json
  • detailstring | object
  • errorobject
500
Internal error during response generation.
application/json
  • detailstring | object
  • errorobject

Schemas

CreateResponseRequest

object
  • modelstring
    Accepted for OpenAI-SDK compatibility but ignored — the router always selects the model. Pass "auto" (the default and only meaningful value); any concrete id you send has no effect. The actual model used is reported in the response model field.
    StandaardautoVoorbeeldauto
  • inputstring | ContentItem[]Verplicht
    Either a plain string (single user message) or a list of structured ContentItem objects for multi-modal / file input.
  • streamboolean
    Stream as SSE (true, default) or return a single JSON response (false).
    Standaardtrue
  • instructionsstringNullable
    System prompt for this response (or conversation, if new).
  • conversation_iduuidNullable
    Append to an existing conversation. Omit for a stateless request — an ephemeral conversation is created and returned in the response.
  • project_iduuidNullable
    Project context for RAG retrieval. Caller must be a member of the project.
  • max_output_tokensintegerNullable
    Upper bound on the number of tokens the model may generate for this response. Omit for no explicit cap (the model's own maximum applies). Values above the model's maximum are clamped to it.
    Voorbeeld1024

ContentItem

object
  • rolestringNullable
    Optional role hint (e.g. "user").
  • typestringNullable
  • contentInputText | InputFile[]Verplicht

InputContent

InputText | InputFile

InputText

object
  • type"input_text"Verplicht
  • textstringVerplicht

InputFile

object
  • type"input_file"Verplicht
  • file_iduuidVerplicht
    Id of a file previously uploaded via the file upload API.

ResponseObject

object
Returned when stream: false.
  • iduuidVerplicht
  • object"response"Verplicht
  • created_atintegerVerplicht
    Unix epoch milliseconds (zero if the chain didn't emit).
  • status"completed"Verplicht
  • modelstringVerplicht
    Concrete model id used (resolved from "auto" when needed).
  • outputobject[]Verplicht
    Structured output items (text blocks, tool calls, etc.) in the same shape as the SSE response.output_item.added events.
  • output_textstringVerplicht
    Concatenated text deltas — convenience for plain-text consumers.

SseEventStream

text/event-stream
Server-Sent Events stream. Each event is one of the OpenAI-compatible types below; payloads are JSON in the data: line. Event types: - response.created — initial event with response metadata. - response.output_text.delta — incremental text chunks. - response.output_text.done — text part finalised. - response.output_item.added / response.output_item.done — structured items (tool calls, file references). - response.content_part.added — additional content parts. - response.completed — terminal success event. - error — terminal error event with {type, code, message}.

Error

object
  • detailstring | object
  • errorobject