grimmory-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
grimmory-mcp
A small MCP server for Grimmory, the self-hosted ebook, comic and audiobook library. It lets an AI assistant such as Claude Code search your library and tidy metadata, tags, genres and shelves.
Built and tested against Grimmory v3.5.0. Grimmory marks its API as unstable, so check it again after you upgrade.
Tools
Tool | Kind | What it does |
| read | Free-text search plus facet filters ( |
| read | Lists the authors, genres, tags, series, publishers and shelves already in use, so new values match existing ones |
| read | One book's metadata, shelves and locked fields |
| read | Regular shelves visible to the user |
| write | Changes chosen fields on one book and returns before/after values |
| write | Tags, genres, moods, authors, series, publisher or language on up to 100 books; shows a preview first, writes only on |
| write | Creates a shelf; refuses duplicate names |
| write | Adds books to shelves or removes them |
Related MCP server: Calibre MCP Server
Safety by design
These rules are enforced in code, not in a prompt:
No delete tools. Nothing can delete books, files, shelves, users or metadata values.
Locks are respected. A field locked in Grimmory is refused, never overwritten. No tool can change locks.
No accidental wipes. Grimmory's metadata endpoint defaults to
replaceMode=REPLACE_ALL, which clears every field you don't send. This server always sendsREPLACE_WHEN_PROVIDED.Bulk edits are two-step. The first call returns a per-book preview. Nothing is written until the same call is repeated with
confirm=True.Nothing is cleared. Empty values are refused. Remove the last tag from a book in the Grimmory UI.
Use a dedicated Grimmory user for the assistant. The server is the only thing between the assistant and whatever that user is allowed to do.
Install
Requires Python 3.12+ and uv.
git clone https://github.com/jensopt/grimmory-mcp
cd grimmory-mcp
uv sync --frozenConfiguration (environment variables)
Variable | Required | Meaning |
| yes | Base URL, e.g. |
| yes | Grimmory username (not email; Grimmory logs in by username) |
| yes | Its password |
| no | Only if Grimmory sits behind Pangolin, see below |
| no | Second half of the same token |
Claude Code
claude mcp add grimmory -s user \
-e GRIMMORY_URL=https://books.example.com \
-e GRIMMORY_USERNAME=assistant -e GRIMMORY_PASSWORD=... \
-- uv run --quiet --frozen --project /path/to/grimmory-mcp grimmory-mcpRestart Claude Code afterwards, because MCP servers only load at startup.
Behind Pangolin
Pangolin's header authentication won't work for this server. It is HTTP Basic auth in the Authorization header, and Grimmory needs that same header for its Bearer token. A request can only carry one.
Use a shareable link (access token) on the Grimmory resource instead. Pangolin shows it as ?p_token=<id>.<token>. Put the part before the dot in PANGOLIN_TOKEN_ID and the part after it in PANGOLIN_TOKEN. The server sends them as P-Access-Token-Id / P-Access-Token headers, which leaves Authorization free for Grimmory.
Notes
Access tokens last 2 hours. On v3.5.0,
/api/v1/auth/refreshreturned 401 in testing, so the server logs in again when the token expires.Grimmory calls genres
categorieson a single book andgenresin bulk edits. The tools use the API's names.To see the full API, set
API_DOCS_ENABLED=trueon your instance and read/api/openapi.json.Uses the
mcpPython SDK 2.x (MCPServer, formerlyFastMCP).
License
MIT
Related MCP Connectors
Read-only access to Penwright's writing-craft book library, grounded guide metadata (card-level...
The media memory layer for AI agents and their humans. Your AI client can search your collection, add and log what you've finished, update ratings and lists, and find patterns across everything you've read, watched, played, and listened to.
Academic literature search, retrieval, and private library management on top of OpenAlex.
Manage your Readlink book library: add books, track reading, rate, notes, highlights, shelves.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables read-only access to local Calibre libraries for searching metadata, inspecting book formats, and extracting content samples. Supports full-text search, batch operations, and detailed book analysis through natural language queries.3MIT
- AlicenseBqualityCmaintenanceConnects AI agents to Calibre ebook libraries for searching, reading, and managing digital collections. It supports metadata updates, format conversion, and full-text content searches while providing granular permission controls for library access.723MIT
- AlicenseNot gradedqualityDmaintenanceEnables searching, reading, and managing a Calibre ebook library through natural language, with features like metadata search, full-text search, content extraction, and library management.729 npmApache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables read-only search, browsing, and metadata retrieval from a local Calibre e-book library using natural language queries.MIT