Back to Browse

Citadel MCP Server

Developer ToolsModerate5.8MCP RegistryLocal
Free

Server data from the Official MCP Registry

A growing Citadel of stack-specific docs, served as MCP tools for AI coding agents.

About

A growing Citadel of stack-specific docs, served as MCP tools for AI coding agents.

Security Report

5.8
Moderate5.8Moderate Risk

Citadel MCP is a well-structured documentation server with proper authentication boundaries and safe code execution patterns. The server uses a sandboxed Node.js executor to run user-supplied code in an isolated context with controlled SDK access, mitigating injection risks. Permissions align with its purpose as a developer tool that fetches and indexes remote documentation. Minor findings around input validation and error handling are present but do not materially impact security. Supply chain analysis found 2 known vulnerabilities in dependencies (0 critical, 2 high severity). Package verification found 1 issue.

6 files analyzed · 8 issues found

Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.

Permissions Required

This plugin requests these system permissions. Most are normal for its category.

HTTP Network Access

Connects to external APIs or services over the internet.

env_vars

Check that this permission is expected for this type of plugin.

file_system

Check that this permission is expected for this type of plugin.

How to Install

Add this to your MCP configuration file:

{
  "mcpServers": {
    "io-github-sustinbebustin-citadel-mcp": {
      "args": [
        "-y",
        "citadel-mcp"
      ],
      "command": "npx"
    }
  }
}

Documentation

View on GitHub

From the project's GitHub README.

Citadel MCP

npm citadel-mcp package

A Code Mode MCP server that gives AI coding agents curated, per-stack documentation as typed tools.

Citadel is built to be forked and tailored. The hosted package ships with a small starter set of stacks, but the real value comes from packaging the docs your agents actually need. Each stack is a tiny module — adding one is mostly mechanical.

Getting Started

Requirements

Install with add-mcp

Install the MCP server for all your coding agents:

npx add-mcp citadel-mcp@latest

Add -y to skip the confirmation prompt and install to all detected agents already in use in the project directory. Add -g to install globally across all projects.

Manual installation

Add the following config to your MCP client:

{
  "mcpServers": {
    "citadel": {
      "command": "npx",
      "args": ["-y", "citadel-mcp@latest"]
    }
  }
}

[!NOTE] Using citadel-mcp@latest ensures that your MCP client will always use the latest version of the Citadel MCP server.

MCP Client Configuration

Using Amp CLI:

amp mcp add citadel -- npx citadel-mcp@latest

Or configure manually:

Follow Amp's MCP documentation and apply the standard configuration shown above.

Use the Claude Code CLI to add the Citadel MCP server:

claude mcp add -s user citadel -- npx -y citadel-mcp@latest

Use -s project instead of -s user to scope the install to the current project. Restart Claude Code, then verify with claude mcp list. A working server advertises a single tool named docs.

Using Codex CLI:

codex mcp add citadel -- npx citadel-mcp@latest

Or configure manually:

Follow the MCP setup guide with the standard configuration format:

  • Command: npx
  • Arguments: -y, citadel-mcp@latest

Go to Cursor Settings -> MCP -> New MCP Server. Use the JSON config provided above.

Using Gemini CLI:

Project-wide installation:

gemini mcp add citadel npx citadel-mcp@latest

Global installation:

gemini mcp add -s user citadel npx citadel-mcp@latest

Using VS Code CLI:

code --add-mcp '{"name":"citadel","command":"npx","args":["-y","citadel-mcp@latest"]}'

Or configure manually:

Follow the official VS Code MCP server setup guide and add the Citadel server through VS Code settings.

Navigate to Settings | AI | Manage MCP Servers and select + Add to register a new MCP server with the following configuration:

  • Name: citadel
  • Command: npx
  • Arguments: -y, citadel-mcp@latest

What you get out of the box

The hosted package includes a starter set of stacks so you can try it immediately:

  • Next.js (App Router, Next.js 16)
  • React
  • Turborepo
  • Supabase guides

This list is intentionally small. For the best results, fork this repo and add the stacks your agents care about — your internal libraries, the framework version you actually use, or any docs site that publishes machine-readable markdown. See docs/adding-a-docs-tool.md.

How it works

Citadel is a Code Mode server: instead of advertising one tool per docs source, it advertises a single docs tool. The agent writes one async () => { ... } per turn that calls codemode.<stack>_docs(...) and codemode.<stack>_index() directly, and the server runs that code in a local Node sandbox. N doc fetches collapse into one round-trip.

Each stack contributes two callable tools to the sandbox SDK:

  • <stack>_index() — returns the doc index so the agent can pick a valid path
  • <stack>_docs({ path }) — fetches that specific doc as markdown

Citadel also exposes a cross-stack ranked search: codemode.docs_search({ query, stacks?, fetch: true }) returns BM25-ranked matches with markdown content attached in a single call.

Documentation

  • Using Citadel as an AI agent — playbook for the docs tool, served at runtime as MCP resource citadel://docs/agent-usage. SDK reference, parallel fan-out, error handling, worked examples.
  • Adding a docs tool — package a new stack as <stack>_index + <stack>_docs.

Local Development

To run the MCP server locally for development:

  1. Clone the repository.

  2. Install and build:

    pnpm install
    pnpm build
    
  3. Configure your MCP client to use the local version:

    {
      "mcpServers": {
        "citadel-dev": {
          "command": "node",
          "args": ["/absolute/path/to/citadel-mcp/dist/index.js"]
        }
      }
    }
    

    Or with the Claude Code CLI:

    claude mcp add -s user citadel-dev -- node /absolute/path/to/citadel-mcp/dist/index.js
    

For development with auto-reload, point the MCP client at tsx and the src entry instead:

claude mcp add -s user citadel-dev -- npx tsx /absolute/path/to/citadel-mcp/src/index.ts

License

MIT

Reviews

No reviews yet

Be the first to review this server!