Capacities MCP

Capacities MCP

An MCP server for Capacities API 2.0 that enables AI agents to discover, create, read, update, and delete objects, blocks, and daily notes with structured JSON or Markdown, using personal API tokens.

Category
访问服务器

README

Capacities MCP Enhanced — API 2.0 for AI Agents

The official MCP server sucks, it's time to make a new one.

Built for the new Capacities API 2.0 with native precise block level CRUD support.

Capacities MCP brings rich, read-write access to your knowledge base through one agent-friendly server. Agents can discover your object types, understand custom properties, create polished content, make precise edits, save web resources, and work with Daily Notes.

✨ Why Capacities MCP Enhanced

  • Two first-class authoring engines — fast Markdown writing and precise structured blocks in one server.
  • Full CRUD with Capacities API 2.0 — objects, custom properties, collections, blocks, web links, tasks, tags, and Daily Notes.
  • Designed for autonomous agents — live schema discovery, consistent responses, focused tools, and clear recovery information.
  • Safer writes — independent readback verification, soft deletion by default, API-key rate-limit failover, and rollback for failed multi-stage Markdown creates.
  • Concurrency-safe object operations — same-object reads can run concurrently, while writes use an exclusive lock and automatically wait for active reads or other writes; different objects proceed concurrently.
  • Faithful rich content — headings, nested blocks, grids, toggles, tasks, links, entity references, colors, code, and math.
  • Agent-friendly media uploads — stream one or many local files, report progress, verify media objects, and manage long-running jobs without exposing multipart internals.
  • Bundled best-practice skill — a complete agent operating guide is included, so a model can use the server correctly without already knowing Capacities.

🚀 Quick start

Requirements

  • Node.js 20+ or Bun 1.3+
  • One or more personal API keys from the new Capacities API with the permissions you need

Installation

Configure your MCP client to use the Capacities MCP server:

Generate a token in Capacities → Settings → Capacities API → Generate new token. New API tokens begin with cap-api-.
Configuring at least 3 tokens with same space and permissions is recommended to avoid rate-limit errors.

Claude Code

{
  "mcpServers": {
    "capacities": {
      "command": "npx",
      "args": ["--yes", "capacities-mcp-enhanced@latest"],
      "env": {
        "CAPACITIES_API_TOKEN": "cap-api-key-1,cap-api-key-2;cap-api-key-3"
      }
    }
  }
}

Hermes Agent

mcp_servers:
  capacities:
    command: "npx"
    args:
      - "--yes"
      - "capacities-mcp-enhanced@latest"
    env:
      CAPACITIES_API_TOKEN: "cap-api-key-1,cap-api-key-2;cap-api-key-3"
    supports_parallel_tool_calls: true

Install the bundled skills (Optional)

By installing the Capacities MCP Best Practices skill, your agent can learn the full workflow, strict content schemas, safe mutation patterns, rate-limit recovery, and common pitfalls.

npx skills add nyrest/capacities-mcp-enhanced

🧰 What agents can do

Category Tool What it does
Discover and read inspect_space Discover structures, properties, labels, and available write options.
Discover and read search_objects Find objects by title, optionally within selected structures.
Discover and read get_object Read a complete object as structured content or Markdown.
Create objects create_object Create a Page, Task, Tag, or custom object with structured content.
Create objects create_object_markdown Create an object from a Markdown document.
Create objects create_object_from_url Save a web resource with structured notes.
Create objects create_object_from_url_markdown Save a web resource with Markdown notes.
Update content update_object Update titles, typed properties, and collections.
Update content append_content Add structured blocks to an object.
Update content append_content_markdown Add Markdown content to an object.
Update content update_block Precisely edit one existing block.
Update content delete_block Remove one block and its nested content.
Update content delete_object Move an object to trash or permanently delete it when explicitly requested.
Daily Notes append_daily_note Add structured blocks to today's or a dated Daily Note.
Daily Notes append_daily_note_markdown Add Markdown to today's or a dated Daily Note.
Media uploads upload_files Stream one or more local files into Capacities media objects with readback verification.
Media uploads manage_upload_job Inspect, wait for, or cancel an in-process background upload job.

upload_files accepts absolute local file paths only; relative paths, directories, and empty files are rejected. Background upload jobs live only in the current MCP process and retain terminal status for a limited time.

Supported environment variables and configuration options

Setting Required Default Description
CAPACITIES_API_TOKEN Yes, unless every call supplies apiToken — One API key or a comma/semicolon-separated key pool. The keys must belong to the same space and use the same permissions.
CAPACITIES_MCP_READBACK No true Set to false to disable ordinary mutation readback. Rollback verification remains enabled. Accepted values: true, false.

Per-call configuration is exposed through the optional apiToken argument on all tools. It overrides CAPACITIES_API_TOKEN for that call and accepts the same key-pool syntax.

⚙️ API key pool and rate limits

CAPACITIES_API_TOKEN and the per-call apiToken option accept multiple API keys separated by , or ;. Keys are selected with round-robin scheduling independently for each endpoint, skipping keys currently marked as rate-limited.

All keys in one pool must belong to the same space and have the same permissions. At least 3 keys are recommended; use separate MCP server instances for multiple spaces.

On 429, the pool immediately fails over to another key that is not rate limited. The error is returned only when all keys are rate limited. No waiting, exponential backoff, or cross-pool retry is performed.

🚅 Concurrency and safe writes

Reads for the same object can run concurrently. A mutation obtains an exclusive object lock, so it waits for active reads and other writes; reads arriving during a write wait as well. Operations for different objects proceed concurrently. This protects the full read → mutate → readback lifecycle against last-write-wins races. The current Capacities SDK does not expose request cancellation/timeout configuration, so this server does not use an unsafe client-side timeout race for mutations.

🛠️ Development

bun run lint
bun run typecheck
bun test
bun run verify:tools
bun run build

The final local release gate is:

npm run release:check
npm publish --dry-run --access public

npm publish --dry-run validates the package without publishing it. Actual publishing additionally requires an authenticated npm account.

Live API tests are available through bun run test:live when a dedicated test token is configured.

📚 Documentation

推荐服务器

Baidu Map

Baidu Map

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

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

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

官方
精选
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

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

官方
精选
本地
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

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

官方
精选
本地
TypeScript
VeyraX

VeyraX

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

官方
精选
本地
Kagi MCP Server

Kagi MCP Server

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

官方
精选
Python
graphlit-mcp-server

graphlit-mcp-server

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

官方
精选
TypeScript
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 模型以安全和受控的方式获取实时的网络信息。

官方
精选