Metadata-Version: 2.4
Name: sphinx-autodoc-fastmcp
Version: 0.0.1a7
Summary: Sphinx extension for documenting FastMCP tools (cards, badges, cross-refs)
Project-URL: Repository, https://github.com/git-pull/gp-sphinx
Author-email: Tony Narlock <tony@git-pull.com>
License: MIT
Keywords: badges,documentation,fastmcp,mcp,sphinx
Classifier: Development Status :: 3 - Alpha
Classifier: Framework :: Sphinx
Classifier: Framework :: Sphinx :: Extension
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Documentation
Classifier: Topic :: Documentation :: Sphinx
Classifier: Typing :: Typed
Requires-Python: <4.0,>=3.10
Requires-Dist: sphinx
Requires-Dist: sphinx-autodoc-badges==0.0.1a7
Description-Content-Type: text/markdown

# sphinx-autodoc-fastmcp

Sphinx extension that documents **FastMCP** tools with card-style `desc` layouts (aligned with `sphinx-autodoc-api-style`), safety badges, parameter tables, and cross-reference roles.

## Features

- **`fastmcp-tool`**: Renders a tool entry as an `mcp` domain `desc` (definition list card) plus a section for ToC and `{ref}` labels.
- **`fastmcp-tool-input`**: Parameter table for a tool (place after prose in MyST).
- **`fastmcp-toolsummary`**: Summary tables grouped by safety tier.
- **Roles**: `:tool:`, `:toolref:`, `:toolicon` / `:tooliconl` / `:tooliconr` / `:tooliconil` / `:tooliconir:`, `:badge:`

## Configuration

In `conf.py` after `sphinx_autodoc_fastmcp` is listed in `extensions`:

```python
fastmcp_tool_modules = [
    "myproject.tools.server_tools",
    "myproject.tools.session_tools",
]
fastmcp_area_map = {
    "server_tools": "sessions",
    "session_tools": "sessions",
}
fastmcp_model_module = "myproject.models"
fastmcp_model_classes = {"SessionInfo", "WindowInfo"}
fastmcp_section_badge_map = {"Inspect": "readonly", "Act": "mutating", "Destroy": "destructive"}
fastmcp_section_badge_pages = {"tools/index", "index"}
fastmcp_collector_mode = "register"  # or "introspect"
```

See the package docstrings and `sphinx_autodoc_fastmcp.setup()` for defaults.

## Dependencies

- Python 3.10+
- Sphinx

## License

MIT
