pb_mcp_server
MCP server from ssakone/pb_mcp_server
claude mcp add --transport stdio ssakone-pb_mcp_server npm start
How to use
This MCP server provides a comprehensive interface to PocketBase, exposing authentication, session management, collection and record operations, user management, and custom HTTP capabilities through a set of MCP tools. You can authenticate as an admin or a user to obtain a session, perform CRUD actions on collections and records, and manage users in the authentication collection. The server supports per-request session persistence, custom HTTP headers, and the option to output responses in JSON or a more compact TOON format to reduce token usage when communicating with LLMs. You can also connect to multiple PocketBase instances and issue raw HTTP requests to any PocketBase API endpoint via the Custom HTTP Requests Tool.
How to install
Prerequisites:
- Node.js (version 14+ recommended) and npm installed
- Git installed
Installation steps:
-
Clone the repository: git clone https://github.com/ssakone/pocketbase-mcp-server.git cd pocketbase-mcp-server
-
Install dependencies: npm install
-
Build the project (if applicable): npm run build
-
Start the server: npm start
Optional: run in HTTP mode for remote access (if you want the HTTP/SSE endpoint): npm run start:http PORT=8080 npm run start:http
Configuration can be provided via environment variables as described in the configuration section of the README.
Environment setup examples (bash): export POCKETBASE_URL=http://127.0.0.1:8090 export POCKETBASE_ADMIN_EMAIL=admin@example.com export POCKETBASE_ADMIN_PASSWORD=your_password export MCP_OUTPUT_FORMAT=json
Additional notes
Tips and considerations:
- Environment variables such as POCKETBASE_URL, POCKETBASE_ADMIN_EMAIL, and POCKETBASE_ADMIN_PASSWORD enable auto-authentication at startup if provided.
- The MCP_OUTPUT_FORMAT option supports json (default) or toon; use toon to reduce token usage when talking to LLMs.
- The server supports multi-instance connections to different PocketBase deployments; pass different base URLs and tokens per request as needed.
- For large collections or heavy usage, enable session persistence across requests using saveSession where applicable.
- When using the HTTP mode, the SSE endpoint is exposed at http://localhost:3001/sse by default unless configured otherwise.
- If you encounter authentication errors, verify that the admin token or credentials (POCKETBASE_ADMIN_EMAIL/POCKETBASE_ADMIN_PASSWORD) are correct and that the PocketBase instance is reachable at POCKETBASE_URL.
Related MCP Servers
iterm
A Model Context Protocol server that executes commands in the current iTerm session - useful for REPL and CLI assistance
mcp
Octopus Deploy Official MCP Server
furi
CLI & API for MCP management
editor
MCP Server for Phaser Editor
DoorDash
MCP server from JordanDalton/DoorDash-MCP-Server
mcp
MCP сервер для автоматического создания и развертывания приложений в Timeweb Cloud