Claude Code Integration
Claude Code is Anthropic’s official CLI and VS Code extension for Claude. This guide covers integrating Moira with Claude Code.
Prerequisites
Section titled “Prerequisites”- Claude Code installed and configured
- Moira server access (cloud or self-hosted)
- Valid Moira account credentials
Configuration
Section titled “Configuration”Open Claude Code settings
In VS Code, open Command Palette and run:
Claude Code: Open SettingsOr edit directly:
Directory~/.claude/
- settings.json
Add Moira MCP server
Add to your
settings.jsonwith URL:https://moiraqq.com/mcpRestart Claude Code
Reload the window or restart VS Code to apply changes.
Authenticate
When first using Moira tools, you’ll be prompted to authenticate. Follow the OAuth flow in your browser.
Verify Connection
Section titled “Verify Connection”Test the connection by asking Claude:
List available Moira workflowsYou should see your workflows listed.
Using Moira in Claude Code
Section titled “Using Moira in Claude Code”Starting a Workflow
Section titled “Starting a Workflow”Start the "development-flow" workflow in MoiraClaude will:
- Call
start_workflowwith the workflow ID - Receive the first step directive
- Execute the directive
- Submit results via
execute_step - Continue until workflow completes
Continuing a Session
Section titled “Continuing a Session”If a session was interrupted, continue with:
Continue my Moira workflow with process ID abc-123Getting Help
Section titled “Getting Help”Show Moira documentation for nodesClaude will call get_help with the topic.
CLAUDE.md Integration
Section titled “CLAUDE.md Integration”For project-specific workflows, add to your CLAUDE.md:
## Moira Workflows
This project uses Moira for development workflows.
### Available Workflows
- `dev-flow` - Main development workflow- `review-flow` - Code review workflow
### Starting Development
To start a task, run the development workflow:
1. Start `dev-flow` workflow2. Follow each step directive3. Submit results before moving to next stepAvailable Tools
Section titled “Available Tools”Once connected, these tools are available:
| Tool | Description |
|---|---|
list_workflows | List available workflows |
start_workflow | Start a workflow, returns first directive |
execute_step | Submit result, get next directive |
get_help | Get documentation |
manage_settings | User settings management |
get_session_info | Session and execution info |
Troubleshooting
Section titled “Troubleshooting”Connection Issues
Section titled “Connection Issues”- Verify MCP server URL is correct
- Check network connectivity
- Ensure authentication is valid
- Check Claude Code logs for errors
Workflow Not Starting
Section titled “Workflow Not Starting”- Verify workflow ID exists:
list_workflows - Check workflow visibility permissions
- Ensure you have access to the workflow
Session Lost
Section titled “Session Lost”If process ID is lost:
- Check
get_session_infofor active executions - Resume with the correct process ID
- Consider adding process ID to CLAUDE.md for persistence
Best Practices
Section titled “Best Practices”- Save Process IDs - Store in CLAUDE.md for session continuity
- Follow Directives - Execute exactly what the directive says
- Meet Completion Conditions - Verify before submitting
- Check Help - Use
get_helpwhen unsure
Related
Section titled “Related”- Quick Start - General setup guide
- MCP Clients - Other client integrations