BookStack MCP Server
Summary: You can use this BookStack MCP server to search, browse, export, and monitor wiki content through a read-only tool schema.
Search content and pages, including BookStack advanced search syntax.
List and read books, pages, chapters, shelves, and attachments with filtering and pagination.
Export pages, books, and chapters as HTML, Markdown, plaintext, PDF, or ZIP.
Retrieve recent changes and inspect server capabilities.
The provided schema is read-only; the README notes optional write tools can be enabled separately.
Provides comprehensive tools for managing BookStack content including searching across books, pages, and chapters, creating and updating pages, retrieving detailed information about books and chapters, and exporting pages in various formats (HTML, PDF, Markdown, Plain text).
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@BookStack MCP Server search for pages about API documentation"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
BookStack MCP Server
Connect an AI assistant to your BookStack wiki through the Model Context Protocol. Search documentation, answer questions with source links, summarize books, and optionally maintain pages and other content.
Read-only by default. The server exposes 21 read tools and, when enabled, 22 write tools. BookStack permissions still apply to every API request. Use a dedicated account with access to only the content the assistant should see.
Quick Start
1. Create a BookStack API token
In BookStack, open your profile's API Tokens section and create a token for a dedicated user. Its role needs Access System API and permission to view the relevant books/pages. Copy both the Token ID and Token Secret; they are separate values.
Also grant Export Content to read WYSIWYG pages as Markdown: BookStack stores no Markdown source for those pages, so the server uses its export endpoint as a fallback. User lookup and recycle-bin tools require additional administrative permissions; ordinary reading does not.
2. Choose an installation
Your setup | Start here |
Claude Desktop | Install the |
Claude Code | |
Codex or Gemini CLI | |
Cursor | |
Any local MCP client | Use the stdio configuration below |
LibreChat / shared Docker service | |
Remote connector with Microsoft sign-in |
For npm-based installations, use a supported Node.js LTS release (Node 24 recommended; CI also uses Node 22). The published package declares node >=18; that minimum is not a recommendation to run an unsupported Node release. Docker includes its own Node runtime.
3. Configure a local MCP client
Add this entry to your client's MCP configuration, replacing the example values:
{
"mcpServers": {
"bookstack": {
"command": "npx",
"args": ["-y", "bookstack-mcp@5.7.1"],
"env": {
"BOOKSTACK_BASE_URL": "https://wiki.example.com",
"BOOKSTACK_TOKEN_ID": "your-token-id",
"BOOKSTACK_TOKEN_SECRET": "your-token-secret"
}
}
}
}This configuration contains credentials: keep it private and outside version control. It pins the reviewed release 5.7.1; update the exact version deliberately when upgrading. The repository's native plugin/extension launchers also pin a matching npm version.
Restart the client, check that BookStack tools appear, and ask: “List the books I can access, then find our onboarding guide and link to it.” This verifies MCP connectivity and BookStack access. Starting npx without the required settings fails; starting it in a terminal with settings waits for MCP input rather than opening a web interface.
Related MCP server: BookStack MCP Server
Client Configuration
The client guide covers Claude Desktop, Claude Code, Codex, Cursor, Gemini CLI, and LibreChat, including per-user HTTP credential headers. The configuration reference documents all server settings and the different npm and Docker defaults.
For development from a checkout, see CONTRIBUTING.md. The server does not automatically read .env; use the client's env settings, export variables, or explicitly pass Node's --env-file option.
Available Tools
Task | Tools and behavior |
Find information |
|
Read the wiki | List/detail tools for books, chapters, pages, shelves, attachments, and comments; |
Export |
|
Maintain content | Optional create/update/delete tools, gallery image uploads, and recycle-bin operations |
See the complete tool reference and recipes for all 43 tool names, pagination, tags, image policies, and version requirements. MCP tools/list on your connected server is authoritative for argument schemas and enabled tools.
To enable writes in non-OAuth mode, set BOOKSTACK_ENABLE_WRITE=true and use a BookStack token with the corresponding permissions. In OAuth mode, writes instead require the configured Entra role and a separate write-token pair. Entra users normally share those BookStack service accounts; sign-in does not automatically give each user their own BookStack identity or private content boundary.
Editing pages safely
For HTML/WYSIWYG pages, read
get_pagewithformat: "raw"and update usinghtml. The renderedhtmlview can remove editor attributes and resolve includes.For Markdown pages, read
format: "markdown"and update usingmarkdown. Savinghtmlclears the stored Markdown source.Tags replace the entire tag list. Omit
tagsto preserve it, or send[]to clear it. Read the current list before changing individual tags.Read all content chunks before replacing a large page. Worked examples show the workflow.
MCP Resources
Clients with resource support can browse bookstack://book/{id} for book metadata and bookstack://page/{id} for Markdown and page metadata. Both templates provide ID completion through BookStack search.
Four MCP prompts guide read workflows: answer_from_wiki, find_pages, summarize_book, and recent_changes. Prompt arguments are documented alongside the tools. Client support for resources and prompts varies.
Security
Use HTTPS, keep TLS verification enabled, and protect HTTP services with OAuth or a trusted internal network. HTTP without OAuth has no built-in caller authentication. Set an explicit allowed-host list when exposing a container; a host allowlist is not authentication.
HTTP image downloads require an allowed hostname, and local file uploads are disabled by default. Request bodies, request duration, and session counts are bounded. See deployment boundaries and the security policy, including private vulnerability reporting.
The privacy policy explains data flows, credentials, OAuth/Redis state, and logging. Your AI client and deployment operator may have additional policies. Use is governed by the terms and MIT license.
Documentation
Browse the documentation index for installation, deployment, configuration, tool recipes, troubleshooting, contributions, releases, and HOL Guard. For a connection problem, start with the troubleshooting guide.
Design background: Why my BookStack MCP server starts read-only describes permission boundaries, shared-token rate limiting, and response-size decisions.
Available Tools
17 toolsexport_bookExport BookC
Export an entire book in various formats
Inputs: id (required), format (required).
export_chapterExport ChapterC
Export a chapter in various formats
Inputs: id (required), format (required).
export_pageExport PageB
Export a page in various formats (PDF/ZIP provide direct BookStack download URLs)
Inputs: id (required), format (required).
get_attachmentGet Attachment DetailsC
Get details of a specific attachment including download links
Inputs: id (required).
get_attachmentsList AttachmentsC
List attachments (files and links) with filtering and sorting
Inputs: offset, count, sort, filter.
get_bookGet Book DetailsC
Get detailed information about a specific book
Inputs: id (required).
get_booksList BooksC
List available books with advanced filtering and sorting
Inputs: offset, count, sort, filter.
get_capabilitiesGet BookStack CapabilitiesB
Get information about available BookStack MCP capabilities and current configuration
Inputs: no named parameters.
get_chapterGet Chapter DetailsC
Get details of a specific chapter
Inputs: id (required).
get_chaptersList ChaptersC
List chapters, optionally filtered by book
Inputs: book_id, offset, count.
get_pageGet Page ContentC
Get full content of a specific page
Inputs: id (required).
get_pagesList PagesC
List pages with content previews, word counts, and contextual information
Inputs: book_id, chapter_id, offset, count, +2 more.
get_recent_changesGet Recent ChangesC
Get recently updated content with contextual previews and change descriptions
Inputs: type, limit, days.
get_shelfGet Shelf DetailsC
Get details of a specific book shelf including all books
Inputs: id (required).
get_shelvesList ShelvesC
List available book shelves (collections) with filtering and sorting
Inputs: offset, count, sort, filter.
search_contentSearch BookStack ContentC
Search across BookStack content with contextual previews and location info
Inputs: query (required), type, count, offset.
search_pagesSearch PagesC
Search specifically for pages with optional book filtering
Inputs: query (required), book_id, count, offset.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 17 tools
Most tools have clearly distinct purposes targeting specific resources like books, chapters, pages, attachments, and shelves, with clear action distinctions (get vs. list vs. export). However, search_content and search_pages have some overlap in purpose, as both handle search operations, which could cause minor confusion for an agent.
Tool names follow a highly consistent verb_noun pattern throughout, such as get_book, export_page, and search_content. All tools use snake_case with clear, descriptive verbs, making the set predictable and easy to navigate.
With 17 tools, the count is slightly high but reasonable for a content management system like BookStack, covering resources like books, chapters, pages, shelves, and attachments. It feels comprehensive without being overwhelming, though it borders on the heavier side.
The tool surface provides complete CRUD-like coverage for the BookStack domain, including retrieval (get/list), export, search, and management of attachments and recent changes. There are no obvious gaps, and agents can perform full lifecycle operations on all core resources.
Maintenance
Related MCP Connectors
Connect to your MediaWiki using simple credentials and manage content without OAuth. Search, read,…
Search, read and edit your team's docs-as-code documentation, synced with Git.
Knowledge base MCP for AI agents on iknow.dev. Search, read, and maintain via OAuth.
Bookatu's help centre, blogs and developer docs. Read only, no key needed.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables AI models to interact with BookStack wiki instances through a comprehensive API interface. Supports content management (books, chapters, pages), user administration, search functionality, and content export in multiple formats.4110 npmMIT
- FlicenseNot gradedqualityDmaintenanceEnables AI assistants to manage BookStack documentation through natural language, supporting content browsing, search, and CRUD operations for books, chapters, and pages.-
- AlicenseBqualityBmaintenanceConnects BookStack knowledge bases to Claude through 47+ tools covering complete CRUD operations for books, pages, chapters, shelves, users, search, attachments, and permissions. Enables full management of BookStack content and configuration through natural language.56475 npm105MIT
- AlicenseCqualityDmaintenanceEnables searching and retrieving content from BookStack knowledge bases via the BookStack API. It provides structured page data with clean HTML-to-text conversion for seamless integration with AI models.110MIT