Tool reference

The 87 tools OpZero exposes over MCP, grouped by what they are for. You will rarely name one directly — Claude picks them from what you ask — but this is the map of what is possible.

Read this as a menu, not a manual
Every parameter table below is generated from the definitions the server actually serves, so it cannot drift from reality. What it does not tell you is which tool to reach for; that is in concepts. If you are ever unsure in a conversation, ask Claude to call docs.

Orientation

Where to start when you are not sure what is possible, what you already have, or why a call was rejected.

docsread only

With no arguments, the full tool catalogue grouped by domain plus the skill list. Pass a skill or uri to read one document, or a template name with its kind (site, mcp_server, agent) for a ready-to-deploy scaffold.

ParameterTypeDescription
topicstringCatalogue filter: a surface, a domain (projects, deployments, workloads, ...) or a tool name.
skillstringSkill to read: short name (assistants, gateways, connections, mcp-servers, agents, oz-desktop-app, src) or its skill:// URI.
uristringExact URI of any ref://, template://, doc:// or skill:// resource to read.
templatestringScaffold to return, by name. site: opzero, landing, portfolio, blog, static, vite-react, react-esm. mcp_server and agent: see `kind`.
kindsite | mcp_server | agentScaffold family for `template`. Required when the name exists in more than one family (minimal). mcp_server names: the hosted MCP server templates; agent names: minimal, scheduler, chat, chat-model.
system_statusread only

action status: your plan, usage, active projects, recent deployments, and how much of each per-plan cap is consumed — the cheapest way to confirm the connection works. action auth: your token type, identity, roles, scopes, real session expiry, and the health of every OAuth discovery endpoint. Run auth first on any auth error.

ParameterTypeDescription
actionreqstatus | authstatus: plan, usage, projects, recent deploys and per-plan caps. auth: this credential and the OAuth infrastructure.
ask_opzero_assistantread only

Ask a question about your own account in plain language. Answers over your recent activity, and renders an adaptive view on hosts that support MCP Apps.

ParameterTypeDescription
questionreqstringQuestion to ask (e.g., 'What deployments are in progress?', 'Is my preview ready?', 'How many projects do I have?')
include_contextbooleanInclude system context (projects, deployments, previews) automatically (default: true)
mcp_conformanceread only

Run the cross-client matrix against a hosted server after deploy: protocol negotiation, auth discovery, CORS, catalogue limits, resources, and MCP Apps across Claude, OpenAI, xAI, IDE, and baseline profiles.

ParameterTypeDescription
endpointstringAbsolute https URL of the MCP endpoint. Provide exactly one of endpoint, project, gateway.
projectstringA hosted MCP server project (id or name).
gatewaystringA gateway slug.
credentialstringBearer token to present. Without it the unauthenticated surface (challenge, discovery, CORS) is still checked; a token-mode hosted server uses its stored token.
clientsstring[]Restrict the run to these client profile ids. Omit to check every known client.
auth_modeoauth | token | publicendpoint targets only: how the endpoint authenticates. OAuth discovery checks apply to oauth; public and token report them as skipped.

Publishing pages and apps

Getting something live. One deploy tool, five formats that differ in how much you write: markdown is the least, files is the most control.

deploy

Deploy a site or app. format markdown: raw markdown becomes a themed page. format themed: body HTML wrapped in the OpZero design system. format html: one complete document, Tailwind compiled for you. format files: a multi-file site with full control. format react: a React component served live via ESM.sh; set ai and storage to give it a backend. Target an existing project to update it — a files map merges into the latest deployment (an empty string deletes a file) unless replace is true — or pass from to rebuild from stored source without sending any.

ParameterTypeDescription
formathtml | files | react | markdown | themedWhat is being deployed: html (one page), files (a path-to-content map), react (a component), markdown (a themed article), themed (an HTML body in the OpZero theme). Omit only with `from` or `commit`.
projectstringExisting project to deploy to (id or name). Omit to create a project named `name`.
namestringName for a new project (also its subdomain); auto-generated when omitted. A project of that name is reused unless new_project is true.
htmlstringhtml: the page, inline CSS and JS allowed; Tailwind classes compile automatically.
filesobject<string, string>files: path to contents. Merged into an existing project ("" deletes a file) for static sites, MCP server projects and agent projects alike.
codestringreact: component source (JSX/TSX) exporting a default component; react, recharts and lucide-react are available.
markdownstringmarkdown: GitHub Flavored Markdown; the title comes from the first heading unless `title` is given.
contentstringthemed: HTML for the page body; oz-card, oz-grid, oz-btn-primary, oz-hero and plain HTML elements are styled.
titlestringreact, markdown, themed: page title.
dependenciesobject<string, string>react: extra ESM.sh packages for the import map, { name: version }.
themedark | light | automarkdown, themed: colour theme, default auto.
stylelanding | article | dashboardthemed: layout, default article.
targetcloudflare | netlify | vercelHosting provider for a new project, default cloudflare. An existing project keeps its target.
aibooleanreact: enable server-side AI (window.claude.complete); Cloudflare target only.
storagebooleanreact: enable per-user persistence (window.storage, window.files); Cloudflare target only.
system_promptstringreact: pinned system prompt for the AI binding; clients cannot override it.
fromstringRedeploy stored files without content: "latest" or a deployment id of `project`.
commitstringRedeploy an MCP server `project` from its repository at this commit (12 to 64 hex) instead of a stored record. Not with a deployment id in `from`.
replacebooleanfiles: replace the whole file set of an existing `project` instead of merging into its current deployment.
new_projectbooleanAlways create a fresh project, even when one named `name` exists.
previewread only

Render one of your deployed pages inline in the conversation, on hosts that support MCP Apps. Identify it by URL, project ID, or project name.

