Extend Zo
API
Access Zo programmatically
The Zo API lets you interact with your Zo from scripts, automations, or other apps. Authenticate with an access token from Settings > Advanced.
Quick start#
- Go to Settings > Advanced and create an access token
- Copy it immediately — you won't see it again
Warning
Your API key grants full access to your Zo. Keep it secret and never commit it to version control.
API reference#
Base URL: https://api.zo.computer
POST /zo/ask
Send a message to your Zo and get a response.
Request
inputstringrequiredYour message to Zo
conversation_idstringContinue an existing conversation
model_namestringOverride the default model (use /models/available to list options)
persona_idstringOverride the active persona (use /personas/available to list options)
output_formatobjectJSON Schema for structured output
streambooleandefault: falseEnable streaming mode. Returns Server-Sent Events (SSE) instead of JSON.
Response
outputstring | objectZo's response. Returns an object if output_format was specified.
conversation_idstringID to continue this conversation in subsequent requests.
Streaming Response (when stream: true)
Returns a Server-Sent Events stream with Content-Type: text/event-stream. Each event has the format:
Event Types:
FrontendModelResponse— Text chunk from the model (data.content)End— Stream completed (includesdata.outputifoutput_formatwas specified)Error— Error occurred (data.message)
The x-conversation-id response header contains the conversation ID for follow-up requests.
GET /models/available
List all available models you can use with the /zo/ask endpoint. When authenticated with an API key, includes your BYOK (Bring Your Own Key) configurations.
Response
modelsarrayList of available models
models[].model_namestringThe value to pass to model_name in /zo/ask
models[].labelstringHuman-readable model name
models[].vendorstringModel provider (e.g., "Anthropic", "OpenAI", "Custom")
models[].descriptionstring | nullShort description of the model's capabilities
models[].typestring | nullEither "fast" or "capable", indicating the model's speed/capability tradeoff
models[].context_windownumber | nullMaximum context window size in tokens
models[].is_byokbooleanWhether this is a BYOK (Bring Your Own Key) model
GET /personas/available
List all configured personas. Use the returned id values with the persona_id parameter in /zo/ask to override the active persona.
Response
personasarrayList of configured personas
personas[].idstringThe value to pass to persona_id in /zo/ask
personas[].namestringDisplay name for the persona
personas[].promptstringSystem prompt defining the persona's behavior
personas[].modelstring | nullAI model ID, or null for system default
personas[].imagestring | nullAvatar image URL
Examples#
Continuing a conversation#
Use the returned conversation_id to continue the conversation:
Structured output#
Use output_format to get responses as structured JSON. This is based on OpenAI's Structured Outputs.
Streaming#
Use stream: true to receive responses as Server-Sent Events: