Skip to main content
Flowyte exposes an OpenAI-compatible chat completions endpoint. If your code already uses an OpenAI client library, you can talk to a Flowyte agent by changing two things: the base URL and the model. The model is your agent id, and the agent’s knowledge, skills, and guardrails all apply to the response. All paths are relative to https://builder.flowyte.com/api/v1.
Authenticate with your secret key Authorization: Bearer flowyte_sk_… (scope chat:write). This endpoint serves the agent’s published version.

What you’ll use

The base-URL swap

Set the client’s base URL to https://builder.flowyte.com/api/v1, the API key to your flowyte_sk_…, and pass the agent id as model. The SDK appends /chat/completions for you.
The response is the standard completion shape: read the reply from choices[0].message.content.

Streaming

Set stream: true and the endpoint returns OpenAI-style SSE chunks — data: {choices:[{delta:{content}}]} … terminated by data: [DONE] — so an OpenAI SDK’s streaming mode works unchanged.

What’s read, and what isn’t

  • Only model, messages, stream, and user are used. The agent’s own configuration governs its behavior — sampling, tools, and system prompt come from the published agent, so request-level overrides for those are ignored.
  • model must be a real agent id, not an OpenAI model name. An unknown id returns a 400.
  • Roles system, user, assistant, and tool are accepted in messages.
Need session state, tool-call events, or quick replies? Use the native chat API instead: POST /chat/sessions then POST /chat/sessions/{id}/messages with stream: true. For an in-browser widget, mint a publishable key — see Embed the chat widget.
Related: Agents · Authentication