# BookStack MCP server

> Connect an AI assistant to your BookStack wiki to search documentation, summarize books, and manage pages and content.

- Repository: https://github.com/ttpears/bookstack-mcp
- Page: https://hostedmcp.org/servers/ttpears/bookstack-mcp
- Transport: stdio
- Stars: 56
- License: MIT

## Install

### Claude Code

```sh
claude mcp add bookstack-mcp -- npx -y bookstack-mcp
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "bookstack-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "bookstack-mcp"
      ]
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "bookstack-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "bookstack-mcp"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"bookstack-mcp","type":"stdio","command":"npx","args":["-y","bookstack-mcp"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "bookstack-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "bookstack-mcp"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add bookstack-mcp -- npx -y bookstack-mcp
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.bookstack-mcp]
command = "npx"
args = ["-y", "bookstack-mcp"]
```

### Gemini CLI

```sh
gemini mcp add -s user bookstack-mcp npx -- -y bookstack-mcp
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "bookstack-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "bookstack-mcp"
      ]
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `BOOKSTACK_BASE_URL` | no | no |  |
| `BOOKSTACK_TOKEN_ID` | no | no |  |
| `BOOKSTACK_TOKEN_SECRET` | no | no |  |

## FAQ

### Is the server read-only by default?

Yes, the server is read-only by default, exposing 21 read tools. Write tools can be enabled by setting the BOOKSTACK_ENABLE_WRITE environment variable.

### How do I provide access to the AI assistant?

You need to create a BookStack API token in your profile's API Tokens section, ensuring the user has 'Access System API' and relevant permissions.

### Can the server read WYSIWYG pages as Markdown?

Yes, if you grant the 'Export Content' permission, the server can use the export endpoint as a fallback to read WYSIWYG pages as Markdown.
