Baton Manual

Chapter 14

AI agents

Baton ships an MCP server, @dudko.dev/baton-mcp, so an AI agent — Claude Code, Cursor, VS Code, Codex — can list, read, edit and run the requests in a workspace. It is a program on your own machine, started by the agent’s host like any other MCP server; nothing about it passes through a service of ours.

14.1Connecting an agent

Settings → Agents, here in the browser build, where there is no workspace folder to configure. — 1: Whether the app is listening for agents; 2: Write the MCP entry for one host; 3: Without the app: the same entry works on the files
  1. Whether the app is listening for agents
  2. Write the MCP entry for one host
  3. Without the app: the same entry works on the files
Figure 38: Settings → Agents, here in the browser build, where there is no workspace folder to configure.

1 says whether the app is listening for agents. 2 writes the MCP entry for one host — npx @dudko.dev/baton-mcp on this workspace — into that host’s configuration inside the workspace. The configuration is committed with the rest, so a colleague’s checkout is set up too. The buttons need a workspace folder, which is why they are greyed out in a browser. 3 is the other way an agent works, below: with the app closed, the same entry still works on the files.

14.2Through the app, or on the files

When the desktop app has the workspace open, the agent works through the app:

The app listens on 127.0.0.1 only, with a token made for that launch, and answers nothing else — not another machine, not a web page. The switch in Settings → Agents turns it off.

With the app closed — and always in a browser or on a phone, neither of which can listen for an agent — the agent works on the files: its edits are written straight to the YAML, and it cannot send anything unless the server was started with --allow-run.

The agent does not commit. Whatever it changed is in the working tree, and committing it is yours to do — or to tell it to do — like any other change.