Slabby

Slabby

An MCP server that enables AI agents to read, search, update, and list documentation within a Slab knowledge base. It facilitates keeping technical docs and team wikis in sync with development workflows through direct Slab integration.

Category
访问服务器

README

🧱 Slabby

npm version Tests License

MCP server for Slab knowledge base integration with AI coding agents

Slabby is a Model Context Protocol server that enables AI coding agents like Claude Code, Cline, and others to read and update your Slab documentation directly. Perfect for keeping RFCs, technical docs, and team wikis in sync with your development workflow.

Features

  • 📖 Read Slab posts - Fetch post content by ID or URL
  • ✏️ Update Slab posts - Edit posts with changes attributed to you
  • 🔍 Search Slab - Find posts across your workspace
  • 📋 List posts - Browse posts by topic or tag
  • 🔐 Secure authentication - Uses your personal Slab API token

Installation

For Development

git clone https://github.com/russwyte/slabby.git
cd slabby
bun install

From npm

npm install -g @russwyte/slabby
# or
bun install -g @russwyte/slabby

Configuration

1. Get your Slab API token

  1. Go to your Slab workspace → SettingsAPI
  2. Generate a new API token
  3. Copy the token (you'll need it in the next step)

2. Set up environment variables

Create a .env file in the project root:

SLAB_API_TOKEN=your-api-token-here
SLAB_TEAM=your-team-domain  # e.g., "acme" for acme.slab.com

Security Note: Never commit your .env file to git. It's already in .gitignore.

3. Configure Claude Code

Add Slabby to your Claude Code MCP settings:

macOS/Linux: ~/.config/claude-code/claude_desktop_config.json Windows: %APPDATA%\claude-code\claude_desktop_config.json

{
  "mcpServers": {
    "slabby": {
      "command": "bun",
      "args": ["run", "/absolute/path/to/slabby/index.ts"],
      "env": {
        "SLAB_API_TOKEN": "your-token-here",
        "SLAB_TEAM": "your-team-domain"
      }
    }
  }
}

Tip: You can also use environment variables instead of hardcoding the token:

{
  "mcpServers": {
    "slabby": {
      "command": "bun",
      "args": ["run", "/absolute/path/to/slabby/index.ts"],
      "env": {
        "SLAB_API_TOKEN": "${SLAB_API_TOKEN}",
        "SLAB_TEAM": "${SLAB_TEAM}"
      }
    }
  }
}

Usage

Once configured, Claude Code will automatically have access to these tools:

slab__get_post

Fetch a Slab post by ID or URL:

Claude, read the Atlas RFC from https://myteam.slab.com/posts/atlas-rfc-xyz123

slab__update_post

Update a Slab post:

Claude, update the Atlas RFC to reflect the single goal change

slab__search

Search across your Slab workspace:

Claude, search Slab for all documents about "marketing automation"

slab__list_posts

List posts in a topic:

Claude, show me all RFCs in the Engineering topic

Development

Run in development mode (with auto-reload):

bun run dev

Run in production mode:

bun run start

Test the MCP server:

# Using the MCP inspector (install separately)
npx @modelcontextprotocol/inspector bun run index.ts

How It Works

Slabby implements the Model Context Protocol, which allows AI assistants like Claude to interact with external tools and services. When you ask Claude Code to read or update Slab content, it:

  1. Uses your Slab API token to authenticate (format: Authorization: token YOUR_TOKEN)
  2. Makes requests to the Slab GraphQL API at https://api.slab.com/v1/graphql
  3. Returns results to Claude Code
  4. All edits are attributed to your user account in Slab

Security

  • API tokens are stored locally - Never sent to Anthropic's servers
  • Edits show as you - All changes attributed to your Slab account
  • Read-only by default - Update operations require explicit permission
  • Environment-based config - Tokens stored in .env (gitignored)

Slab API Reference

This project uses the Slab GraphQL API. The GraphQL schema is documented at: https://studio.apollographql.com/public/Slab/variant/current/schema/reference

Key operations:

  • query GetPost - Fetch post content by ID
  • mutation UpdatePost - Update post content
  • query SearchPosts - Search posts across workspace
  • query ListPosts - List posts, optionally filtered by topic

⚠️ Important: The GraphQL queries in this project are based on common GraphQL patterns and need to be verified against the actual Slab schema before use with production credentials. See SCHEMA_VERIFICATION.md for a detailed verification checklist.

Troubleshooting

"Authentication failed" error

  • Check that your SLAB_API_TOKEN is correct
  • Verify the token has appropriate permissions in Slab settings

"Team not found" error

  • Ensure SLAB_TEAM matches your Slab subdomain (e.g., "acme" for acme.slab.com)

Claude Code doesn't see the tools

  • Restart Claude Code after updating MCP config
  • Check that the absolute path to index.ts is correct
  • Verify bun is in your PATH

Contributing

Contributions welcome! Please feel free to submit issues, fork the repository, and send pull requests.

When contributing, please:

  1. Add tests for any new functionality
  2. Ensure all tests pass with bun test
  3. Follow the existing code style
  4. Update documentation as needed

License

Copyright 2025 Russ White

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this project except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

See the LICENSE file for the full license text.

Related Projects


Built with ❤️ using Bun and the MCP SDK

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选