API reference

Base URL: your deployment (local: http://localhost:8080). All bodies are JSON (UTF-8). Times are RFC 3339. IDs are UUIDv7 strings. Bots can be addressed by id or slug (/v1/bots/piper).

Conventions

Topic Rule
Auth Authorization: Bearer <token> (EventSource: ?access_token=). Tokens come from register/login and last BISCUIT_TOKEN_TTL (30 days default).
Errors RFC 9457 application/problem+json: {type, title, status, code, detail, requestId}. Switch on code; show detail.
Request IDs Send X-Request-ID or get one back on every response; it appears in logs and errors.
Validation Unknown JSON fields are rejected (400) so typos don't silently do nothing. Bodies over 1 MiB → 400.
Idempotency Idempotency-Key: <≤100 chars> on POST /messages. Repeating it returns the original (200, Idempotent-Replayed: true) and does not trigger another reply.
Concurrency Docs use ETags: GET returns ETag: "rev"; PUT with If-Match: "rev". Mismatch → 412 stale_revision. If-None-Match → 304.
Pagination Keyset: ?limit= (default 50, max 200) and ?before=<id>; responses are {items, next}; next: null means the end.
Rate limits Token bucket per user (or IP). Over the limit → 429 rate_limited + Retry-After (seconds).
Back-pressure Replies in flight are bounded; when full, POST /messages → 503 busy + Retry-After before anything is stored. Safe to retry with the same Idempotency-Key.
Compression Accept-Encoding: gzip honoured for JSON (not for event streams).
Versioning Breaking changes ship under a new prefix (/v2). Within v1, fields are only added.

Error codes

HTTP code Meaning
400 invalid_request Malformed JSON, unknown field, or failed validation (see detail).
401 unauthorized / token_expired / bad_credentials Missing/invalid token, expired token, wrong email or password.
404 not_found Missing — or belongs to another workspace (never revealed).
409 conflict / email_taken Unique constraint (e.g. email already registered).
412 stale_revision / exists Doc changed since your If-Match; or creating a doc that exists.
429 rate_limited Slow down; honour Retry-After.
503 busy / not_ready Reply backlog full (retry); instance not ready (health).
504 timeout Upstream or query exceeded its deadline.
500 internal Bug — quote requestId.

Auth

Method Path Body Returns
POST /v1/auth/register {email, name, password (10–200)} 201 {token, expiresAt, user, workspace} — creates a personal workspace with the starter crew (Global, Piper, Ledger, Relay, Outbound, Scout), in one transaction
POST /v1/auth/login {email, password} 200 {token, expiresAt, user, workspace, workspaces}
GET /v1/me — {user, workspaceId, workspaces}
POST /v1/workspaces/{ws}/switch — {token, expiresAt} scoped to that workspace (must be a member)

Bots

Method Path Body / query Returns
GET /v1/bots — {items: Bot[]}
POST /v1/bots {name, role?, about?, hue?, crew?, model?, slug?} 201 Bot (slug from name; suffixed if taken)
GET /v1/bots/{bot} — Bot
PATCH /v1/bots/{bot} any of name, role, about, hue, crew, model Bot
DELETE /v1/bots/{bot} — 204 (soft delete; slug becomes reusable)

Bot = {id, slug, name, role, about, hue, crew, model, createdAt, updatedAt} hue: blue|orange|green|red|pink or a custom colour c-rrggbb (matches the web colour library).

Messages

Streaming a reply
POST /messagesmessagestepdeltadone
You or your deviceSaved or publishedHover or tab to a box to trace it
Method Path Notes
GET /v1/bots/{bot}/messages?limit&before Page newest-first: {items: Message[], next}
POST /v1/bots/{bot}/messages {text (≤8000), body?, project?, approval?: "always"} + optional Idempotency-Key. approval: "always" makes computer work this reply starts ask before every step. See modes below.

Message = {id, botId, from: "me"|"bot"|"system", kind, text, body, at}

Streaming mode — send Accept: text/event-stream:

event: message   data: {…your message…}
event: step      data: {"id":"c1","tool":"web_search","label":"Searching the web for “…”","status":"running"}
event: step      data: {"id":"c1",…,"status":"done"}
event: delta     data: {"text":"On "}
event: delta     data: {"text":"it. "}
…
event: done      data: {…the saved bot reply…}

Replies run as an agent loop: the bot may call tools (web_search, read_url, browse on its computer, connected-app tools, MCP, delegate_task, create_routine, run_routine, propose_memory, generate_image, create_skill) over several rounds before and between its text. Each tool call streams as step events: {id, tool, label, status: running|done|failed|waiting, detail?, run?}. run is the computer run a browse step drives (follow it on /v1/computer/{run}/stream). Writes (sending, posting, creating in another app) become approvals in Now and report waiting. The saved reply carries the steps as body.agentSteps.

event: error ({code}) if the reply couldn't be saved. If you disconnect, the server still finishes and saves the reply; it appears on /v1/events.

Fire-and-forget mode — any other Accept: 202 {message}; the reply arrives as message.created on /v1/events.

Memories

Method Path Body
GET /v1/memories — → {items} (pending first, newest first)
POST /v1/memories {text (≤2000), meta?, botId?, pending?} → 201
PATCH /v1/memories/{id} {text?, pending?} (keep a pending memory with pending:false)
DELETE /v1/memories/{id} 204

Docs

Method Path Notes
GET /v1/docs List without bodies (cheap).
GET /v1/docs/{name} ETag: "rev"; supports If-None-Match.
PUT /v1/docs/{name} {title, body: object}. No If-Match → create (201, or 412 exists). With If-Match: "rev" → update (200, or 412 stale_revision). Each save appends a revision.
GET /v1/docs/{name}/revisions {items: [{rev, createdAt, authorId}]} newest first.
GET /v1/docs/{name}/revisions/{rev} Full body of a revision; cacheable forever.

The web editor's document state (tabs, comments, prefs) is stored as body.

Routines

Method Path Body
GET /v1/routines —
POST /v1/routines {bot, name, prompt, days: [0..6] (0 = Monday), hour, minute?, tz? (IANA, default UTC), paused?, trigger?, triggerConfig?} — trigger is schedule (default) · webhook · email · slack · github. A webhook routine answers {routine, hookKey, hookUrl}; the key is shown only this once.
PATCH /v1/routines/{id} Any of {name, prompt, days, hour, minute, paused, trigger, triggerConfig} — the next run is recomputed from now (resuming doesn't fire a backlog).
POST /v1/routines/{id}/run 202 — schedule routines become due now and run on the scheduler's next tick; triggered routines start at once (source: manual).
POST /v1/routines/{id}/hook-key Webhook routines: a new key, {hookKey, hookUrl}, returned once; the old key stops working.
GET /v1/routines/{id}/runs The latest 30 runs: {id, status: ok|failed, error?, source, payloadSummary?, output?, startedAt, finishedAt}
GET /v1/inbound/address {address} — the workspace's inbound email address (empty when BISCUIT_INBOUND_DOMAIN is unset).

triggerConfig — email: {from?, subjectContains?}; slack: {teamId, on: mention\|phrase\|reaction\|channel, phrase?, reaction?, channel?}; github: {repo: "owner/name", events?: [issues, pull_request, issue_comment], label?}. The scheduler only claims schedule routines.

Inbound events (no session token)

Each endpoint verifies its request, ignores an event id it has already accepted for a routine, and caps triggered runs at 200 per routine and 300 per workspace per hour (429 "Automation run rate limit exceeded"). Accepted events answer 202 {started: true}. The event is added to the routine's prompt inside an <untrusted_data> block (capped at 6,000 characters) that the bot is told never to take instructions from; the run records source, payloadSummary and output.

Method Path Verification · event id
POST /v1/hooks/routines/{id} Authorization: Bearer <hook key> (constant-time) · Idempotency-Key or X-Event-Id header. Any body.
POST /v1/inbound/email Recipient must be a workspace's <slug>@BISCUIT_INBOUND_DOMAIN · MessageID/Message-Id. Postmark JSON, Mailgun and SendGrid (JSON or form). Filters: from, subject contains.
POST /v1/inbound/slack X-Slack-Signature with BISCUIT_SLACK_SIGNING_SECRET, timestamp within 5 minutes · event_id. Answers url_verification. Fires on app_mention, a phrase in a message, reaction_added, or any message in a channel; bot messages are ignored.
POST /v1/inbound/github X-Hub-Signature-256 with BISCUIT_GITHUB_WEBHOOK_SECRET · X-GitHub-Delivery. Issues opened, pull request opened, issue comment created; repo and label filters.
DELETE /v1/routines/{id} 204

When due, a worker posts the prompt to the bot's thread (from: system, kind: routine) and the bot replies like in chat. Each run is recorded in routine_runs. A run that fails also opens a routine approval ("Name stopped at Bot"); approving it runs the routine again.

What bots know when they answer

Every reply (chat, routine run and group chat) gets, on top of its conversation:

  • Memories the team kept (not pending), shared or for that bot — the newest, up to ~3,000 characters.

  • Passages from knowledge files that match the question (the search above), up to ~4,000 characters, with the file named so the bot can cite it.

  • A skill, when the message starts with its slash command (/weekly-digest for growth): its steps become instructions, and the skill's runs (and failed, when the model errors) count up.

  • Connected apps, when the workspace has any and the model supports tool calls: before answering, the bot may take up to 3 steps with them. Reads run at once with the stored token — github_search_issues, linear_search_issues, notion_search — and their results (with links) go into the reply's prompt. Writes — github_create_issue, linear_create_issue, slack_post_message — never run then: they become an approval (“Piper wants to: Post in #growth on Slack”, with the exact content) whose action holds the tool and arguments. Approving it runs the action once and posts “Done: …” (or why it failed) in the bot's chat and the Today feed.

The reply's body records what it drew on — {sources: ["pricing.md"], skill: "/weekly-digest"} — and the app shows it under the message.

Context window and compaction

GET /v1/bots/{bot}/context (optional project) returns what the bot reads on its next turn in your chat:

{ "model": "gemini-2.5-flash", "window": 1000000, "used": 13700, "compactAt": 800000,
  "entries": [{ "kind": "system", "label": "System prompt", "tokens": 3200 },
              { "kind": "tools", "label": "14 tools", "tokens": 9800, "count": 14, "apps": ["gmail", "slack"] },
              { "kind": "summary", "label": "…", "tokens": 58, "count": 8 },
              { "id": "…", "kind": "you", "label": "Break that down by team", "tokens": 8 }],
  "summary": { "upto": "<message id>", "text": "…", "entries": 8, "tokensBefore": 180 } }

Kinds are system, memory, tools, summary, you and agent. Tokens are estimates (about four characters each); the window comes from the model's name. POST /v1/bots/{bot}/context/compact folds all but the newest four turns, plus any earlier summary, into a new summary written by the bot's model, and returns the same report with folded: {entries, before, after} (no folded when there was too little to fold). A reply compacts on its own once the chat passes compactAt (80% of the window), then reads the summary and the turns after it.

Sign in with Google or GitHub

Method Path Notes
GET /v1/auth/providers {providers: ["google", "github"]} — the ones this server has set up.
GET /v1/oauth/{provider}/start?redirect=<app address> Web: redirects to the provider. redirect must be one of the app's addresses (BISCUIT_CORS_ORIGINS, BISCUIT_APP_URL).
GET /v1/oauth/{provider}/start?ticket=<random> Desktop: same, but the result is kept under the ticket.
GET /v1/oauth/{provider}/callback The provider returns here. Web: redirects to <redirect>/auth/callback#token=… (or #error=…). Desktop: shows “You're signed in”.
GET /v1/oauth/ticket?id=<ticket> Desktop: {token} once the browser sign-in finished (single use, 5 minutes); 404 pending until then.

The flow uses PKCE; its state is sealed (AES-GCM) and expires after 10 minutes. Only provider-verified emails are accepted.

Passwords and sessions

Method Path Body / notes
POST /v1/auth/forgot {email} → 202, the same answer whether or not the email has an account. Emails a link to {BISCUIT_APP_URL}/reset/{token}: single use, 1 hour; asking again replaces the old link. Public.
POST /v1/auth/reset {token, password} → a new session. Sets the password and signs out every other session. 400 invalid_link when used, replaced or expired. Public.
POST /v1/me/password {current, password} → a new session for this device; other sessions end. 403 wrong_password.
POST /v1/me/signout-all → a new session for this device; every token issued before now stops working.

Tokens carry their issue time; the membership check rejects tokens older than the user's last password change or sign-out-everywhere (401 signed_out). Invites and support requests are also emailed (see BISCUIT_SMTP_URL).

API keys

Method Path Body / notes
GET /v1/keys Your keys in this workspace: {id, name, prefix, createdAt, lastUsedAt?} — never the secret.
POST /v1/keys {name} → {key: "bsk_…", item}. The key is shown once; only its hash is stored. Up to 20 per person.
DELETE /v1/keys/{id} Revoke.

Send Authorization: Bearer bsk_… on any request: it acts as its creator in that workspace, with their current role, and stops working when revoked or when they leave the workspace.

Team, settings and usage

Method Path Body / notes
PATCH /v1/me {name} — your display name.
PATCH /v1/workspace {name} — owners and admins.
GET /v1/members {items: [{userId, name, email, role: owner|admin|member, joinedAt}]}
PATCH /v1/members/{user} {role: admin|member} — owners and admins; the owner's role can't change.
DELETE /v1/members/{user} Leave, or (owners and admins) remove someone. Never the owner. Their tokens stop working for this workspace within 30 s on every instance (at once on the one that handled it).
GET /v1/invites Pending, unexpired invites.
POST /v1/invites {email, role?} → {invite, token} — owners and admins. The token is shown once (only a hash is stored); the link is /invite/{token}, valid 14 days, single use.
DELETE /v1/invites/{id} Revoke a pending invite.
POST /v1/invites/accept {token} → {token, expiresAt, workspaceId} — the signed-in account's email must match (403 wrong_account).
GET /v1/usage This UTC month: {usage: {since, resets, tokens, calls, failed, byBot, byModel, byDay}, planTokens, usedPct}. The allowance is BISCUIT_PLAN_TOKENS (default 2,000,000).

Owner/admin checks read the role from the database, not the token, so a demotion applies at once.

Group chats

Method Path Body / notes
GET /v1/groups {items: [{id, name, botIds, leadId?, createdAt}]}
POST /v1/groups {name, bots: [slug or id] (1–12), lead?} — the lead must be one of the bots.
DELETE /v1/groups/{id} 204
GET /v1/groups/{id}/messages The latest 100, oldest first: {id, groupId, from: me|bot|system, botId?, text, at}
POST /v1/groups/{id}/messages {text} → 202. One bot answers in the background with the group's recent history: the one @mentioned, else the lead, else the first. Both arrive as group.message. 503 + Retry-After when the reply backlog is full.

Work on the user's computer

The desktop app can share folders with bots (Settings → Computer access) and allow commands. Its heartbeat (POST /v1/devices/heartbeat) then carries local: {folders: ["Projects", …], run: bool} — names only.

While that desktop app is online (seen in the last 2 minutes) and the person asking a bot shares folders, the bot's tool loop gets local_list, local_read, local_write and (if allowed) local_run, up to 12 steps. Each call is stored and sent to the app as the live event local.call; the app runs it through its Rust side (paths must resolve inside a shared folder, symlinks included; commands run in a shared folder for at most 60 s with output capped at 64 KB), asking the person in the app, with options (yes, yes for this session, no), before any write or command, and answers:

Method Path Body / notes
POST /v1/local/calls/{id}/result {state: done|failed|declined, result} — only the device's owner can answer, once.

Reads wait up to 30 s for an answer; writes and commands up to 3 minutes (the person is approving).

Voice

Method Path Body / notes
GET /v1/voice {transcribe, speak} — whether the server does speech (else the app uses the device's).
POST /v1/voice/transcribe Multipart audio (≤ 10 MB, webm/opus or m4a) → {text} (Whisper).
POST /v1/voice/speak {text, voice?} (≤ 4,000 chars) → audio/wav.

Both answer 404 not_configured without GROQ_API_KEY.

Devices, connected apps and support

Method Path Body / notes
POST /v1/devices/heartbeat {id (uuid the client keeps), name, platform, kind: desktop|web|mobile} — the app checks in while open (every 60 s while visible). Another user's device id is 409.
GET /v1/devices Your devices in this workspace, most recently seen first.
DELETE /v1/devices/{id} Forget one of your devices.
GET /v1/connections {items: [{id, provider, label, createdAt}], providers} — secrets are never returned.
PUT /v1/connections/{provider} {token, label?} — owners and admins. Providers: github, linear, notion, slack; the token's shape is checked, then it is stored AES-256-GCM sealed under BISCUIT_SEAL_KEY.
DELETE /v1/connections/{provider} Deletes the stored token.
GET /v1/support Your support requests.
POST /v1/support {subject, body, context?} → 201. Saved and logged (support request) for the team.

Library: skills, knowledge, projects; marketplace installs

Method Path Body / notes
GET /v1/skills {items: [{id, name, desc, body, draft, runs, failed, updatedAt}]}
POST /v1/skills {name: "/slash-command", desc?, body?, draft?} — names are unique per workspace (409 name_taken).
PATCH /v1/skills/{id} Any of {name, desc, body, draft}
DELETE /v1/skills/{id} 204
GET /v1/sources Knowledge files: {items: [{id, name, mime, size, state: ready|unreadable, createdAt}]}
POST /v1/sources Multipart field file, max 10 MB (413 over). Text formats (txt, md, csv, json, html, yaml…) are ready and searchable; other files are kept as unreadable.
GET /v1/sources/search?q= Up to 3 {sourceId, name, snippet} hits: full-text over the question's words (prefix match), exact phrase first, then by rank; the snippet highlights the matching passages.
DELETE /v1/sources/{id} 204
GET /v1/projects {items: [{id, name, brief: [[label, text]], botIds, createdAt}]}
POST /v1/projects {name, brief?: [[label, text]], bots?: [slug or id]}
GET /v1/installs Marketplace item ids added to this workspace.
POST /v1/installs {item} → 204; adding twice is a no-op. The app creates what the item brings (a bot, a skill) through their own endpoints first.

Now: approvals, activity and tasks

Method Path Body / notes
GET /v1/approvals Open items only: {items: [{id, botId, kind: approval|code|routine, title, detail, routineId?, state, createdAt}]}
POST /v1/approvals {bot, kind: approval|code, title, detail?} — a bot asks for a yes or a sign-in code.
POST /v1/approvals/{id}/resolve {decision: approve|decline, code?} — a code item needs a code of 6+ characters (400 otherwise); a routine item re-runs the routine. 409 already_resolved if answered before.
GET /v1/activity The latest 30 lines of the "Today" feed: {items: [{id, botId?, text, tone, at}]}
GET /v1/tasks {items: [{id, botId, text, state: working|done|failed, createdAt, doneAt?}]}
POST /v1/tasks {bot, text} → 202. Posted in the bot's chat, answered in the background, then marked done or failed.

Approval choices. POST /v1/approvals/{id}/resolve takes decision: approve | always | decline. always approves and saves an Allow automatically rule for that bot, tool and target (channel, repo, recipient or host). An approved action runs, its result is posted in the chat it came from as a system/action_result message, and the bot continues from there. Approvals from routines, triggers and delegations are unattended and carry expiresAt (30 minutes); unanswered ones become expired. review says why it asked (a rule, or auto review).

Action rules

Method Path Body Notes
GET /v1/github/pull?repo=owner/name&number=N — One pull request with files (and patches), commits, checks and comments. 409 if GitHub isn't connected.
POST /v1/github/pull/merge {repo, number, method} Merge (owner or admin). method: squash (default), merge or rebase.
POST /v1/attachments multipart file Attach any file (max 20 MB): {id, name, mime, size}. Send it with a message as body: {attachments: [{id, name, mime, size}]}; the text can then be empty.
GET /v1/attachments/{id} — Download your own attachment.
GET /v1/rules — {items: Rule[]}
POST /v1/rules {bot?, tool, target?, effect: ask|allow} tool is a tool name or *; target is matched (case-insensitive substring) in the action's channel, repo, recipient or host. 201 Rule
DELETE /v1/rules/{id} — 204

Rule = {id, botId?, tool, target, effect: ask|allow, source: user|always, createdAt}. Every tool call is reviewed in order: Ask first rules (always win) → Allow automatically rules → defaults (reading runs; sending, posting or creating in another app asks) → with BISCUIT_AUTO_REVIEW=on, a separate model checks writes a rule would allow and asks instead when they don't clearly serve the user's request.

The bot's computer (live browser)

A bot can work in a real, isolated headless Chrome on the server while you watch live, approve risky steps, or take control. Requires Chrome on the server (BISCUIT_COMPUTER=auto|on).

Method Path Body Notes
POST /v1/bots/{bot}/computer {task (≤2000), approval?: "auto"|"always"} 201 State. 503 computers_busy + Retry-After when all browsers are in use; 503 computer_unavailable if disabled.
GET /v1/computer — {live: State[], recent: Session[]}
GET /v1/computer/{id} — Current State.
GET /v1/computer/{id}/stream — SSE live view (below).
POST /v1/computer/{id}/control {action} pause · resume · takeover · handback · approve · deny · stop → State; 409 if invalid for the current state.
POST /v1/computer/{id}/input {type: click|scroll|key|text|secret|navigate|back, x, y (0–1), dy, key, text, url} Only while you have control (409 take_control_first otherwise).
POST /v1/computer/{id}/teach {action: start|stop} Teach a task: start takes control and records each input as a human step; stops by itself after 10 minutes (and on hand back or stop). Owner only. → State; 409 if not recording.
POST /v1/computer/{id}/skill-draft — Drafts a skill from the session's recorded steps with the default model (sections: When to use, Inputs, Steps, Done when, Ask before). Saved as a draft with requiredTools: ["browser"] → 201 {id, skill}; 409 nothing_recorded.
GET /v1/computer/{id}/audit — Every action considered, with the gateway decision.

State = {id, botId, task, status, url, title, label, waiting?, steps[], answer?, startedAt, approval, teaching?, teachEnd?} status: starting · running · paused · controlling · needs_you · done · failed · stopped. Step = {n, action, args, label, decision: allow|ask|deny, reason?, ok, error?, at, url?, source: bot|human, selector?}. Human steps keep no typed text: args.text is ‹typed› (with length) or ‹secret› for sensitive fields.

Stream events: state (first event carries all steps), step, frame {jpeg: base64, at} at ≤ 10 fps (latest frame wins; the last frame is always sent before done), done (final state; the stream ends).

The gateway decides every action before it runs and records it:

Rule Decision
Typing into password, one-time-code or card fields deny — use a saved login (fill_credential) or take control and type it yourself; the text is redacted from the audit log
fill_credential on a page whose host isn't one of the login's hosts (exact or subdomain) deny — lookalikes such as example.com.evil.io never match
Clicking buy / pay / checkout / delete / send / transfer / subscribe… ask — status needs_you until you approve, decline or take control
approval: "always" ask for every step
Hosts in BISCUIT_COMPUTER_DENY_HOSTS deny
Human-verification walls (CAPTCHA, "verify you are human") the bot stops and hands over (needs_you)
Any request to private, loopback, link-local or metadata addresses blocked inside the browser (SSRF guard)

When a task finishes, the answer is posted to the bot's thread as a kind: "computer" message.

The Vault (saved logins)

Logins bots fill on their own sites without the model ever seeing them. Values are sealed with BISCUIT_SEAL_KEY (AES-256-GCM) and are write-only: no response ever carries one.

Method Path Body Notes
GET /v1/vault — {items: VaultItem[]}
POST /v1/vault {name (≤80), hosts: string[] (1–20), username?, password?, totp?} 201 VaultItem. Needs a password or a TOTP seed. 409 name_taken for a duplicate name.
PATCH /v1/vault/{id} any of the above Replaces what's given; totp: "" removes the seed. The person who saved it, or an admin.
DELETE /v1/vault/{id} — 204. The person who saved it, or an admin.
POST /v1/vault/requests {bot, name, host, reason?} Posts a secure-form card in the bot's thread (kind: "vault_request", body.vaultRequest = {name, host, reason}). The card submits straight to POST /v1/vault, so values never pass through a chat message.

VaultItem = {id, name, kind: login|secret|totp, hosts[], username (mask, e.g. "j•••@x.com"), hasPassword, hasTotp, createdAt, updatedAt, lastUsedAt}. hosts accept a bare host or a URL (https://id.example.com/login → id.example.com).

On the computer, the model gets fill_credential {id, item, field: username|password|otp} and sees saved logins as name (hosts) only. One-time codes are generated on the server (RFC 6238). Each use adds an activity line naming the item (never the value); the audit row keeps only id, item and field.

Live events

GET /v1/events (SSE). First event: ready {workspaceId}. Then, for every committed change in your workspace:

bot.created · bot.updated · bot.deleted · message.created · memory.created · memory.updated · memory.deleted · doc.saved · routine.created · routine.updated · routine.deleted · approval.created · approval.updated · activity.created · task.created · task.updated · skill.created · skill.updated · skill.deleted · source.created · source.deleted · project.created · install.created · workspace.updated · member.added · member.updated · member.removed · connection.updated · connection.removed · group.created · group.deleted · group.message · local.call

Each data is {ws, type, data}; data is the full row, or {ref: true, id} for large payloads (refetch). resync means you fell behind and were dropped — refetch, then reconnect (EventSource reconnects automatically; retry: 3000). Comments : ping arrive every 25 s.

Operations endpoints

Path Purpose
GET /healthz Liveness (process up).
GET /readyz Readiness: DB reachable and realtime listener attached; includes pool stats.
GET /metrics Prometheus metrics (see OPERATIONS.md).
GET /v1/version {version, commit, model} — build stamped from the services/api/vX.Y.Z tag.

Bot capabilities and MCP

See capability setup and compatibility for permissions, desktop control, private memory, delegation, cron schedules and MCP.

Method Endpoint Purpose
GET / PUT /v1/bots/{bot}/permissions Read / owner-admin managed tool and skill grants
GET /v1/delegations Your delegation history
POST /v1/delegations/{id}/cancel Cancel your pending delegation
GET /v1/mcp/servers MCP connections and discovered tools, without credentials
PUT / DELETE /v1/mcp/servers/{name} Owner-admin connection management
POST /mcp Authenticated MCP Streamable HTTP endpoint

Routine creation/patch accepts cron, tz, and groupId; an empty groupId on PATCH restores the personal Bot conversation. Memory creation accepts scope: "private" (default) or "team"; team notes require owner review. Direct message listing is scoped to the authenticated person.