Connect an agent
Add Frond to Claude Code, Codex, Cursor or any MCP client, and the tools it exposes.
Agents talk to Frond over MCP. Locally that is stdio: your MCP client starts petal mcp for the project folder.
Register the project
Once per project, from its folder:
petal project add <name>
Or let the agent call petal_setup with create_project.
Add the server to your client
{
"mcpServers": {
"petal": {
"command": "petal",
"args": ["mcp", "--path", "/path/to/project"]
}
}
}
Each petal mcp process is one agent connection, scoped to the project at --path (default: the current directory). Set the connection id with --connection <id> or PETAL_CONNECTION; the default is mcp-<uuid>.
Frond reads the client’s name from the MCP handshake to label the session (Claude Code, Codex, Cursor, VS Code, Gemini, OpenCode or other). The label is for display only and never used for access decisions.
Sessions
A session opens on the first tool call that resolves the project. Its focus is the delivery the agent last wrote to; reads never move it. petal mcp sends a heartbeat every 20 seconds and ends its session when the client stops. petal serve ends sessions it has not heard from for 60 seconds.
Tools
| Tool | What it does |
|---|---|
petal_context |
Connection, project, usage policy and next action, deliveries, current version. Pass sinceVersion to get only changes. |
petal_delivery_get |
List or get deliveries, tasks, requests, tests and observations; read preferences. |
petal_delivery_update |
Create deliveries, set phase, spec and links, add, edit, move and remove tasks, request a merge review, add observations. |
petal_request |
Ask questions and approvals, record answers, withdraw, and check a gate. |
petal_tests |
Save browser tests, run one, rerun the suite, cancel, read runs and evidence. |
petal_messages |
List, send and acknowledge messages. |
petal_improve |
Record signals, read clusters, draft and edit improvements. |
petal_setup |
Project setup: create the project, set usage, manage applications and environments. |
petal_open_app |
Return the dashboard URL for a delivery; locally it also opens the browser. |
Tools with an op accept op: "schema" with of to return the JSON Schema of another op. Ops that edit an existing entity take an optional expectedVersion and fail with a conflict when it moved on.
Hosted
In hosted mode agents connect over HTTP at /mcp with a project-scoped agent token (petal_at_…). See Hosted mode.