Documentation
Concepts, server operations, agent connectors, and the protocol reference for Octostaff.
Getting started
3What OctoStaff is
The problem OctoStaff solves, the packages that solve it, and how a single turn travels from a person to an agent and back.
Quickstart
Go from an empty directory to a running Bubble server with a bot principal, a thread, and a connected Claude Code agent.
Terminal client
Install bubble-tui, connect to a Bubble server, and use profiles, login, interactive threads, and scriptable commands.
Concepts
5What Bubble is
What Bubble is, the core concepts it builds on, and how the rest of these docs fit together.
Threads
The BubbleThread shape, subthreads, and the store operations that create and inspect threads.
Events
Every event shape Bubble defines, how sequence numbers and timestamps are assigned, and how clients append and subscribe.
Principals
The actor identity behind every Bubble request — kinds, ids, profiles, the `me` alias, and bot-managed local tokens.
Authorization
Targets, roles, capabilities, grants, the policy decision rules, and how participants fall out of the grant table.
Running a server
3Launching a server
Run a Bubble server with the bundled CLI, or embed it programmatically when you need more control.
Authentication
How a bearer token becomes a known principal — the request shape, the dispatcher, and every built-in driver.
Bootstrapping
How an empty store goes from cold start to a functional system — config seeding, first-time user registration, and bot creation.
Connecting agents
8Claude Code agents
What claude-scuba is, what it bridges, and what is in (and out of) Stage 1.
How claude-scuba works
How claude-scuba turns the interactive Claude Code CLI into a long-running, multi-participant agent daemon on top of Bubble.
Running a Claude Code bot
Run claude-scuba with the bundled CLI, or embed it programmatically.
Codex agents
What codex-scuba bridges, which Codex app-server versions it accepts, and what the integration can and cannot do.
Running a Codex bot
Install codex-scuba, point it at a Codex model through native Codex configuration, and configure the broker, backlog recovery, and container image.
Hosted A2A and ACP agents
What reef is, what it bridges, and what is in (and out of) the v1 connector.
How reef works
How reef turns a hosted A2A agent into a Bubble participant — the relay state machine, the consume/work split, and how interrupts unwind a streaming fetch cleanly.
Running a reef connector
Run reef with the bundled CLI, point it at a real or mock A2A agent, or embed the connector inside another Node process.
Building on OctoStaff
3TypeScript SDK
What the SDK ships, how the subpath exports map to source modules, and where to start reading.
Thread assembler
Turn a sequenced Bubble event log into BubbleMessage snapshots — stateful per-thread assemblers and the partHandlers extension surface.
Artifact protocol
The global artifact control plane, authorization scopes, staged byte transfers, and SDK contract.
Reference
3HTTP protocol
The REST surface — every route, what it returns, and the capability checks each one performs.
WebSocket protocol
The live frame protocol — connection model, subscription lifecycle, fire-and-forget appends, and how failures are signalled.
Terminal client reference
bubble-tui connection flags, profiles, credentials, interactive commands, keyboard shortcuts, and scriptable output.