ParameterTypeDescription
urlstringHTTPS URL of a page on opzero.sh (https://my-site.opzero.sh). Provide exactly one of url, project.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
live_canvas

An interactive widget showing your live site next to a prompt box. Edits typed there arrive back in the conversation, and the page hot-reloads once you apply them.

ParameterTypeDescription
htmlstringHTML to deploy as the initial canvas content. Tailwind utility classes are auto-compiled. Provide exactly one of html, project_id, or project_name.
namestringOptional project name when deploying html (reuses an existing project with the same name, else auto-generated).
project_idstringAttach the canvas to this existing project (UUID).
project_namestringAttach the canvas to the existing project with this name. Errors if ambiguous; use project_id then.

Projects and domains

Managing the containers your deployments live in.

project_inspectread only

action list: everything you have deployed, with URLs and status, filtered by status, hosting target, type, name, or staleness. action get: one project by name or ID with its latest deployment. action cleanup: an audit for duplicates, stale projects, and throwaway test deploys — recommends, never deletes.

ParameterTypeDescription
actionreqget | list | cleanupget: one project with its latest deployment (needs `project`). list: your projects, filtered and paged. cleanup: duplicates, stale and auto-generated projects worth deleting.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
statusactive | archived | deleted | alllist: default active.
project_typestatic | mcp_server | agentlist: filter by type.
targetcloudflare | netlify | vercellist: filter by hosting target.
name_containsstringlist: substring match on the name.
sort_bycreated | last_deploy | name | typelist: default last_deploy.
stale_daysintegerlist: only projects not deployed for this many days.
limitintegerlist: page size, default 50.
cursorstringlist: pagination.nextCursor from the previous page.
projectdestructive

action create: an empty container (usually unnecessary; deploy creates one). action rename: change the name without touching contents or history. action set_domain: point your own domain at a project, or clear it (Pro or Team, plus a CNAME at your registrar). action configure: turn AI or storage on or off for a running app, change its pinned system prompt, widen the model allowlist, or adjust caps — live within about a minute, no redeploy. action archive / unarchive: hide a project from default listings without deleting it.

ParameterTypeDescription
actionreqcreate | rename | set_domain | configure | archive | unarchivecreate: a new empty project (needs `name`). rename: needs `project` and `new_name`. set_domain: needs `project` and `domain` (empty string removes the domain; Pro or Team plan). configure: runtime bindings and the deploy webhook on an existing app (needs `project`). archive: takes the runtime offline and hides the project (needs `project` or `projects`, and `confirm: true`). unarchive: restores the record; the runtime needs a redeploy.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
projectsstring[]Up to 10 projects (ids or names) for a batch. Use instead of `project`.
namestringcreate: the project name (also its subdomain).
descriptionstringcreate: optional description.
targetcloudflare | netlify | vercelcreate: hosting target, default cloudflare.
new_namestringrename: the new name.
domainstringset_domain: the custom domain to point at the project; pass "" to remove the current one. The user must then add a CNAME to the project URL.
aiobjectconfigure: the window.claude.complete binding (Cloudflare-target apps).
storageobjectconfigure: the window.storage binding.
inject_sdkbooleanconfigure: inject the OpZero runtime SDK into served pages.
webhook_urlstringconfigure: URL POSTed on every deploy of this project; "" clears it.
confirmbooleanarchive: must be true. Archiving takes a hosted server or agent offline (410) and is restored only by a redeploy.
actor_chainobject[]Delegated caller chain, leaf last. Omit on a direct call.
project_deletedestructive

Take projects offline. Soft by default, with a seven-day window in which redeploying the name restores them; hard delete is immediate and permanent.

ParameterTypeDescription
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
projectsstring[]Up to 10 projects (ids or names) for a batch. Use instead of `project`.
hardbooleantrue: remove the record and every deployment now, no 7-day grace, no restore.
actor_chainobject[]Delegated caller chain, leaf last. Omit on a direct call.

Deployment history

Inspecting what shipped, and moving between versions.

deployment_inspectread only

action list: recent deployments across all projects, or scoped to one. action get: everything about one deployment, including the full deployed file contents — the way to recover source a conversation has lost. action status: status, detail, URL, file count, and size for a deployment, or the last five for a project.

ParameterTypeDescription
actionreqget | list | statusget: one deployment with its files (needs `deployment`). list: recent deployments, all projects or one `project`. status: status and history of a `deployment` or the last 5 of a `project`.
deploymentstringget, status: the deployment id.
projectstringlist: only this project. status: this project's last 5 deployments.
limitintegerlist: rows to return, default 10.
deploymentdestructive

action rollback: republish an older deployment’s files as a new deployment — forward-only, nothing is destroyed. action delete_record: permanently remove one deployment record from history.

ParameterTypeDescription
actionreqrollback | delete_recordrollback: republish the files of `deployment` as a new deployment of its project. delete_record: remove `deployment` from history permanently.
deploymentreqstringThe deployment id.

Assistants

Your own agent — model, pinned instructions, and tool backends — behind a chat endpoint.

assistant_inspectread only

action list: your assistants with slugs, models, connected servers, and status. action get: one assistant’s full config and its chat endpoint URL. action models: every model an assistant can run on — the live Vercel AI Gateway catalogue with context windows, prices, and capability tags.

ParameterTypeDescription
actionreqget | list | modelsget: one assistant in full (needs `assistant`). list: your assistants. models: the model catalogue an assistant can run on.
assistantstringAssistant slug or id.
statusactive | archived | alllist: default active.
limitintegerlist: page size, default 50.
providerstringmodels: only this provider (anthropic, openai, google, ...).
searchstringmodels: case-insensitive substring of the id or name.
assistantdestructive

action create: an assistant from a model, a system prompt, and connections to MCP servers that already exist, served from one of your app subdomains via oz.assistant(slug). action update: change the model, prompt, connected servers, or limits, effective immediately. action delete: remove it; the chat endpoint stops responding at once.

ParameterTypeDescription
actionreqcreate | update | deletecreate: a new assistant (needs `name`; reuses an existing slug). update: change the given fields only (needs `assistant` and one field). delete: needs `assistant` and `confirm: true`.
assistantstringAssistant slug or id.
namestringcreate: display name, e.g. "Support Bot". update: the new name.
slugstringcreate: URL-safe identifier (lowercase, hyphens); derived from name when omitted.
modelstringVercel AI Gateway model id (provider/model), default anthropic/claude-sonnet-5. Versions use a dot (claude-haiku-4.5). Unknown ids are refused; assistant_inspect models lists the catalogue.
system_promptstringPinned server-side; chat callers cannot override it.
mcp_serversobject[]Already-running Streamable HTTP MCP servers the assistant calls as tools, replacing the whole list: { url, name, headers | connection | auth: "owner" } each. One credential source per entry; owner auth (default for your own hosted servers, gateways and OpZero endpoints) mints a per-run owner token.
max_tokensintegerMax output tokens per reply, default 2048.
max_stepsintegerMax tool-use rounds per request, default 8, max 20.
rate_limit_per_minuteintegerPer-IP request limit on the chat endpoint, default 30.
daily_trigger_capintegerUnattended runs per UTC day (cron, webhook, ctx.assistants.ask), default 100, max 100000; 0 blocks them all.
visibilitypublic | privateprivate (default): the chat endpoint needs an owner bearer with deploy scope. public: anyone with the URL, rate limited per IP.
triggersobject | object[]Full replace of the trigger set, upserted by name; omit to leave triggers untouched. cron { type, name, schedule, prompt } runs the prompt on a UTC schedule (5-minute floor). webhook { type, name, auth: { mode: hmac | key, preset github | stripe | slack, secret, ... }, prompt_template, allowed_tools, max_steps } gets a signed endpoint at hooks.opzero.sh; the secret is required on create and never echoed.
confirmbooleandelete: must be true. The chat endpoint and every trigger stop immediately.
assistant_chat

Talk to one of your assistants server-side by slug — the way to test one before any app exists. Pass prompt for one turn or messages to replay a conversation; the whole reply comes back with a trace of each tool-use round.

ParameterTypeDescription
assistantreqstringSlug of one of your active assistants.
promptstringSingle-turn shorthand: one user message. Either prompt or messages.
messagesobject[]The conversation, oldest first, max 100 turns of role user | assistant. The assistant keeps no history; replay every turn it should see.

Hosted MCP servers and agents

Code you hand to OpZero that runs on a stable endpoint. kind mcp_server is a tools surface verified to speak MCP; kind agent is stateful code on the Cloudflare Agents SDK — WebSocket sessions, synced state, schedules, per-instance SQL. Scaffolds come from docs with a template name and kind.

workload_deploydestructive

Build and deploy TypeScript or Python. kind mcp_server: hosted TypeScript gets ctx.browser, ctx.connect, ctx.signals, ctx.loop, storage/files, resources, ingest, MCP Apps, and an explicit cron schedule when the server must wake itself. kind agent: each exported Agent class becomes a stateful instance type at <endpoint>/agents/<class-name>/<instance>; the result carries the URLs and a connect block for clients.

ParameterTypeDescription
kindreqmcp_server | agentmcp_server: a hosted MCP server (@opzero/mcp-runtime or opzero_mcp). agent: a Cloudflare Agents SDK agent.
filesreqobject<string, string>Source files keyed by path (max 50). mcp_server: server.ts/index.ts/main.ts or server.py; agent: agent.ts/index.ts/main.ts exporting Agent classes. .html/.css/.svg/.txt/.md import as strings.
namestringProject name; reusing a name redeploys in place unless new_project is true.
projectstringExisting project (id or name) to redeploy into. Omit for a new project or to match by name.
new_projectbooleanCreate a fresh project even if one with the same name exists.
auth_modetoken | public | oauthoauth (server default), token (agent default) or public. Omit on redeploy to keep the current mode.
secretsobject<string, string>Encrypted environment secrets (ctx.env.KEY / this.env.KEY). OPZERO_* keys are reserved.
runtimecloudflare | vercelmcp_server: runtime target, default cloudflare. vercel needs account entitlement.
allow_public_shared_storagebooleanmcp_server, public auth_mode only: allow ctx.storage shared-scope writes by anonymous callers.
multi_tenantbooleanmcp_server, oauth only: admit any authenticated OpZero user, each with their own ctx.user, storage and connections. Omit on redeploy to keep.
schedulestringmcp_server: cron (UTC, 5 fields or @hourly/@daily/@weekly/@monthly, min 5 minutes) for scheduled(). "" removes it; omit to keep.
durableboolean | objectmcp_server, Cloudflare only: opt into ctx.durable (per-server SQLite): true, or { schema, methods, alarm } mirroring defineServer({ durable }). Omit on redeploy to keep.
blobsbooleanmcp_server, Cloudflare only: opt into ctx.blobs (shared R2 under servers/<id>/). The source must also declare defineServer({ blobs: true }).
allowed_callersstring[]agent, oauth only: emails or AuthKit subjects (usr_...) admitted alongside you. [] clears; omit to keep.
classesstring[]agent: exported Agent class names to host. Defaults to every class extending Agent in the source.
idle_archive_daysintegeragent: days of inactivity before automatic archiving (default 14); 0 disables. Omit on redeploy to keep.
workload_inspectread only

action list and get: your servers or agents with endpoint, auth mode, classes, and last verification. action logs: deployment health, recent deploy records, and a live Cloudflare tail — the first stop when a server misbehaves. action secrets: configured secret keys, never values. action widgets: which MCP Apps widgets a server exposes and which tools render into each. action model_grants and model_usage: the models a workload may call and what it has spent.

ParameterTypeDescription
actionreqlist | get | logs | secrets | widgets | model_grants | model_usagelist: your servers or agents (needs `kind`). get: one workload (needs `kind`, `project`). logs, secrets, widgets: kind mcp_server (needs `project`). model_grants, model_usage: the model grant ledger.
kindmcp_server | agentmcp_server or agent. Required except for model_grants and model_usage, where it filters by grantee kind.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
limitintegerlist: page size, max 100 (default 50). logs: deployment records, max 50 (default 10). model_grants, model_usage: rows, max 200 (default 50).
cursorstringlist, kind mcp_server: pagination.nextCursor from the previous page.
sincestringlogs: ISO timestamp lower bound for deployment records.
grantee_kindinstall | run | home_assistant | mcp_server | agentmodel_grants: only grants held by this kind of workload; defaults to `kind` when given.
grantee_idstringmodel_grants: only grants held by this workload id.
include_revokedbooleanmodel_grants: include revoked grants (default false).
grant_idstringmodel_usage: only calls drawn against this grant.
workload_configuredestructive

action update: change a deployed server or agent’s settings without a rebuild. action secret_set / secret_delete: encrypted environment secrets, exposed as ctx.env.KEY (servers) or this.env.KEY (agents), hot-applied. action model_grant / model_grant_revoke: let a workload call platform models on your account, or stop it.

ParameterTypeDescription
actionrequpdate | secret_set | secret_delete | model_grant | model_grant_revokeupdate: settings without resending source (needs `kind`, `project`). secret_set / secret_delete: one encrypted secret (needs `kind`, `project`, `key`; set needs `value`). model_grant: needs `grantee_id`, `grantee_kind` or `kind`, `model` or `model_class`, and a budget. model_grant_revoke: `grant_id`, or `grantee_id` with a kind.
kindmcp_server | agentmcp_server or agent. Required for update and the secret actions; stands in for grantee_kind on the grant actions.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
keystringsecret_set, secret_delete: environment variable name. OPZERO_* and platform-reserved keys are refused.
valuestringsecret_set: the secret value; write-only, never returned.
auth_modetoken | public | oauthupdate: new auth mode. Moving to public needs confirm_public. Omit to keep.
confirm_publicbooleanupdate: required to move an authenticated workload to auth_mode public.
multi_tenantbooleanupdate, kind mcp_server, oauth only: admit any authenticated OpZero user. Omit to keep; false closes it.
allow_public_shared_storagebooleanupdate, kind mcp_server, public only: allow anonymous ctx.storage shared-scope writes.
schedulestringupdate, kind mcp_server: cron for scheduled() (UTC, min 5 minutes). "" removes it; omit to keep.
allowed_callersstring[]update, kind agent, oauth only: emails or AuthKit subjects admitted alongside you. Replaces the list; [] clears.
idle_archive_daysintegerupdate, kind agent: days of inactivity before automatic archiving; 0 disables. Applied in place when alone.
grantee_kindinstall | run | home_assistant | mcp_server | agentmodel_grant, model_grant_revoke: the workload kind being granted; defaults to `kind`. install, run and home_assistant are opaque ids.
grantee_idstringmodel_grant, model_grant_revoke: mcp server id or agent id (from workload_inspect get), or the opaque install/run id.
modelstringmodel_grant: explicit Vercel AI Gateway model id, e.g. anthropic/claude-sonnet-5. Or give model_class.
model_classreasoning | fast | embeddingmodel_grant: grant a class of models rather than one id (oz.json models[].class).
capabilitieschat | tools | embeddings[]model_grant: what the grant may be used for. Default ["chat"].
budget_periodday | monthmodel_grant: budget window, default month.
budget_usdnumbermodel_grant: USD ceiling per window. One of budget_usd or budget_calls is required.
budget_callsintegermodel_grant: call-count ceiling per window.
enforcementhard | softmodel_grant: hard (default) refuses once the ceiling is reached; soft records the overage and allows the call.
warn_at_pctintegermodel_grant: advisory warning threshold as a percentage of the ceiling.
reasonstringmodel_grant, model_grant_revoke: why, recorded as provenance.
grant_idstringmodel_grant_revoke: the grant id (mg_...) from workload_inspect model_grants.
workload_rotate_tokendestructive

Replace a token-mode server’s or agent’s shared access token. The old one stops working immediately; the new one is shown exactly once.

ParameterTypeDescription
kindreqmcp_server | agentmcp_server or agent.
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
list_mcpsread only

Your hosted MCP servers with what each client needs to add one: the claude.ai Add custom connector dialog for Claude, a claude mcp add command for Claude Code, config and install links for Cursor and VS Code, the URL for anything else. Renders as a widget with a client selector detected from the host and an Add button per server.

ParameterTypeDescription
clientclaude | claude_desktop | claude_code | chatgpt | cursor | vscode | otherPreselect the client the widget adds servers to. Omit to let the widget detect its host (Claude when it cannot).
name_containsstringOnly servers whose project name contains this text (case-insensitive).
limitintegerServers to return, most recently deployed first (default 50).

Gateways

One MCP endpoint fronting many backends, behind an exposure policy.

gateway_inspectread only

action list: your gateways with endpoints and backend counts; materializes the default gateway on first call. action get: one gateway in full — exposure policy, backend attachments with namespaces, and per-backend health.

ParameterTypeDescription
actionreqget | listget: one gateway with its exposure policy, endpoint URL and backends (needs `gateway`). list: your gateways with backend counts and endpoint URLs.
gatewaystringGateway slug or gateway id. "default" is the auto-created default gateway.
limitintegerlist: page size, default 50.
gatewaydestructive

action create: a federated endpoint at gw.opzero.sh/g/<slug>/mcp — choose the exposure mode carefully, search is right for Claude.ai. action update: name, exposure mode, inline limit, pinned tools, or tracking flag, live within about thirty seconds. action add_backend: attach a hosted server, an external MCP server, or an assistant under a namespace that prefixes its tool names; use an external connection for third-party credentials. action remove_backend: detach one, revoking any connection grant it held. action delete: remove the gateway and its attachments; backends survive, the default gateway cannot be deleted.

ParameterTypeDescription
actionreqcreate | update | delete | add_backend | remove_backendcreate needs `name`. update needs `gateway` and a field. delete needs `gateway`, `confirm`. add_backend needs `gateway`, `type`, `namespace`. remove_backend needs `backend_id`, `confirm`.
gatewaystringGateway slug or gateway id. "default" is the auto-created default gateway.
namestringcreate: the gateway name, e.g. "Support Bot Tools". update: the new name.
slugstringcreate: URL-safe identifier, derived from name when omitted. The endpoint is gw.opzero.sh/g/<slug>/mcp. "default" is reserved.
descriptionstringcreate, update: what this gateway is for.
exposure_modeauto | inline | search | pinnedcreate, update: search (constant meta-tools; required for Claude.ai), inline (tools merged as <ns>_<tool>), pinned (chosen tools inline), auto (default: search when track_all_deployed, else by inline_tool_limit).
inline_tool_limitintegercreate, update: tool count where auto flips from inline to search (default 40).
pinned_toolsstring[]update: qualified tool names (<namespace>_<tool>) shown inline in pinned mode.
track_all_deployedbooleancreate, update: federate every active deployed MCP server automatically (default false; the default gateway has it on).
client_capabilitiesobject<string, string>create, update: the MCP ClientCapabilities map declared to backends. Omit for the built-in map (ui, tasks); a configured map replaces it, {"extensions": {}} declares none.
reset_client_capabilitiesbooleanupdate: true returns the gateway to the built-in ClientCapabilities declaration. Not with client_capabilities.
typeopzero_mcp | external_mcp | assistantadd_backend: opzero_mcp (your hosted server, by server_id), external_mcp (any MCP server, by url or connection), assistant (exposed as ask_<slug>).
namespacestringadd_backend: tool-name prefix, unique per gateway (lowercase alphanumeric and underscores, e.g. "shop").
server_idstringadd_backend, opzero_mcp: the project id or the mcp_server id; both resolve to the current MCP endpoint.
assistant_slugstringadd_backend, assistant: the assistant slug.
assistant_idstringadd_backend, assistant: the assistant id (alternative to assistant_slug).
urlstringadd_backend, external_mcp: the Streamable HTTP MCP endpoint. Optional with connection; pass it to point a connection at a self-hosted instance on the same origin.
connectionstringadd_backend, external_mcp: an external connection (label, provider slug, or id) as the credential; attaching grants it to the backend. Needs a linked identity.
auth_bearerstringadd_backend, external_mcp: a bearer token sent to the backend. Stored encrypted, never returned. Prefer connection for OAuth services.
use_caller_tokenbooleanadd_backend, external_mcp: forward each caller's own OpZero bearer to the backend. OpZero service-owned endpoints only (https://code.opzero.sh).
tool_allowliststring[]add_backend: backend-local tool names to expose (omit for all). Required with the "opzero" connection, where it is also the grant.
positionintegeradd_backend: sort order in listings (default 0).
backend_idstringremove_backend: the backend attachment id (from gateway_inspect get).
confirmbooleandelete, remove_backend: must be true. Both take tools off the live gateway within about 30 seconds; a removed attachment's settings (tool_allowlist, position, auth_bearer) are gone.

External connections

OAuth grants to third-party MCP servers, stored encrypted and released only to workloads you name.

connection_inspectread only

action list: your connections with status, granted scope, and which workloads may use each. Status needs_reauth means the grant must be recreated.

ParameterTypeDescription
actionreqlistlist: your external connections with status, granted scope and the workloads granted each one.
limitintegerlist: page size, default 50.
connectiondestructive

action create: connect Notion, Linear, Sentry, Neon, Vercel, or any RFC 9728 server; returns a one-time authorize URL, and the grant is stored encrypted and refreshed for you. The "opzero" provider connects OpZero itself with no browser step, so a workload can run named platform tools as you. action grant: let one workload use one connection, or revoke that permission — the consent boundary, nothing is ambient; granting "opzero" additionally requires a tool_allowlist, whose entries may be a tool name or tool:action. action delete: revoke at the provider where supported, delete the stored credential, and drop every grant on it.

ParameterTypeDescription
actionreqcreate | delete | grantcreate needs `provider` or `url`. delete needs `connection`, `confirm`. grant (or revoke with `revoke`) needs `connection`, `subject_kind`, `subject_id`.
connectionstringdelete, grant: the connection id (from connection_inspect).
providerstringcreate: catalog provider slug (opzero, oz, notion, linear, sentry, neon, vercel). "opzero" is the platform; "oz" is your own server or gateway (see target).
urlstringcreate: Streamable HTTP MCP endpoint of any external server (must publish RFC 9728 metadata); overrides a catalog entry. Not with provider "opzero" or "oz".
targetstringcreate, provider "oz": a hosted MCP server slug, "gw" for your default gateway (the default), or "gw/<slug>".
labelstringcreate: a name for this connection, e.g. "Work Notion"; defaults to the provider name. Not with provider "oz".
grant_to_kindgateway_backend | assistant | mcp_server | agentcreate: also grant the new connection to a workload of this kind in the same step.
grant_to_idstringcreate: id of the workload to grant; required with grant_to_kind.
subject_kindgateway_backend | assistant | mcp_server | agentgrant: the kind of workload being granted or revoked.
subject_idstringgrant: the workload id: gateway backend id (gateway_inspect get), assistant id, mcp_server id, or agent id (workload_inspect).
notestringgrant: why this grant exists.
revokebooleangrant: true removes the grant instead of adding it.
tool_allowliststring[]grant: the tools the workload may call as you. Required for the "opzero" and "oz" providers; a current name, a legacy name, or tool:action.
confirmbooleandelete: must be true. The stored credential is revoked at the provider and every workload grant on it is removed.

Tasks and the builder

Long-running work on your account: tasks hosted servers mint, items waiting on your attention, and the Oz Build agent that builds and deploys apps through this same tool surface.

task_inspectread only

action list and get: tasks across your workloads, or one with its current status and result. action observe: wait for a task to change.

ParameterTypeDescription
actionreqlist | get | observelist: durable tasks across the account, filtered and paged. get: one task by id (needs `task_id`). observe: a task with its event log from a cursor and its approvals (needs `task_id`).
projectstringRestrict to one project (id or name). get/observe: skips the account scan.
task_idstringget/observe: the task id, from the call that minted it or from list.
home_idstringlist: only tasks bound to this home.
install_idstringlist: only tasks bound to this install.
actorstringlist: only tasks whose actor chain names this actor.
statusworking | input_required | completed | failed | cancelledlist: only this status.
run_kindhosted-mcp | assistant | agent | machine | sandboxlist: only tasks backed by this run kind.
toolstringlist: only tasks minted by this tool.
terminalbooleanlist: true for finished tasks only, false for in-flight only.
dead_letteredbooleanlist: true for dead-lettered tasks only.
afterintegerobserve: last event seq you already have. Omit to read from the beginning.
limitintegerlist/observe: page size.
cursorstringlist: cursor from the previous page.
task

action approve: let a task past an approval gate. action cancel: stop one. action attention: what is waiting on you — approvals, failures, and stalls (re-derived on every call, so it needs deploy scope). action ack: clear an attention item.

ParameterTypeDescription
actionreqapprove | cancel | ack | attentionapprove: decide one pending approval (needs `task_id`, `approval_id`, `decision`). cancel: record a cancel request (needs `task_id`). ack: acknowledge one attention record (needs `attention_id`). attention: what in this home is waiting on a person, re-derived unless `refresh: false`.
projectstringapprove/cancel: the project holding the task, if known. Skips the account scan.
task_idstringapprove/cancel: the task id.
approval_idstringapprove: the approval to decide, from task_inspect observe.
decisiongranted | deniedapprove: grant or deny.
attention_idstringack: the record to acknowledge, from action attention.
home_idstringattention: assert which home to read. Must be this account's home; it never selects another one.
kindtask_input_required | approval_pending | budget_threshold | run_failedattention: only this kind of attention.
include_acknowledgedbooleanattention: false returns open rows only. Default true.
refreshbooleanattention: false skips the re-derivation and reads the stored rows. Default true.
limitintegerattention: page size.
builder_run

action start: begin a turn on the durable Build run and wait up to wait_seconds for it to finish. action cancel: request a stop at the next tool boundary. Refused to workload grants, so a builder cannot start itself.

ParameterTypeDescription
actionstart | cancelstart (default): run one turn (needs `message`). cancel: record a cancel request against a run (needs `run_id`).
messagestringstart: what the builder should do this turn.
messagesobject[]start: prior turns to replay, oldest first (max 100). The run keeps no history of its own; omit for a fresh conversation.
wait_secondsintegerstart: how long to wait for a terminal state before answering, 0 to 60. Default 20; 0 returns as soon as the run is created.
run_idstringcancel: the run to request cancellation of.
reasonstringcancel: why, recorded with the request (max 200 characters).
builder_run_inspectread only

A Build run’s reply, tool calls, and stop facts.

ParameterTypeDescription
run_idreqstringThe runId builder_run returned.

Files

The file store your apps and hosted servers share, reached from app code through oz.files and from servers through ctx.files. These tools work on it from the conversation.

file_inspectread only

action list and search: browse or search files in a scope. action history: a file’s revisions. action attachments: what a file is attached to. action download_url: a short-lived URL for a file’s bytes.

ParameterTypeDescription
actionreqlist | search | history | attachments | grants | download_urllist: files under a prefix, metadata only. search: files matching every term of `query`. history: one file's revisions. attachments: one owner object's files or one file's owners. grants: file grants in force (owner role). download_url: a 5-minute presigned GET for an uploaded file.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
user_idstringAddress one end user's personal scope instead of the project-wide shared scope.
scopestringStorage scope: 'shared' (project-wide, the default), 'user:<id>', 'app:<inst_...>:<subject>' or 'home:<home_...>'. Wins over user_id.
prefixstringlist, search: only paths starting with this prefix, e.g. "reports/". Case-sensitive.
afterstringlist: resume after this path. attachments: the att_* id the previous page ended on.
reversebooleanlist: scan in descending path order.
querystringsearch: terms to match in path, display name or indexed text; every term must match.
cursorstringsearch: the previous page's cursor.
pathstringhistory, download_url: file path. Pass exactly one of path or handle.
handlestring | objectFile handle: the stable file_... id from a read or listing, unchanged by a rewrite or a move. Pass exactly one of path or handle.
beforestringhistory: resume after this revision. grants: the previous page's next_before (or an ISO-8601 instant).
owner_kindstringattachments: with owner_id, list that object's files in position order.
owner_idstringattachments: the app's own id for the owner object.
grant_idstringgrants: one exact grant by its fgr_* id, revoked or expired included.
home_idstringgrants: grants made inside one home.
grantee_kinduser | client | assistant | agent | mcp_server | gateway | gateway_backend | platformgrants: kind of actor holding the grant.
grantee_idstringgrants: id of the actor holding the grant.
grantor_subjectstringgrants: AuthKit subject whose authority the grants spend.
target_file_idstringgrants: grants over one file handle.
include_revokedbooleangrants: include revoked grants. Default false.
include_expiredbooleangrants: include lapsed grants. Default false.
limitintegerPage size. list: default 200, max 1000. search: max 100. history, attachments, grants: default 50, max 200.
file_readread only

Read one file’s contents.

ParameterTypeDescription
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
user_idstringAddress one end user's personal scope instead of the project-wide shared scope.
scopestringStorage scope: 'shared' (project-wide, the default), 'user:<id>', 'app:<inst_...>:<subject>' or 'home:<home_...>'. Wins over user_id.
pathstringFile path, e.g. "reports/q1.csv". Pass exactly one of path or handle.
handlestring | objectFile handle: the stable file_... id from a read or listing, unchanged by a rewrite or a move. Pass exactly one of path or handle.
encodingtext | base64 | noneHow to return the content. Default 'text'; 'none' returns metadata only.
file_write

Write one file, creating it or replacing its contents.

ParameterTypeDescription
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
user_idstringAddress one end user's personal scope instead of the project-wide shared scope.
scopestringStorage scope: 'shared' (project-wide, the default), 'user:<id>', 'app:<inst_...>:<subject>' or 'home:<home_...>'. Wins over user_id.
pathreqstringFile path, e.g. "reports/q1.csv". Printable ASCII, slashes allowed; no "..", leading/trailing slash, whitespace, or % ? # < > | * characters.
contentstringText content, stored as UTF-8. Pass exactly one of content or content_base64.
content_base64stringBase64-encoded bytes, for binary files. Pass exactly one of content or content_base64.
content_typestringMedia type to store and serve. Defaults to a guess from the path extension.
display_namestringUser-facing name shown instead of the path; may contain spaces and accents. Omitted on a rewrite keeps the existing name.
publicbooleanPublish at a credential-free URL. Writes to the shared scope; cannot be combined with user_id.
metadataobject<string, string>Arbitrary JSON kept alongside the file (max 4KB serialized).
if_revisionstringOnly write if the file is still at this revision; otherwise nothing is written and the result is a revision_conflict. Omit for last-write-wins.
file_upload

action prepare: a presigned upload for bytes too large to send inline. action finalize: register the uploaded object as a file.

ParameterTypeDescription
actionreqprepare | finalizeprepare: stage a large file and get a presigned PUT URL (needs `path`, `size`, `sha256`). finalize: verify the PUT object and commit it as the file (needs `upload_id`).
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
user_idstringAddress one end user's personal scope instead of the project-wide shared scope.
scopestringStorage scope: 'shared' (project-wide, the default), 'user:<id>', 'app:<inst_...>:<subject>' or 'home:<home_...>'. Wins over user_id.
pathstringprepare: the path the upload becomes, e.g. "media/demo.mp4". Same grammar as file_write.
sizeintegerprepare: exact byte length. finalize refuses an object of any other size.
sha256stringprepare: SHA-256 of the content, 64 hex characters or a 44 character base64 digest.
content_typestringprepare: media type to store and serve. Defaults to a guess from the path extension.
display_namestringprepare: user-facing name, shown instead of the path.
metadataobject<string, string>prepare: arbitrary JSON kept on the finalized file (4KB max serialized); provenance for a derived artifact belongs here.
upload_idstringfinalize: the upl_... id prepare returned.
filedestructive

action attach / detach: link a file to a project or workload, or unlink it. action move, trash, restore, delete: reorganise, soft-delete, recover, or permanently remove. action share / unshare and grant / grant_revoke: publish a file or let a named workload read it.

ParameterTypeDescription
actionreqattach | detach | move | trash | restore | delete | share | unshare | grant | grant_revokeattach: reference a file from an owner object (needs `owner_kind`, `owner_id`, `handle`). detach: drop one reference (needs `attachment_id`). move: rename (needs `path` or `handle`, and `to_path`). trash / restore: soft delete and its undo. delete: remove now (needs `path`). share / unshare: move a file into or out of a home's shared scope (owner role). grant / grant_revoke: write or revoke a file grant (owner role).
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates.
user_idstringAddress one end user's personal scope instead of the project-wide shared scope.
scopestringStorage scope: 'shared' (project-wide, the default), 'user:<id>', 'app:<inst_...>:<subject>' or 'home:<home_...>'. Wins over user_id. share: the scope the file is in; unshare: where it lands. grant: the folder scope granted.
pathstringmove, trash, restore, delete, share, unshare: the file path. Pass exactly one of path or handle.
handlestring | objectFile handle: the stable file_... id from a read or listing, unchanged by a rewrite or a move. Pass exactly one of path or handle.
to_pathstringmove: the new path, e.g. "reports/2026-q1.csv". Same grammar as file_write.
display_namestringmove: set the user-facing name at the same time. Omit to keep the current one.
if_revisionstringmove, trash, restore, delete: only act if the file is still at this revision; otherwise a revision_conflict result.
owner_kindstringattach: the app's kind for the owner object (lowercase letters, digits, underscores), e.g. document, message, task.
owner_idstringattach: the app's own id for that object.
roleinline | attachment | thumbnailattach: how the owner renders it. Default attachment.
labelstringattach: user-facing caption. Spaces and accents allowed; it is not a path.
revisionstringattach: pin this revision. Must be the file's current one, else the attach is refused with a revision_conflict.
positionintegerattach: ordering inside the owner object. Defaults to the end of its list.
added_bystringattach: actor that attached it, recorded for audit.
attachment_idstringdetach: the att_* id.
home_idstringshare, unshare: the home (home_...); defaults to the one the project is attached to. grant: the home the grant is made inside.
grantee_kinduser | client | assistant | agent | mcp_server | gateway | gateway_backend | platformgrant: kind of the actor that will make the call, the leaf of its actor chain.
grantee_idstringgrant: id of that actor, e.g. the hosted server id or assistant id.
actionsfile:read | file:write | file:list | file:search | file:share[]grant: exact actions granted. An action absent here is denied; no implied read behind a write.
target_file_idstringgrant: a single file handle (file_<ULID>). Mutually exclusive with scope.
path_prefixstringgrant: folder grant path prefix inside scope, no leading slash; empty covers the whole scope. Matched on a segment boundary.
expires_atstringgrant: ISO-8601 instant the grant lapses. Omit for one that lasts until revoked.
grantor_subjectstringgrant: AuthKit subject (usr_*) whose authority the grant spends. Defaults to the calling account.
grant_idstringgrant_revoke: the fgr_* id.

Source repositories

Every project has a source repository. These tools read and edit it with anchored, compare-and-swap writes, branches, and proposals reviewed before they land. A refused call answers as unknown.

src_inspectread only

action list, outline, view: the tree, a file’s symbols, or a rendered view. action log, diff, changed_paths: history and what changed. action branches, repos: what exists. action quota_get, race_check: limits and concurrent-edit safety.

ParameterTypeDescription
actionreqlist | log | diff | changed_paths | outline | branches | repos | view | quotalist: a directory at a snapshot. log: commit history. diff: two snapshots (needs `from` and `to`). changed_paths: paths differing between two snapshots. outline: headings or symbols of one file (needs `path`). branches: heads and protection. repos: your projects as repositories (no `project`). view: the repository view. quota: object counts, metrics, queue depths, limits.
projectstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
refobjectlist, log, outline, view: snapshot to read at. Defaults to { branch: "main" }; a branch resolves to its current head.
pathstringoutline: the file. log: restrict history to this path. view: file to show in the Browse tab.
prefixstringlist: directory to list ("" for the root). diff, changed_paths: restrict to this directory.
depthintegerlist: tree depth, default 1.
limitintegerlist: entries, up to 2000. log: commits, up to 100.
fromobjectdiff, changed_paths: the older snapshot. Defaults to { branch: "main" }.
toobjectdiff, changed_paths: the newer snapshot. Defaults to { branch: "main" }.
textbooleandiff: return a unified diff instead of per-path line counts.
context_linesintegerdiff: unified diff context lines.
max_text_bytesintegerdiff: byte budget for the unified diff.
beforestringlog: commit hash; start after this commit.
first_parentbooleanlog: default true, one entry per landed proposal.
proposalintegerview: proposal id to inspect in the Queue tab.
tabbrowse | queueview: which tab to open; default browse, or queue when proposal is given.
full_hashesbooleanReturn full 64 character hashes instead of 12 character prefixes.
src_readread only

Read one file by path, or several with paths, at a ref.

ParameterTypeDescription
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
pathstringOne file to read. Use `paths` for several.
pathsstring[]Several small files to read at one snapshot. Use instead of `path`.
refobjectSnapshot to read at. Defaults to { branch: "main" }; a branch resolves to its current head.
runintegerpaths only: run id whose candidate tree to read (the merge result a run would land), instead of ref.
start_lineintegerpath: first line of a line range.
end_lineintegerpath: last line of a line range.
sectionstringpath: markdown heading, with or without the leading #s. Returns exactly the section body bytes.
symbolstringpath: top level symbol name. Returns exactly the definition body.
max_bytesintegerpath: byte budget, default 16 KB; a longer body is truncated with a marker.
unchanged_sincestringpath: commit hash. If the blob is identical there, returns unchanged: true and no content.
max_total_bytesintegerpaths: byte budget across all files.
full_hashesbooleanReturn full 64 character hashes instead of 12 character prefixes.
src_write

Write a whole file with compare-and-swap against the version you read.

ParameterTypeDescription
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
branchreqstringBranch to move. A protected branch refuses direct writes; open a proposal instead.
messagereqstringCommit message.
mutation_idreqstringClient generated unique id (a UUID). Retrying with the same id returns the original result verbatim.
expect_headreqstringCommit hash you believe is the branch head. If it moved the server rebases per the tier or returns HEAD_MOVED.
filesreqobject[]Files to write, replace or delete in this one commit.
rebasepath | edit | booleanRebase tier when the head moved: path (apply if no touched path changed), edit (src_edit only: also reanchor edits), false (never).
trace_idstringW3C trace id, 32 lowercase hex characters, recorded in the commit.
src_edit

Apply anchored edits to a file — find this, replace with that — with compare-and-swap.

ParameterTypeDescription
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
pathreqstringThe one file to edit.
branchreqstringBranch to move. A protected branch refuses direct writes; open a proposal instead.
messagereqstringCommit message.
mutation_idreqstringClient generated unique id (a UUID). Retrying with the same id returns the original result verbatim.
expect_headreqstringCommit hash you believe is the branch head. If it moved the server rebases per the tier or returns HEAD_MOVED.
editsreqobject[]Anchored edits: old/new, a line range with range_hash, a section, or a symbol.
rebasepath | edit | booleanRebase tier when the head moved: path (apply if no touched path changed), edit (src_edit only: also reanchor edits), false (never).
trace_idstringW3C trace id, 32 lowercase hex characters, recorded in the commit.
src_branch

action create: a branch. action protect / unprotect: guard one from direct writes. action rebase and restore: move a branch onto a new base, or bring back a deleted path.

ParameterTypeDescription
actioncreate | protect | unprotect | rebase | restorecreate (default): a new branch at a commit. protect / unprotect: a branch moves only through merge finalization, with its validation policy (needs `branch`). rebase: replay the branch onto another snapshot (needs `branch`, `onto`, `message`, `mutation_id`, `expect_head`). restore: a new commit whose tree equals snapshot `to` (needs `branch`, `to`, `message`, `mutation_id`, `expect_head`).
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
namestringcreate: the branch name. Defaults to contrib/<you>/<n>.
fromobjectcreate: the commit the branch starts at. Defaults to { branch: "main" }; branch from the target head so a proposal needs no rebase.
require_validationbuild[]protect: validation classes a run must carry a pass for before finalize. Omit to leave unchanged; [] clears it.
ontostringrebase: commit hash (or unique prefix) to rebase onto, usually the target head.
overlapfail | branch | ontorebase: paths changed on both sides. fail (default): REBASE_CONFLICT. branch: keep the branch version. onto: take the onto version.
tostringrestore: commit hash whose tree becomes the branch content.
branchstringBranch to move. A protected branch refuses direct writes; open a proposal instead.
messagestringCommit message.
mutation_idstringClient generated unique id (a UUID). Retrying with the same id returns the original result verbatim.
expect_headstringCommit hash you believe is the branch head. If it moved the server rebases per the tier or returns HEAD_MOVED.
trace_idstringW3C trace id, 32 lowercase hex characters, recorded in the commit.
rebasepath | edit | booleanRebase tier when the head moved: path (apply if no touched path changed), edit (src_edit only: also reanchor edits), false (never).
src_propose

action open: propose a change set for review. action validate: run the candidate’s checks. action validation_record: attach a result. action reject: close one without merging.

ParameterTypeDescription
actionopen | reject | validation_record | validateopen (default): open a proposal from `branch` onto `target` (needs `summary`). reject: remove a proposal (needs `proposal`, `reason`). validate: run the platform build evaluator on a run (needs `run`). validation_record: record evidence on a run; refused for callers, evidence comes from validate.
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
branchstringopen: the source branch.
targetstringopen: the target branch, default main.
summarystringopen: what the proposal changes.
proposalintegerreject: the proposal id.
reasonstringreject: why.
runintegervalidate, validation_record: the run id from open or src_proposal_inspect; it must be evaluated (queued).
classbuild | test | policy | reviewvalidation_record: the validation class.
verdictpass | failvalidation_record: pass or fail.
evidenceobject<string, string>validation_record: evaluator output to keep with the record (at most 16 KB serialized).
mutation_idstringvalidation_record: client generated unique id; retrying with it returns the original record.
src_proposal_inspectread only

action list: open proposals. action get: one proposal with its diff and validation record.

ParameterTypeDescription
actionreqlist | getlist: proposals with their current runs. get: one proposal with its run, queue position and conflicts (needs `proposal`).
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
statequeued | conflict | rejected | mergedlist: filter by state.
targetstringlist: only proposals onto this branch, in queue order with positions.
minebooleanlist: only proposals you opened.
proposalintegerget: the proposal id.
src_merge_finalize

Land a validated proposal on its target branch.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
runreqinteger—
mutation_idreqstring—
expect_target_headstring—
expect_candidate_rootstringThe candidate root you validated or reviewed: full hash or a prefix of at least 12 characters. The call fails CANDIDATE_MISMATCH unless it names the run candidate.
src_sync

Sync a working copy. action checkout: the manifest to fetch. action upload_prepare and blob_missing: stage local changes. action commit: land the manifest as one commit.

ParameterTypeDescription
actionreqcheckout | upload_prepare | commit | blob_missingcheckout: the exact manifest of a snapshot or a run candidate. upload_prepare: presigned PUT URLs for blobs over 1 MB (needs `blobs`). commit: commit a manifest of blob hashes (needs `manifest` and the compare and swap fields). blob_missing: which hashes are not stored (needs `hashes`).
projectreqstringProject id or project name (the name is also its opzero.sh subdomain). An ambiguous name is refused with the candidates. You must own the project; the repository id is the project id.
refobjectcheckout: snapshot to flatten. Defaults to { branch: "main" }; a branch resolves to its current head.
runintegercheckout: run id whose candidate tree to flatten, instead of ref.
prefixstringcheckout: restrict the manifest to this directory. commit: restrict the change set to it.
blobsobject[]upload_prepare: the blobs to stage.
hashesstring[]blob_missing: full blob hashes to check.
manifestobject[]commit: every path with its blob hash; only differences from the tree at expect_head apply.
prunebooleancommit: delete paths present at expect_head but absent from the manifest.
branchstringBranch to move. A protected branch refuses direct writes; open a proposal instead.
messagestringCommit message.
mutation_idstringClient generated unique id (a UUID). Retrying with the same id returns the original result verbatim.
expect_headstringCommit hash you believe is the branch head. If it moved the server rebases per the tier or returns HEAD_MOVED.
trace_idstringW3C trace id, 32 lowercase hex characters, recorded in the commit.
rebasepath | edit | booleanRebase tier when the head moved: path (apply if no touched path changed), edit (src_edit only: also reanchor edits), false (never).

Everything else

Tools the server exposes that this page has not yet written up by hand. The descriptions below come straight from the server.

mcp_diagnosticsread only

Diagnose the MCP session from both ends. Reports what this server sees of the calling client (protocol era and version marker, client identity and capabilities from _meta, transport headers, resolved caller identity, scopes) and what is going on inside the server (implemented JSON-RPC methods, tool catalog with per-tool allow/deny for this caller, widgets, resources, runtime bindings and configuration).

Takes no parameters.

mcp_diagnostics_report

Companion to mcp_diagnostics, called by its widget: stores the host-side findings it collected (client_report) in a short per-caller ring and returns the full diagnostics report with them under clientReports. Writes only diagnostic state for the calling identity; anonymous callers on a public server get the report back but nothing is kept.

ParameterTypeDescription
client_reportreqobjectThe host-side findings the mcp-diagnostics widget collected: ui/initialize result, host capabilities and context, browser sandbox facts, bridge probe outcomes.
src_ingest

Commit a checkout back as a change set: the manifest is diffed against the tree at expect_head and only differences apply. Paths absent under prefix are deleted only with prune: true.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
branchreqstringBranch to move. Protected branches refuse direct writes; open a proposal instead.
messagereqstringCommit message.
mutation_idreqstringClient generated unique id (a UUID). Retrying with the same id returns the original result verbatim.
expect_headreqstringCommit hash the caller believes is the branch head. If the head has moved the server attempts a rebase per the rebase tier, otherwise it returns HEAD_MOVED.
trace_idstringW3C trace id, 32 lowercase hex characters, recorded in the commit.
rebasepath | edit | booleanRebase tier when the head moved. path: apply if none of the touched paths changed. edit (src_edit only): also reanchor old/new, section and symbol edits against the current blob. false: never rebase.
prefixstringRestrict the change set to this directory.
prunebooleanDelete paths present at expect_head but absent in the manifest.
filesreqobject[]Full manifest of the checkout under prefix. Reference unchanged blobs by blob_hash (a short hash is fine) to avoid resending bytes.
src_race_check

Serialization self test (spec R8): N concurrent src_write calls race one throwaway branch with the same expect_head, fanned out into the repository object at once. Exactly one must land and every other writer must see HEAD_MOVED at the winner.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
writersintegerConcurrent writers, default 8.
src_exportread only

Raw repository export for replay: refs with full heads, commits in sequence order with their stored objects (after and limit page them), and objects by full hash. Proposal, queue and mutation records are not exported.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
afterintegerSequence index to start commits from (0 is the first commit). With limit, pages the commit list.
limitintegerCommits per page, at most 500.
hashesstring[]Objects (blobs, trees, commits) to return by hash. Entries past the response budget come back under pending; request them again.
src_replay

Replay a standalone src repository into this project repository (spec 1.1 section 4.5): the platform reads the source under your identity, walks its commits in sequence order, inserts blobs and trees by hash (R2 objects copied by key), re-encodes every commit and refuses with REPLAY_DIVERGENCE naming the commit if a hash differs (the target is left untouched), and recreates the refs at the same heads. Idempotent and resumable.

ParameterTypeDescription
source_serverreqstringThe standalone server: its slug (for example src) or its MCP URL (https://<slug>.mcp.opzero.sh/mcp). Must be a hosted server this account owns.
source_reporeqstringRepository id on the source server.
projectreqstringTarget project (slug or id). Its repository must be pristine (first touch only) or a previous replay of the same source.
src_fpvread only

Open a first-person operational view of a project repository. Returns a bounded, read-only snapshot of branch/HEAD, recent commits and paths, proposals/runs/queues, quota pressure, metrics and audit activity.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
refstringOptional branch name or snapshot/commit prefix. Defaults to main.
src_ideread only

Open the project repository in an editor: file tree, branches, log, proposals, and the contents of one file, with syntax highlighting and editing in the view. Read-only itself - it returns a snapshot.

ParameterTypeDescription
projectreqstringProject slug (its name) or project id. The repository id is the project id; you must own the project.
pathstringOptional file to open. Omitted, the view opens on the tree with no file loaded.
refstringOptional branch name or commit prefix. Defaults to main. A commit opens the session read-only.
desktop_open

Open the Oz OS desktop as an MCP App widget. Returns its current layout, app catalogue and browser continuation.

ParameterTypeDescription
session_idstring—
desktop_get_stateread only

Read one desktop session: windows in back-to-front order, minimized state, geometry, dock, wallpaper and revision. Does not capture app pixels, read app documents or start workloads.

ParameterTypeDescription
session_idstring—
desktop_list_appsread only

List apps with the exact app IDs accepted by desktop_launch_app. Narrow before you read: category (system, site, service, agent, assistant, app), project_type (static, mcp_server, agent), name_contains, sort_by (name, category, recent) and limit.

ParameterTypeDescription
categorysystem | site | service | agent | assistant | app | system | site | service | agent | assistant | app[]—
project_typestatic | mcp_server | agent—
name_containsstring—
sort_byname | category | recent—
limitinteger—
fieldssummary | full—
desktop_list_sessionsread only

List your desktop sessions. Background sessions are independent working spaces for agents; shared sessions are observed and controlled with the user.

Takes no parameters.

desktop_create_session

Create a named background or shared Oz desktop session. Each agent should create a background session and target its returned session_id, avoiding focus conflicts with the user.

ParameterTypeDescription
namereqstring—
modebackground | shared—
desktop_end_session

Discard a temporary background desktop session when an agent is done. Requires its current expected_revision.

ParameterTypeDescription
session_idreqstring—
expected_revisionreqinteger—
desktop_launch_app

Open an app by its exact catalogue app_id, or restore and focus its existing window. Requires expected_revision from desktop_get_state.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idreqstring—
desktop_focus_window

Bring an open window to the front and restore it if minimized. Target a background session to avoid changing the user screen.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idreqstring—
desktop_close_window

Close one window. Saved documents, deployments and durable workloads are not deleted or cancelled.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idreqstring—
desktop_minimize_window

Minimize or restore an open window without closing its view. Minimized browser views remain mounted and may keep using resources.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idreqstring—
minimizedboolean—
desktop_set_window

Move, resize, maximize, restore, or snap a window left/right. Coordinates are desktop CSS pixels; clients clamp them to their available screen.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idreqstring—
xnumber—
ynumber—
widthnumber—
heightnumber—
modenormal | maximized | left | right—
desktop_set_dock

Replace the dock with the ordered app_ids provided. Every id must be a current catalogue app_id; an unknown id is rejected and nothing is written.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
app_idsreqstring[]—
desktop_set_wallpaper

Set this desktop wallpaper: dune (golden hour), night (after hours), or sage (quiet morning).

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
wallpaperreqdune | night | sage—
desktop_set_chrome

Set whether the dock and menu bar automatically hide and reveal at the screen edges. Both default to auto-hide.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
dock_auto_hideboolean—
menu_auto_hideboolean—
desktop_show_desktop

Minimize every window in the selected desktop session. Does not stop applications or background work.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
desktop_save_layout

Persist the desktop UI layout with optimistic concurrency. Window and dock ids that are no longer in the catalogue are dropped from the saved layout rather than rejected, so a deleted project cannot wedge later saves.

ParameterTypeDescription
session_idstring—
expected_revisionreqinteger—
layoutreqobject—
desktop_share_signal

Exchange short-lived WebRTC screen-sharing negotiation messages inside an owned shared desktop session. UI-only.

ParameterTypeDescription
session_idstring—
peer_idreqstring—
afterinteger—
targetstring—
kindjoin | offer | answer | leave—
datastring—
terminal_open

Requires read and deploy scopes. Open or create an owner-scoped Oz Terminal session shared by the desktop and MCP widget.

ParameterTypeDescription
session_idstringTerminal session UUID returned by terminal_open.
titlestringTitle for a new session.
terminal_listread only

List your recent terminal sessions so a user or agent can resume the same transcript. Requires a direct user connection; workload grants cannot access shared terminal sessions.

Takes no parameters.

terminal_getread only

Read a terminal transcript, including commands in flight. A running entry is not proof its underlying task stopped or completed.

ParameterTypeDescription
session_idreqstringTerminal session UUID returned by terminal_open.
if_revisionintegerLast observed session revision. Return entries only when it changed.
include_commandsbooleanInclude the current caller-visible command catalogue.
terminal_completeread only

Return caller-visible command, parameter and enum completions plus authoritative argument validation. Never execute.

ParameterTypeDescription
commandreqstringRegistered tool name or tasks/projects/logs/status alias, followed by --argument value pairs or a JSON object. No shell syntax.
terminal_observeread only

Read one fresh task or observability snapshot without adding a transcript entry. Supports `task_inspect` (actions list, get, observe), `workload_inspect` (action logs), `log_query` and the obs_* read tools; native permissions still apply.

ParameterTypeDescription
commandreqstringRegistered tool name or tasks/projects/logs/status alias, followed by --argument value pairs or a JSON object. No shell syntax.
terminal_executedestructive

Requires read and deploy scopes. Run a schema-validated platform command in a shared terminal.

ParameterTypeDescription
session_idreqstringTerminal session UUID returned by terminal_open.
commandreqstringRegistered tool name or tasks/projects/logs/status alias, followed by --argument value pairs or a JSON object. No shell syntax.
request_idreqstringFresh UUID per intended command. Reuse exactly this ID after an uncertain response to avoid repeating the effect.
browser_openread only

Open Oz Browser, the default Oz OS web browser, as an MCP App. Returns saved tabs, history and owned deployed-project URL suggestions without starting paid runtime.

Takes no parameters.

browser_get_stateread only

Read your Oz Browser tabs, active tab, history, deployed project URL suggestions and revision. Does not start or refresh a remote browser.

Takes no parameters.

browser_navigate

Navigate the selected tab to an HTTP(S) URL or search query. Requires expected_revision from browser_get_state.

ParameterTypeDescription
expected_revisionreqinteger—
urlreqstring—
tab_idstring—
browser_new_tab

Open a browser tab, optionally at a URL. Supports up to twelve tabs.

ParameterTypeDescription
expected_revisionreqinteger—
urlstring—
browser_select_tab

Select a tab in your shared Oz Browser and return its page. Requires expected_revision; may resume metered remote browsing.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
browser_close_tabdestructive

Close a browser tab. Unsaved page work may be lost; saved history remain.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
browser_back

Go back one entry in the tab navigation history. Requires expected_revision.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
browser_forward

Go forward one entry in the tab navigation history. Requires expected_revision.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
browser_reloaddestructive

Reload a browser tab and return its page. Requires expected_revision.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
browser_read_pageread only

Read the selected remote browser page as untrusted text and links, with viewport coordinates in the widget. May resume metered browsing after idle expiry; resumed tabs have fresh cookies and no former back/forward stack.

ParameterTypeDescription
tab_idreqstring—
browser_interactdestructive

Interact with a remote page: click at 1280x800 viewport coordinates, type text into the focused field, press a named key, or scroll by delta_y pixels. Requires expected_revision.

ParameterTypeDescription
expected_revisionreqinteger—
tab_idreqstring—
actionreqclick | type | key | scroll—
xnumber—
ynumber—
textstring—
keyEnter | Tab | Escape | Backspace | ArrowUp | ArrowDown | ArrowLeft | ArrowRight | Space | Delete | Home | End | PageUp | PageDown—
delta_ynumber—
browser_clear_historydestructive

Clear saved Oz Browser address autocomplete history. Requires expected_revision.

ParameterTypeDescription
expected_revisionreqinteger—
browser_stopdestructive

Close the remote browser and discard its temporary login cookies. Saved tab URLs and history remain.

ParameterTypeDescription
expected_revisionreqinteger—
Next
Other clients

Connecting from Claude Code, Cursor, Codex, and raw HTTP.