The MCP server binary is bundled with the app—most users simply enable it in Settings. Node.js is only required if you intend to rebuild the server source.
Setup
Option 1: Via Schaltwerk Settings (Recommended)
1
Open Settings
Click the gear icon in the top bar to open Schaltwerk Settings
2
Configure MCP
Go to Agent Configuration, select your agent (Claude Code, Codex, OpenCode, or Gemini), and toggle Enable MCP. Schaltwerk writes the necessary config pointing to the embedded server.
3
Restart Agent
Restart your orchestrator session to load the MCP configuration
Option 2: Manual Setup
If you prefer manual setup or your agent doesn’t appear in settings:- Codex
- Claude Code
- Factory Droid
- Manual Config
What Can Agents Do?
Once set up, your AI agent can use these MCP tools to automate session management:Create Sessions
Agent can create new specs or sessions directly in Schaltwerk
Update Specs
Modify existing spec content before starting work
Start Work
Convert specs to running sessions with worktrees
Check Status
Query all sessions and their current state
Open PR Modal
Agent can request opening the Create PR dialog (you review and confirm in the UI)
Setup Scripts
Read the current worktree setup script, then propose and apply updates after confirming which untracked config (e.g., .env) should be copied.
Pull Requests via MCP
Agents can request that Schaltwerk open the Create Pull Request dialog for a running/reviewed session:- Tool:
schaltwerk_create_pr - Result: Schaltwerk opens the PR modal with suggested values
- You still confirm the PR in the UI (the tool does not create the PR directly)
Worktree Setup Scripts via MCP
- Read first: Call
schaltwerk_get_setup_scriptto load the existing script. - Inspect & confirm: Check the repo for untracked config (e.g.,
.env,.env.local,.npmrc) and confirm with the user which files should be copied into new worktrees. - Write full script: Send the complete updated script (with shebang) via
schaltwerk_set_setup_script. The script runs once per new worktree withWORKTREE_PATH,REPO_PATH,SESSION_NAME, andBRANCH_NAMEenv vars. - UI safeguard: When edited in the app, Schaltwerk prompts before saving. MCP changes rely on the agent following the read/confirm/write flow above.
Spec Discovery API
Agents can inspect specs without crawling the full session list. Use the following MCP tools when you need to review planning docs before starting work:schaltwerk_spec_list— returns an array of spec summaries{ session_id, display_name?, content_length, updated_at }schaltwerk_spec_read— fetches the full markdown plus metadata for a given spec
content_length is counted in Unicode code points so agents can paginate or highlight accurately.
How It Works
1
Agent receives task
You give your agent a coding task
2
Agent creates session
Agent uses MCP to create a Schaltwerk session with the task description
3
Schaltwerk updates
New session appears in your sidebar automatically
4
You review
Check the session, test the code, and merge when ready
Use Cases
Task Breakdown
Task Breakdown
Break down a large feature into multiple parallel sessions:
- Agent creates multiple specs for different components
- Each spec becomes a separate session
- Work on all parts simultaneously
- Review and merge independently
Code Review Automation
Code Review Automation
Let your agent help with code reviews:
- Agent analyzes pull requests
- Creates Schaltwerk session with review notes
- You see the session appear in sidebar
- Review agent’s feedback and suggestions
Multi-Agent Workflows
Multi-Agent Workflows
Coordinate multiple AI agents:
- Orchestrator agent breaks down work
- Creates sessions for implementation agents
- Monitors progress across all sessions
- Collects results when ready
Troubleshooting
Sessions not appearing
Sessions not appearing
Make sure Schaltwerk is running and your project is open. The MCP server only works when Schaltwerk is active.
Agent can't connect
Agent can't connect
Restart your agent after setting up MCP. The MCP tools are only loaded when the agent starts.

