Skip to main content
Glama
WROLPi MCP Server

WROLPi MCP Server

Official
by wrolpi

WROLPi MCP Server

An MCP server that lets an LLM (Claude Desktop, Claude Code, or any MCP client) search and read the contents of your WROLPi: videos and their captions, archived web pages, ebooks and documents, Zim encyclopedias, maps, tags, inventories, and the download queue.

Every tool only reads, except upgrade_wrolpi, which your MCP client asks you to approve. The server runs on your computer, not on the WROLPi, and talks to the WROLPi's normal HTTP API over your network. Every result carries a link back into the WROLPi web app.

Requirements

  • A WROLPi reachable from this computer (for example https://wrolpi.local:8443).

  • uv (recommended) or Python 3.11+ with pipx.

Related MCP server: ZIM MCP Server

Install

Install it as a persistent command. A WROLPi is meant to work offline, and this is the install that starts without the Internet:

uv tool install git+https://github.com/wrolpi/mcp
# or
pipx install git+https://github.com/wrolpi/mcp

To update later:

uv tool upgrade wrolpi-mcp
# or
pipx upgrade wrolpi-mcp

then restart the MCP client (or toggle the server off and on) so it relaunches the new version.

You can also run it without installing, straight from this repository:

uvx --from git+https://github.com/wrolpi/mcp wrolpi-mcp

Avoid this form in a client config: uvx asks GitHub which commit is current on every launch, so the server fails to start whenever the Internet is down (even with uv --offline). Pinning a tag does not help; only a full commit hash (git+https://github.com/wrolpi/mcp@<40-char sha>) starts offline.

Configure

The server reads these environment variables:

Variable

Default

Meaning

WROLPI_API_URL

https://localhost:8443

The WROLPi's address, exactly as you type it in a browser.

WROLPI_VERIFY_TLS

false

Verify the TLS certificate. WROLPi uses a self-signed one by default.

WROLPI_TIMEOUT

300

Seconds to wait for a response. Deep searches and searching every Zim at once can take minutes on a Raspberry Pi.

Claude Code

claude mcp add wrolpi -e WROLPI_API_URL=https://wrolpi.local:8443 -- wrolpi-mcp

Claude Desktop

Add to claude_desktop_config.json (Settings > Developer > Edit Config):

{
  "mcpServers": {
    "wrolpi": {
      "command": "wrolpi-mcp",
      "env": {"WROLPI_API_URL": "https://wrolpi.local:8443"}
    }
  }
}

Claude Desktop may not see your shell's PATH; if the server does not start, use the full path to wrolpi-mcp (which wrolpi-mcp).

LM Studio

LM Studio 0.3.17 or newer can run MCP servers. Open a chat, switch to the Program tab in the right-hand sidebar, click Install > Edit mcp.json, and add the wrolpi entry (the file is ~/.lmstudio/mcp.json, or %USERPROFILE%\.lmstudio\mcp.json on Windows):

{
  "mcpServers": {
    "wrolpi": {
      "command": "wrolpi-mcp",
      "env": {"WROLPI_API_URL": "https://wrolpi.local:8443"}
    }
  }
}

Save the file, then turn the wrolpi server on in the Program tab for the chat. The first tool call opens a confirmation dialog where you can allow it once or always.

Notes:

  • Use a model that supports tool calling (LM Studio marks them with a tool icon). Small models can emit tool calls but get unreliable as the tool list grows.

  • LM Studio is a GUI app and may not see the PATH of your shell. If the server fails to start with a "command not found" error, put the full path to wrolpi-mcp in command (which wrolpi-mcp on macOS/Linux, where wrolpi-mcp on Windows).

Tools

Tool

What it does

search_files

Search videos, archived pages and documents in one call. Filter by kind, channel, domain, author, subject, or tags. deep=true also searches captions and page text.

get_file

Details of one item by its ID.

read_content

A video's captions or comments, or an archived page's text.

search_zim, get_zim_entry, list_zim_files

Search and read Zim encyclopedias (Wikipedia, Wiktionary, ...).

list_collections

Video channels, archived domains, and playlists.

list_tags

Every tag with its usage counts.

list_files, read_file

Browse the media directory and read plain-text files.

list_downloads

The download queue: what is scheduled, running, or failed.

get_map_overview, search_places

Downloaded map regions, pins, and place search.

get_inventory

Inventories (food storage, supplies) and their items.

get_statistics, get_status

Library statistics and system status.

upgrade_wrolpi, get_upgrade_status

Upgrade the WROLPi to a git branch (release, master, ...) and follow the upgrade's log. Not for Docker.

get_database_schema, query_database

Read-only SQL against the WROLPi's database. Off unless enabled on the WROLPi (below).

Upgrades

upgrade_wrolpi asks the WROLPi's Controller to upgrade to the newest code of a branch, exactly like Upgrade on the Controller page. Omit the branch to upgrade the branch the WROLPi already runs. The upgrade takes several minutes and restarts every WROLPi service, so the other tools fail meanwhile; get_upgrade_status reports progress from the Controller, which stays up. A WROLPi running in Docker cannot upgrade itself.

Database queries (advanced)

query_database runs read-only SQL (SQLite) against the WROLPi's database, for questions the other tools cannot answer ("which channels have the most unwatched videos?"). The WROLPi refuses these until you opt in, because WROLPi's API has no login: anyone who can reach the WROLPi could read the whole database, including viewing history. There is no switch for it in Settings. To enable it, add this to config/wrolpi.yaml in the media directory:

allow_database_query: true

then click Import for wrolpi.yaml on the WROLPi's Configs page (or restart the WROLPi). To turn it off again, set it to false and import again; deleting the line has no effect until the WROLPi restarts.

Queries cannot change anything: the WROLPi opens the database read-only and refuses any statement other than a read. Each query is stopped after 10 seconds, returns at most 1000 rows to the model, and long text values are cut short.

Troubleshooting

Every tool fails, or a search fails and then everything after it does. The usual cause is one slow request. A deep=True search or a search across every Zim can take minutes on a Raspberry Pi; if the server gives up first, the WROLPi keeps working on the abandoned request and the next calls queue behind it. Since 0.1.1 the model is told exactly this (and how to retry) instead of a bare "Error executing tool". If it still happens, raise WROLPI_TIMEOUT, or ask for title-only searches.

The model never sees an error message, only "Error executing tool". Upgrade the server: that is how versions before 0.1.1 reported a timeout. uv tool upgrade wrolpi-mcp (or pipx upgrade wrolpi-mcp), then restart the client. If your config runs uvx --from git+..., clear its cache instead so it fetches the latest: uv cache clean wrolpi-mcp.

The server will not start while the Internet is down. Your config runs it through uvx --from git+https://github.com/wrolpi/mcp, which must contact GitHub on every launch. Switch to the persistent install above and set "command": "wrolpi-mcp".

"Could not reach the WROLPi". WROLPI_API_URL must be the address you type in a browser, including https:// and the port (https://wrolpi.local:8443). The server's log goes to the MCP client's log (LM Studio: Developer > Logs; Claude Desktop: ~/Library/Logs/Claude/mcp*.log).

Development

git clone https://github.com/wrolpi/mcp wrolpi-mcp
cd wrolpi-mcp
uv sync
uv run pytest
# Try the tools interactively in the MCP Inspector:
WROLPI_API_URL=https://wrolpi.local:8443 uv run mcp dev wrolpi_mcp/server.py

tests/test_live.py runs every tool against a real WROLPi when WROLPI_LIVE_URL is set:

WROLPI_LIVE_URL=https://wrolpi.local:8443 uv run pytest tests/test_live.py

License

GPLv3, the same as WROLPi.

Available Tools

16 tools
get_fileA
Read-only

Get details about one item of any kind (video, archived page, document) by its ID from search results.

Args: file_group_id: The ID from search results. kind: "video", "archive", or "doc" if known (skips guessing).

NameRequiredDescriptionDefault
kindNo
file_group_idYes

Output Schema

NameRequiredDescription
resultYes
get_inventoryA
Read-only

List the inventories (emergency supplies, food storage, etc.), or read one in full.

Args: inventory_slug: The slug of one inventory to read with every item; omit to list them all.

NameRequiredDescriptionDefault
inventory_slugNo

Output Schema

NameRequiredDescription
resultYes
get_map_overviewA
Read-only

Describe the maps on this WROLPi: downloaded map regions, whether each has a place-search index, subscribed regions, and the user's saved pins (with links).

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription
resultYes
get_statisticsA
Read-only

Get an overview of what content is stored in the WROLPi library.

Returns counts and sizes for videos, archives, ebooks, Zim files, and other content.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription
resultYes
get_statusA
Read-only

Get WROLPi system status (version, mode, download summary, CPU, memory, disks, flags).

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription
resultYes
get_zim_entryA
Read-only

Read a specific article/entry from a Zim file (e.g. a Wikipedia article) as plain text.

Use search_zim first to find entry paths.

Args: zim_id: ID of the Zim file. entry_path: Path to the entry within the Zim file (from search results). offset: Character offset to continue reading from.

NameRequiredDescriptionDefault
offsetNo
zim_idYes
entry_pathYes

Output Schema

NameRequiredDescription
resultYes
list_collectionsB
Read-only

List collections (video channels, archived domains, playlists, document authors and subjects) in the library, paged.

Args: kind: Filter by collection kind: "channel", "domain", "playlist", "author", "subject", or None for all. query: Match collection names containing this text. limit: Maximum results. offset: Pagination offset (from a previous listing's "next offset").

NameRequiredDescriptionDefault
kindNo
limitNo
queryNo
offsetNo

Output Schema

NameRequiredDescription
resultYes
list_downloadsA
Read-only

Read the WROLPi download queue: summary, recurring downloads (channels, feeds), and one-time downloads.

Use this when the user asks what is downloading, what failed and why, or what is scheduled. Downloads cannot be started, stopped, or retried from here.

Args: status: Only show downloads with this status: new, pending, failed, deferred, or complete. limit: Maximum recurring and one-time downloads to show (each).

NameRequiredDescriptionDefault
limitNo
statusNo

Output Schema

NameRequiredDescription
resultYes
list_filesA
Read-only

List the directories and files inside one directory of the WROLPi media directory.

Use this to explore how the library is organized on disk (e.g. "videos/", "archive/", a channel's directory). Directories are listed first, then files. Every entry's relative path can be passed back to list_files to descend. Large directories are paged; call again with the returned offset.

Args: path: Directory relative to the media directory (e.g. "videos/SomeChannel"). Empty for the top level. offset: Number of entries to skip (from a previous listing's "next offset").

NameRequiredDescriptionDefault
pathNo
offsetNo

Output Schema

NameRequiredDescription
resultYes
list_tagsA
Read-only

List every tag in the library with how many files, Zim entries, channels, and domains carry it.

Tag names can be passed as tag_names to the search tools. Users tag what they care about, so this is a good map of their interests. Also returns the most recently used tag names.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription
resultYes
list_zim_filesA
Read-only

List all available Zim encyclopedias (Wikipedia, Wiktionary, etc.).

Returns Zim IDs needed for search_zim and get_zim_entry.

NameRequiredDescriptionDefault

No parameters

Output Schema

NameRequiredDescription
resultYes
read_contentA
Read-only

Read what an item says: a video's captions or an archived page's text (part="text"), or a video's comments (part="comments"). Long content is returned in windows; continue with the offset the result gives you.

Args: file_group_id: The ID from search results. part: "text" (default) or "comments". offset: Character offset to continue reading from.

NameRequiredDescriptionDefault
partNotext
offsetNo
file_group_idYes

Output Schema

NameRequiredDescription
resultYes
read_fileA
Read-only

Read a plain-text file from the media directory by its relative path (from list_files).

Args: path: File path relative to the media directory, e.g. "notes/todo.txt". Text files only. offset: Character offset to continue reading from.

NameRequiredDescriptionDefault
pathYes
offsetNo

Output Schema

NameRequiredDescription
resultYes
search_filesA
Read-only

Search the whole library (videos, archived web pages, documents/ebooks) in one call.

Args: query: Text to search for in titles (and, with deep=True, captions/page text). Omit to browse the newest items. kind: Narrow to "video", "archive", or "doc". channel: A video channel name (or id); implies kind=video. domain: An archived site's domain, e.g. "example.com"; implies kind=archive. author: Document author (partial match); implies kind=doc. subject: Document subject (partial match); implies kind=doc. tag_names: Only items with these tags. limit: Maximum results (at most 100). offset: Pagination offset. deep: Also search inside captions, page text and descriptions. Slower on a Raspberry Pi; use it when a title search finds nothing.

NameRequiredDescriptionDefault
deepNo
kindNo
limitNo
queryNo
authorNo
domainNo
offsetNo
channelNo
subjectNo
tag_namesNo

Output Schema

NameRequiredDescription
resultYes
search_placesB
Read-only

Find towns, cities, and landmarks by name in the downloaded maps. Each result links to the WROLPi map.

Args: query: Place name (prefix match), e.g. "Portland". limit: Maximum results. offset: Pagination offset. lat: Latitude to rank nearby places first. lon: Longitude to rank nearby places first.

NameRequiredDescriptionDefault
latNo
lonNo
limitNo
queryYes
offsetNo

Output Schema

NameRequiredDescription
resultYes
search_zimA
Read-only

Search the Zim encyclopedias (Wikipedia, Wiktionary, etc.).

Without zim_id this searches the Zims that have "search by default" enabled; pass a zim_id (from list_zim_files) to search one specific Zim. Read a result with get_zim_entry.

Args: query: Text to search for. zim_id: ID of one Zim file to search; omit to search the default Zims. limit: Maximum results (per Zim when searching several). offset: Pagination offset.

NameRequiredDescriptionDefault
limitNo
queryYes
offsetNo
zim_idNo

Output Schema

NameRequiredDescription
resultYes

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 16 tool updatesv0.1.0
    • First observedget_file
    • First observedget_inventory
    • First observedget_map_overview
    • First observedget_statistics
    • First observedget_status
    • First observedget_zim_entry
    • First observedlist_collections
    • First observedlist_downloads
    • First observedlist_files
    • First observedlist_tags
    • First observedlist_zim_files
    • First observedread_content
    • First observedread_file
    • First observedsearch_files
    • First observedsearch_places
    • First observedsearch_zim

TDQS

A3.9/5.0

Scored across 16 tools

Disambiguation4/5

Each tool maps to a distinct resource (library files, Zim encyclopedias, maps, downloads, inventory, system), and descriptions consistently distinguish them. Minor overlap exists between get_file/read_file/read_content (all touch library items) and between read_content and get_zim_entry, but the sources and purposes are clearly stated.

Naming Consistency5/5

Every tool follows a consistent snake_case verb_noun pattern (get_*, list_*, search_*, read_*), with no camelCase or style mixing. The verbs accurately reflect the actions and are used uniformly across the set.

Tool Count4/5

16 tools is on the heavier side but each covers a genuinely different part of the WROLPi domain (library, Zim, maps, downloads, status), so none feel redundant. It sits at the upper end of the comfortable range but remains well-scoped.

Completeness4/5

The set covers a coherent read/browse lifecycle: search, item details, content reading, collections, tags, downloads queue, maps, inventory, statistics, and system status. Gaps are mostly deliberate (downloads explicitly cannot be started/stopped/retried, no write operations), so agents rarely hit dead ends for query tasks.

Maintenance

ActivityMaintained
ResponsivenessOutdated data

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    A
    maintenance
    Enables AI models to access and search offline Wikipedia and other knowledge bases stored in ZIM format files. Provides intelligent content retrieval, structured browsing, advanced search capabilities, and metadata extraction for comprehensive offline knowledge access.
    8
    356 PyPI
    149
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables large language models to directly access and search content in ZIM files, allowing offline question answering and information retrieval from resources like Wikipedia.
    22
    MIT
  • A
    license
    Not graded
    quality
    A
    maintenance
    Enables AI agents to search, read, and manage offline knowledge from ZIM files (Kiwix archives) with full-text search, language support, and library management.
    95
    GPL 3.0
  • A
    license
    A
    quality
    C
    maintenance
    Enables AI assistants to search, browse, and cite a local Zotero 7 library with zero configuration and no API key, keeping all data on the user's machine.
    8
    MIT