Anytype MCP Server

Read and edit Anytype spaces, objects, types and chats through the app's local API

Official · Any Association TypeScript Local · stdio ProductivityKnowledge and memory

71 popularity score ★ 537 ↓ 1.6k/wk

Connect your client

Local (npm)

Add in one click

Opens the app, which asks before it adds the server. Then replace each <NAME> in its settings with your value.

Or add it by command or config

It needs OPENAPI_MCP_HEADERS. Replace each <NAME> with your value.

Claude CodeTerminal
claude mcp add anytype -e OPENAPI_MCP_HEADERS=<OPENAPI_MCP_HEADERS> -- npx -y @anyproto/anytype-mcp
Claude Desktopclaude_desktop_config.json
{
  "mcpServers": {
    "anytype": {
      "command": "npx",
      "args": [
        "-y",
        "@anyproto/anytype-mcp"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
Cursor~/.cursor/mcp.json
{
  "mcpServers": {
    "anytype": {
      "command": "npx",
      "args": [
        "-y",
        "@anyproto/anytype-mcp"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
VS Code.vscode/mcp.json
{
  "servers": {
    "anytype": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@anyproto/anytype-mcp"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
Codex~/.codex/config.toml
[mcp_servers.anytype]
command = "npx"
args = ["-y", "@anyproto/anytype-mcp"]

[mcp_servers.anytype.env]
OPENAPI_MCP_HEADERS = "<OPENAPI_MCP_HEADERS>"
Gemini CLITerminal
gemini mcp add --scope user -e OPENAPI_MCP_HEADERS=<OPENAPI_MCP_HEADERS> anytype npx -- -y @anyproto/anytype-mcp
Local (from source)

Add in one click

Opens the app, which asks before it adds the server. Then replace each <NAME> in its settings with your value.

Or add it by command or config

It needs OPENAPI_MCP_HEADERS. Replace each <NAME> with your value.

FirstTerminal
git clone https://github.com/anyproto/anytype-mcp.git
cd anytype-mcp
bun install
bun run build
Claude CodeTerminal
claude mcp add anytype -e OPENAPI_MCP_HEADERS=<OPENAPI_MCP_HEADERS> -- node '<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs'
Claude Desktopclaude_desktop_config.json
{
  "mcpServers": {
    "anytype": {
      "command": "node",
      "args": [
        "<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
Cursor~/.cursor/mcp.json
{
  "mcpServers": {
    "anytype": {
      "command": "node",
      "args": [
        "<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
VS Code.vscode/mcp.json
{
  "servers": {
    "anytype": {
      "type": "stdio",
      "command": "node",
      "args": [
        "<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs"
      ],
      "env": {
        "OPENAPI_MCP_HEADERS": "<OPENAPI_MCP_HEADERS>"
      }
    }
  }
}
Codex~/.codex/config.toml
[mcp_servers.anytype]
command = "node"
args = ["<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs"]

[mcp_servers.anytype.env]
OPENAPI_MCP_HEADERS = "<OPENAPI_MCP_HEADERS>"
Gemini CLITerminal
gemini mcp add --scope user -e OPENAPI_MCP_HEADERS=<OPENAPI_MCP_HEADERS> anytype node -- '<ABSOLUTE_PATH_TO_CLONE>/bin/cli.mjs'

Settings 3

OPENAPI_MCP_HEADERS Required: JSON with the Authorization header ("Bearer <YOUR_API_KEY>") and Anytype-Version (the README uses 2025-11-08).
ANYTYPE_API_BASE_URL Optional: Address of the Anytype API; defaults to http://127.0.0.1:31009, use http://localhost:31012 for anytype-cli.
ANYTYPE_MCP_DEBUG Optional: Set to 1 to log operation names, status and timing to stderr.

What it does

Anytype MCP Server is the Anytype team's own bridge between an MCP client and the Anytype app. It does not ship a fixed set of tools: when it starts, it downloads the OpenAPI document that the locally running Anytype app serves (by default at http://127.0.0.1:31009), turns each API operation into a tool, and forwards calls to that local API with the user's API key.

With a current app this means the v2 API: search across spaces or within one, spaces and members, objects, collections and saved queries, properties and their options, types and templates, file upload and download, and space chats. If the app does not serve v2, the server falls back to the v1 document; a spec URL or local file can also be passed after the `run` argument to pin a version.

The tool list is wider than the README's feature list suggests. Against the v2 API document kept in the repository's test fixtures (taken from the app on 2026-09-15), version 2.0.1 exposes 46 tools, listed here by operation name; a client sees each as `API-` plus that name with hyphens (list_properties appears as `API-list-properties`). They include eleven for chats and two for files. Three operations are held back by its tool policy: creating auth challenges, creating API keys, and the chat event stream. Because the list comes from the app, the exact tools depend on the Anytype version installed; restart the server after updating Anytype to pick up new operations.

Writes can carry `expected_etag` so an update fails instead of overwriting a changed object, and the server adds a retry key to writes that support one. The package also has a `get-key` command that pairs with the app to create an API key from the terminal.

What it needs

RuntimeNode.js

Node.js with npx (or Bun to build from source). The Anytype desktop app installed, signed in and running on the same machine, with its local API reachable (port 31009 by default, or 31012 for anytype-cli via `ANYTYPE_API_BASE_URL`). An API key created in Anytype under App Settings > API Keys, or with `npx -y @anyproto/anytype-mcp get-key`, passed in `OPENAPI_MCP_HEADERS`.

Limits

It fails to start if the Anytype app is not running or reachable, if the key is rejected, or if the API document cannot be read; it does not retry with another API version in those cases. The tool list is read once per process, so updating Anytype needs a server restart. It cannot create API keys or pairing challenges, and it does not stream chat events; chat messages are fetched by listing. Downloaded files are written to a private temporary folder on the machine running the server and stay there until removed. Tools differ between v1 and v2 apps.

Who it suits

Suits Anytype users who want an assistant to search, file and update their own notes, tasks and collections on the same computer where the app runs, and who are comfortable giving it a key that can also delete objects and post in chats. As it talks only to the local app, it is not a fit for reaching Anytype from a remote server or a machine without the desktop app or anytype-cli running.

Tools 46

auth_whoami
Show what the configured API key is allowed to do
list_schemas
List the schemas the Anytype API publishes
get_op_schema
Fetch the input schema for one edit operation
get_schema
Fetch one schema by kind
search_global
Search objects in every space the key can see
list_spaces
List the user's spaces
create_space
Make a new space
get_space
Read one space's details
update_space
Change a space's name or description
list_chats
List chats in a space
create_chat
Make a chat in a space
get_chat_messages
Read messages from a chat
add_chat_message
Post a message to a chat
delete_chat_message
Remove a chat message
edit_chat_message
Change the text of a chat message
toggle_chat_reaction
Add or remove a reaction on a message
read_chat
Mark a chat's activity as read
create_collection
Make a collection in a space
get_collection_objects
List the objects in a collection
get_collection_views
List a collection's views
upload_file
Upload a file into a space
download_file
Save a file's content to a temporary folder on the local machine
list_members
List the members of a space
get_member_me
Read the current user's membership in a space
list_objects
List objects in a space
create_object
Make a page, task or other object
delete_object
Delete an object
get_object
Read one object with its content
patch_object
Change an object's fields or content
list_properties
List the properties defined in a space
create_property
Define a new property
delete_property
Remove a property
update_property
Change a property's definition
list_property_options
List the options (tags) of a select property
create_query
Make a saved query (set)
get_query_objects
List the objects a query returns
get_query_views
List a query's views
search_space
Search objects within one space
create_template
Make a template for a type
list_types
List the object types in a space
create_type
Define a new object type
delete_type
Remove an object type
get_type
Read one object type
update_type
Change an object type
get_type_schema
Fetch the field schema of an object type
validate
Check an AnyBlock document before writing it

Similar servers