Skip to content
docsMCP tools

get started

MCP tools

What muxd mcp exposes to your agent. You never call these yourself, but knowing them helps you write better instructions.

muxd mcp speaks the Model Context Protocol over stdio. Clients start it through the configs written by muxd init or muxd install-client. It serves your global sources plus the current project's, ranked first.

search_docs

Search every indexed source. Agents are told to call it before writing code that uses a library.

ParameterTypeDescription
querystringKeywords, API names or a short question, e.g. create client auth.
sourcestring?Restrict the search to one source slug.
limitinteger?Maximum results, 1 to 25. Default 8.

get_doc

Read the full content of one section returned by search_docs or list_sections.

ParameterTypeDescription
sourcestringSource slug.
idstringSection id, or its exact title.
offsetinteger?Character offset, to page through long sections.

list_sources

List the indexed libraries. The current project's sources come first; thin ones (README only, very short) are marked so the agent knows to be careful.

list_sections

The table of contents of one source: section ids and titles.

ParameterTypeDescription
sourcestringSource slug.

save_doc

Write a curated Markdown reference into muxd after researching a library whose docs were missing or thin. Only verified facts, for the version in use, with sources cited.

ParameterTypeDescription
sourcestringExisting slug, or a new one for a library muxd doesn't have yet.
contentstringMarkdown, with ## headings per topic so sections are searchable.
titlestring?Heading for this block, e.g. Auth setup (v5).
modeappend | replaceAppend to existing notes (default), or rewrite them.

The improve_docs prompt

An MCP prompt, available in clients that support prompts (as a slash command in Claude Code). Give it a package name and the agent researches the library from official docs or source code, then saves a version-accurate reference with save_doc. Use it on the libraries marked thin in list_sources.

Instructions for your agents

muxd init adds this block to AGENTS.md / CLAUDE.md, between <!-- muxd:start --> and <!-- muxd:end --> markers so later runs can update it:

AGENTS.md
## Library documentation (muxd) Docs for this project's dependencies are indexed locally by muxd and exposedthrough the `muxd` MCP server. Before writing or changing code that uses athird-party library, call `search_docs` (then `get_doc` for the full section)instead of relying on memory: these docs match the versions this project uses.