AgentRoot
Navigate

// install_claude_code

Using AgentRoot with Claude Code

Search the AgentRoot registry and install MCP servers and skills directly into Claude Code. Skills are automatically loaded based on trigger keywords, and MCP servers are added to your Claude configuration.

// what_you_need

  • Claude Code installed and running
  • Node.js 18+ (for npx commands)
  • A project directory (for project-scoped installs)

1Search the registry

Find MCP servers, skills, agents, and A2A endpoints in the AgentRoot registry:

# Search for MCP servers $ npx agent-root search "database" --type mcp dbtools.io/postgres-mcp mcp Postgres MCP Server transport: sse | tools: query, describe-table, list-tables sqlcraft.dev/sqlite-mcp mcp SQLite MCP Server transport: stdio | tools: query, schema, export
# Search for skills $ npx agent-root search "react" --type skill devkit.tools/react-patterns skill React Best Practices skills: component-architecture, testing-strategy
# Search all types at once $ npx agent-root search "kubernetes"

2Install a record

Use the --tool claude flag to install records into Claude Code:

Installing an MCP server:

$ npx -p @agent-root/cli agent-root install dbtools.io/postgres-mcp --tool claude # The CLI prints the JSON snippet to paste into # your project .claude/mcp.json (or ~/.claude/mcp.json): { "mcpServers": { "postgres-mcp": { "command": "npx", "args": ["@dbtools/postgres-mcp", "--connection", "$POSTGRES_URL"] } } }

Install never mutates Claude Code's settings files automatically. Copy the printed snippet into the right mcp.json yourself, then restart Claude Code.

Installing skills:

$ npx -p @agent-root/cli agent-root install devkit.tools/react-patterns --tool claude # Writes skill files into Claude's skills dir: # ~/.claude/skills/devkit.tools/react-patterns/SKILL.md # (plus any referenced supporting files)

3Verify it works

For MCP servers, restart Claude Code and check that the tools are available:

$ claude /mcp # Should list postgres-mcp with its tools

For skills, Claude automatically loads relevant skills based on trigger keywords in your prompts. Ask Claude about the topic the skill covers and it will reference the skill content:

# The skill triggers on keywords like "react component", "component structure" $ claude "Help me build a React component for a data table" # Claude loads the component-architecture skill automatically

4Project-scoped vs global installs

By default, skills install globally. Pass --project to install into the current directory instead:

# Global install (default) — available in all projects $ npx -p @agent-root/cli agent-root install devkit.tools/react-patterns --tool claude # Installs to: ~/.claude/skills/ # Project-scoped — only available in this project $ npx -p @agent-root/cli agent-root install devkit.tools/react-patterns --tool claude --project # Installs to: .claude/skills/

Project-scoped skills live in .claude/skills/ in your project root and can be committed to version control so the whole team benefits.

Skill auto-invocation works through the trigger keywords defined in each skill's frontmatter. When your prompt matches a trigger, Claude loads that skill as context. You can also reference skills explicitly using their path.

// troubleshooting

  • MCP server not showing up: The CLI prints a JSON snippet on install but does not write it for you. Paste it into .claude/mcp.json (project) or ~/.claude/mcp.json (global), then restart Claude Code.
  • Skills not loading: Verify files exist at ~/.claude/skills/<domain>/<record-id>/ or .claude/skills/<domain>/<record-id>/. Check that trigger keywords in the SKILL.md frontmatter match your prompts.
  • Permission errors: Ensure the target skills directory is writable. Exit code 77 (NOPERM) means the CLI could not write to ~/.agents/ or the symlink target.
  • Outdated skills: Run agent-root update <domain>/<record-id> to re-fetch from the publisher.

// next_steps