Agents · MCP
Drive workbooks from your agent.
The CLI ships an MCP (Model Context Protocol) server. Point any MCP-aware client at it and an assistant can list groups, scaffold projects, build, publish, and manage runtime settings as structured tool calls — no scraping, no glue scripts.
Claude Code
Either install the official skill (recommended — it ships with Workbooks-specific authoring guidance) or wire up MCP directly.
Option A — install the skill
curl -fsSL https://workbooks.sh/skill | sh
Restart Claude Code; workbook init,
workbook publish, and authoring help are available
via the /workbooks skill.
Option B — wire up MCP
Add to your .mcp.json (project or user-level):
{
"mcpServers": {
"workbooks": {
"command": "workbook",
"args": ["mcp", "serve"]
}
}
}
Cursor
Cursor reads .cursor/mcp.json with the same shape as
Claude Code's config. Drop the snippet above into that file and
restart Cursor.
Codex / other clients
Any MCP-compatible client works — Continue, Zed, Aider, custom LangChain agents. Stdio transport; no network ports to manage.
What the agent can do
- list_groups — your groups across the workspace
- list_workbooks — workbooks inside a group
- init_project — scaffold a new workbook project at a path
- build — compile a project to
dist/ - publish — upload a built artifact to Studio
- inspect — print metadata for a workbook file
- unbundle — recover source from a built file
- get_runtime_config / set_runtime_config — manage
WB_ENVvalues
Authentication
workbook publish uses the same OAuth flow whether
invoked by you or by an agent. The agent triggers the flow once
via a browser; the token is stored in your OS keychain. Agents
cannot read the token directly — only the CLI can.