bookstack_content_crudLABSCO SUMMARY
The image gallery is the part most BookStack integrations skip, and it is the part this one is built around.
Uploading an image by URL is where authoring usually breaks down, so the tool streams the remote file under a size and time limit and refuses to fetch anything on a private or loopback address. The rest of the surface is deliberately consolidated — one CRUD tool across four entity types rather than sixteen near-identical ones.
What it is
A FastMCP server for a BookStack wiki. It consolidates the API into a handful of tools covering books, shelves, chapters and pages, full-text search, batch edits, and the image gallery that authoring depends on.
What you get
- bookstack_content_crud — one interface for creating, reading, updating and deleting books, bookshelves, chapters and pages
- bookstack_list_content — list and filter content entities with pagination
- bookstack_search — full-text search across the instance
- bookstack_batch_operations — bulk create, update and delete
- bookstack_manage_images — create, read, update, delete and list gallery images; accepts base64, a data URL, or an HTTP(S) URL it fetches for you
- bookstack_search_images — find images by extension, date, size and usage
- URL uploads are fetched with a 30 second timeout and a 50 MB ceiling, restricted to HTTP and HTTPS, with loopback, private, link-local and redirect-based internal targets blocked
- MIME validation against the formats BookStack accepts: jpeg, png, gif, webp, bmp, tiff and svg+xml
Requirements
A BookStack instance and an API token belonging to a user who can view and manage the image gallery: BS_URL, BS_TOKEN_ID and BS_TOKEN_SECRET. Python with the FastMCP server's requirements installed, launched as a module. Image uploads need a real page context — pass uploaded_to with a page id, since BookStack rejects uploads without one.
Setup effort
Build from source
USE CASES
Drafting a page with its illustrations
Create the page, then upload the images to the gallery against that page id.
Finding where something is documented
Search the full text across the wiki and list the matching chapters and pages.
Reorganising a shelf
Create or move books and chapters, and apply the same edit across many pages at once.
Cleaning up the media library
Find images by extension, size, date or whether anything uses them, then delete the ones that are dead.
6 tools
Listed in project docs. Your client may show a different list.
bookstack_list_contentbookstack_searchbookstack_batch_operationsbookstack_manage_imagesbookstack_search_imagesBEFORE YOU INSTALL
What to know first
Tools you get
6 tools named in the project's documentation. bookstack_content_crud and bookstack_manage_images each cover create, read, update and delete through an operation parameter, so six tools span the full surface.
Requires
- BS_TOKEN_ID in your environment
- BS_TOKEN_SECRET in your environment
Where it runs
The documented client runs the server on your machine.
INSTALLATION
Connect your client
Server setup
git clone https://github.com/oculairmedia/Bookstack-MCP
cd Bookstack-MCP
pip install -r fastmcp_server/requirements.txtCopy .env.example to .env and set BS_URL, BS_TOKEN_ID, BS_TOKEN_SECRET
Start the server over HTTP on port 3054 (the command the project's Dockerfile runs):
fastmcp run fastmcp_server/my_server.py:mcp --transport http --host 0.0.0.0 --port 3054MCP Clients
OpenCode
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"bookstack-mcp": {
"type": "remote",
"url": "http://localhost:3054/mcp",
"enabled": true
}
}
}The repository's own opencode.json points at the maintainer's server (http://192.168.50.90:3054/mcp). Use the address of the server you started — http://localhost:3054/mcp on the same machine. Other clients that accept a Streamable HTTP URL connect to the same address.