Cargo doc

Provides tools to check, build, and search Rust documentation locally via cargo doc commands.
  • typescript

10

GitHub Stars

typescript

Language

6 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "spacemeowx2-cargo-doc-mcp": {
      "command": "/absolute/path/to/docs-rs-mcp/build/index.js",
      "args": []
    }
  }
}

You can run a dedicated MCP server to manage Rust documentation locally with cargo doc commands. This server helps you check, build, and search crate documentation efficiently from your development environment, streamlining quick lookups and offline access.

How to use

Configure a client to communicate with the MCP server over stdio. You run a local MCP process and connect your tooling to its standard input and output. Use the explicit server configuration below to start the MCP and then connect your tooling using the provided interface.

How to install

Prerequisites: you need Node.js 16 or later and Rust with Cargo installed.

Install dependencies for the MCP server package manager.

pnpm install

Build the MCP server to generate the runtime artifacts.

pnpm run build

For development with automatic rebuilds on changes, start the watch mode.

pnpm run watch

Add the MCP server configuration to your client configuration. Use the provided example to expose the server over stdio.

{
  "mcpServers": {
    "docs_rs_mcp": {
      "command": "/absolute/path/to/docs-rs-mcp/build/index.js"
    }
  }
}

Additional notes

Debugging MCP servers can be challenging since communication happens over stdio. You can use the MCP Inspector to access debugging tools in your browser.

pnpm run inspector

The server uses a cache to speed up repeated access to built documentation. Cache entries expire after 24 hours to keep documentation up to date.

Available tools

get_crate_doc

Get crate's main documentation page for understanding overall concepts and usage.

list_symbols

List all symbols (structs, enums, traits, etc.) in a crate's documentation.

search_doc

Search within a crate's documentation by a query, with an optional limit on results.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational