Skip to main content
mcpSource-backed

AFFiNE MCP Server

MCP server for connecting Claude to AFFiNE Cloud or self-hosted AFFiNE workspaces, documents, databases, comments, collections, folders, tags, notifications, blobs, access tokens, semantic page composition, templates, edgeless canvas data, and workspace organization workflows over stdio or HTTP.

by DAWNCR0W · submitted by oktofeesh1·added 2026-06-06·
Review first review before installing

Open the source and read safety notes before installing.

Citation facts

Source-backed facts for citing this resource, derived directly from the registry — also available as plain text for AI assistants.

Source URLs
https://github.com/DAWNCR0W/affine-mcp-server/blob/main/README.md, https://github.com/DAWNCR0W/affine-mcp-server
Brand
AFFiNE MCP Server
Brand domain
github.com
Safety notes
The full tool surface can create, update, publish, revoke, move, replace, and delete AFFiNE workspaces, documents, folders, collections, comments, database rows, blobs, surface elements, tags, and access tokens., Start with AFFINE_TOOL_PROFILE=read_only or disable groups such as destructive, admin, blobs, users, access_tokens, docs.database, or write when the assistant only needs discovery or reading., HTTP mode exposes MCP endpoints and must be protected with bearer or OAuth authentication, HTTPS, allowed origins, and deployment-level access controls., AFFiNE Cloud requires API tokens for MCP usage; avoid trying to automate email/password login against Cloud deployments., Cookie and password-based auth can grant broad account access and should be avoided for unattended or shared deployments.
Privacy notes
Workspaces, document titles, document bodies, comments, tags, database schemas, database rows, edgeless canvas data, notifications, user profiles, access-token metadata, blobs, and exported markdown can be sent to the MCP client and model., API tokens, cookies, passwords, bearer tokens, OAuth config, and saved config files should be treated as secrets and kept out of prompts, logs, screenshots, issues, and committed MCP config., Generated or modified documents can persist in AFFiNE and may become visible to collaborators depending on workspace permissions and sharing state., Blob upload, cleanup, export, and publish/revoke workflows can expose files, generated content, or collaboration state beyond the current prompt.
Author
DAWNCR0W
Submitted by
oktofeesh1
Claim status
unclaimed
Last verified
2026-06-06

Decision playbook

Review trust signals before you adopt

Signals are present but mixed. Use the checklist below to confirm the source and operational safety for your environment.

Compare context
Selected

0

Current score

63

Baseline

Delta

No baseline selected

No major trust-signal divergence detected in the current selection.

Source and provenance checks

Needs review

Confirm ownership and provenance before trusting install instructions.

  • Source link availableRequired

    Open the canonical repository and verify ownership.

    Done
  • Source provenance statusRequired

    Marked as source-backed.

    Done
  • Metadata reviewed

    No reviewed flag detected in metadata.

    Pending

Safety and privacy checks

Complete

Validate risk disclosures before installation or API wiring.

  • Safety notes presentRequired

    Review the listed safety guidance before running commands.

    Done
  • Privacy notes presentRequired

    Review data handling notes before connecting accounts or secrets.

    Done
  • Trust level risk gateRequired

    Trust level does not block evaluation.

    Done

Package and install checks

Needs review

Check package metadata and artifact integrity signals.

  • Install payload available

    Install or copy payload is available for review.

    Done
  • Package verification flag

    No package verification flag provided.

    Pending
  • Checksum metadata

    No checksum provided for downloaded artifact.

    Pending

Compare-driven decision checks

Needs review

Use compare context to validate trade-offs before adoption.

  • Compare tray has multiple entries

    Add at least one more entry to compare trust differences.

    Pending
  • Baseline comparison available

    No baseline peer selected yet.

    Pending
  • Diverging trust signals identified

    No major trust-signal divergence found.

    Pending

Setup at a glance

CLI install

Copy-ready — paste the snippet to get started.

15 minutes

Adoption plan

Balanced adoption plan

Current risk score 24/100. Use staged verification before broader rollout.

Risk 24

Pre-adoption checks

Validate source and review signals before any execution.

  • Confirm source provenanceRequired

    Source URL/provenance metadata is present.

    Done
  • Confirm metadata review state

    No review metadata found; increase manual validation.

    Pending
  • Verify install payload

    Install/config payload exists and can be inspected.

    Done

Security checks

Confirm safety, privacy, and package integrity signals.

  • Review safety notesRequired

    Safety notes are present.

    Done
  • Review privacy notesRequired

    Privacy notes are present.

    Done
  • Verify package integrity metadata

    No package verification/checksum metadata.

    Pending

Rollout

Adopt in controlled steps based on the selected plan.

  • Run in isolated sandbox firstRequired

    Use a constrained sandbox and observe behavior across multiple tasks.

    Pending
  • Roll out graduallyRequired

    Roll out to a small cohort before wider usage.

    Pending
  • Set monitoring and fallback

    Define rollback path and monitor errors after adoption.

    Pending

Evidence readiness

Evidence readiness matrix · balanced

Missing required evidence: Metadata review. Risk score 31.

Risk 31

Source provenance

Present

Source repository/provenance is listed.

Required in this preset

Metadata review

Missing

Review metadata is missing.

Required in this preset

Safety notes

Present

Safety notes are present.

Required in this preset

Privacy notes

Present

Privacy notes are present.

Optional in this preset

Package integrity

Missing

Package integrity metadata is missing.

Optional in this preset

Install payload

Present

Install payload is available.

Required in this preset

Required gaps: Metadata review

Decision timeline

Decision timeline · balanced

Blocking gaps: Check metadata review status. Risk 28.

Risk 28

triage

Confirm source provenanceRequired

Source/provenance metadata is available.

Done

triage

Check metadata review statusRequired

Review metadata is missing.

Pending

verify

Review safety notesRequired

Safety notes are available.

Done

verify

Review privacy notes

Privacy notes are available.

Done

verify

Validate package integrity metadata

Package integrity metadata is missing.

Pending

rollout

Verify install payload and commandsRequired

Install payload is available.

Done

Blockers: Check metadata review status

Prerequisite readiness

Prerequisite readiness

5 prerequisites to line up before setup. Have accounts and credentials ready first.

0/5 ready
Account & credentials3Install & runtime215 minutes

Safety & privacy surface

Safety & privacy surface

5 safety and 4 privacy notes across 3 risk areas. Review closely: credentials & tokens, permissions & scopes, network access.

3 areas
  • SafetyCredentials & tokensThe full tool surface can create, update, publish, revoke, move, replace, and delete AFFiNE workspaces, documents, folders, collections, comments, database rows, blobs, surface elements, tags, and access tokens.
  • SafetyCredentials & tokensStart with AFFINE_TOOL_PROFILE=read_only or disable groups such as destructive, admin, blobs, users, access_tokens, docs.database, or write when the assistant only needs discovery or reading.
  • SafetyCredentials & tokensHTTP mode exposes MCP endpoints and must be protected with bearer or OAuth authentication, HTTPS, allowed origins, and deployment-level access controls.
  • SafetyCredentials & tokensAFFiNE Cloud requires API tokens for MCP usage; avoid trying to automate email/password login against Cloud deployments.
  • SafetyCredentials & tokensCookie and password-based auth can grant broad account access and should be avoided for unattended or shared deployments.
  • PrivacyCredentials & tokensWorkspaces, document titles, document bodies, comments, tags, database schemas, database rows, edgeless canvas data, notifications, user profiles, access-token metadata, blobs, and exported markdown can be sent to the MCP client and model.
  • PrivacyCredentials & tokensAPI tokens, cookies, passwords, bearer tokens, OAuth config, and saved config files should be treated as secrets and kept out of prompts, logs, screenshots, issues, and committed MCP config.
  • PrivacyPermissions & scopesGenerated or modified documents can persist in AFFiNE and may become visible to collaborators depending on workspace permissions and sharing state.
  • PrivacyNetwork accessBlob upload, cleanup, export, and publish/revoke workflows can expose files, generated content, or collaboration state beyond the current prompt.

Safety notes

  • The full tool surface can create, update, publish, revoke, move, replace, and delete AFFiNE workspaces, documents, folders, collections, comments, database rows, blobs, surface elements, tags, and access tokens.
  • Start with AFFINE_TOOL_PROFILE=read_only or disable groups such as destructive, admin, blobs, users, access_tokens, docs.database, or write when the assistant only needs discovery or reading.
  • HTTP mode exposes MCP endpoints and must be protected with bearer or OAuth authentication, HTTPS, allowed origins, and deployment-level access controls.
  • AFFiNE Cloud requires API tokens for MCP usage; avoid trying to automate email/password login against Cloud deployments.
  • Cookie and password-based auth can grant broad account access and should be avoided for unattended or shared deployments.

Privacy notes

  • Workspaces, document titles, document bodies, comments, tags, database schemas, database rows, edgeless canvas data, notifications, user profiles, access-token metadata, blobs, and exported markdown can be sent to the MCP client and model.
  • API tokens, cookies, passwords, bearer tokens, OAuth config, and saved config files should be treated as secrets and kept out of prompts, logs, screenshots, issues, and committed MCP config.
  • Generated or modified documents can persist in AFFiNE and may become visible to collaborators depending on workspace permissions and sharing state.
  • Blob upload, cleanup, export, and publish/revoke workflows can expose files, generated content, or collaboration state beyond the current prompt.

Prerequisites

  • Node.js and npm for installing the affine-mcp-server package.
  • AFFiNE Cloud API token or approved self-hosted AFFiNE credentials.
  • AFFiNE base URL for the Cloud or self-hosted deployment.
  • Clear workspace scope and least-privilege tool profile before enabling write, admin, destructive, blob, or access-token tools.
  • HTTPS, bearer-token, or OAuth planning before exposing HTTP mode beyond a local trusted client.

Schema details

Install type
cli
Troubleshooting
No
Source repository stats
Scope
Source repo
Collection metadata
Estimated setup
15 minutes
Difficulty
intermediate
Full copyable content
{
  "mcpServers": {
    "affine": {
      "command": "affine-mcp"
    }
  }
}

About this resource

Content

AFFiNE MCP Server connects Claude and other MCP clients to AFFiNE Cloud or self-hosted AFFiNE deployments. It exposes a large tool surface for workspaces, documents, markdown import/export, semantic pages, templates, document trees, collections, folders, tags, databases, comments, history, notifications, user settings, personal access tokens, blob storage, and edgeless canvas data.

The server supports local stdio usage for desktop or CLI MCP clients and HTTP mode for remote deployments. Authentication can use AFFiNE API tokens, saved interactive login config, cookies, or self-hosted email/password credentials, with API tokens recommended for stable automation.

Source Review

These sources were reviewed on 2026-06-06. Prefer the live repository, README, npm metadata, package metadata, tool manifest, server entrypoint, tool filter implementation, configuration and deployment guide, security policy, and license file for current install commands, supported transports, auth strategy, tool profiles, tool groups, and licensing.

Features

  • NPM package affine-mcp-server with the affine-mcp CLI.
  • Local stdio transport for Claude Code, Claude Desktop, Codex CLI, Cursor, and other local MCP clients.
  • HTTP transport with /mcp, /sse, /messages, /healthz, and /readyz endpoints for remote deployments.
  • AFFiNE Cloud and self-hosted AFFiNE support through GraphQL and WebSocket APIs.
  • API token, saved config, cookie, and self-hosted email/password auth modes.
  • Tool profiles for full, read_only, core, and authoring surfaces.
  • Tool-group and exact-tool disabling through environment variables.
  • Workspace, document, database, comment, history, user, access-token, notification, blob, organization, folder, collection, tag, template, semantic page, and edgeless canvas workflows.
  • MIT license.

Installation

Install the CLI package:

npm i -g affine-mcp-server
affine-mcp login

Configure a local MCP client:

{
  "mcpServers": {
    "affine": {
      "command": "affine-mcp",
      "env": {
        "AFFINE_BASE_URL": "<affine-base-url>",
        "AFFINE_API_TOKEN": "<affine-api-token>",
        "AFFINE_TOOL_PROFILE": "read_only"
      }
    }
  }
}

Verify the connection with affine-mcp status and affine-mcp doctor, then broaden tool access only when the workflow requires authoring, admin, blob, database, or destructive operations.

Use Cases

  • Search, read, and export AFFiNE documents from Claude.
  • Create or update workspace docs, tags, folders, collections, comments, and database rows under a controlled tool profile.
  • Compose structured pages, semantic sections, markdown imports, templates, or edgeless canvas elements from approved prompts.
  • Inspect workspace trees, document fidelity, capabilities, history, notifications, and orphaned docs.
  • Run a constrained remote HTTP MCP endpoint for a team-owned AFFiNE deployment.
  • Generate or revoke AFFiNE access tokens only in an explicitly approved admin workflow.

Safety and Privacy

AFFiNE MCP Server can be read-only or highly write-capable depending on its tool profile and disabled groups. Start with AFFINE_TOOL_PROFILE=read_only for research and discovery. For authoring workflows, explicitly choose which write groups are allowed, and disable destructive or admin groups unless the assistant really needs them.

The full surface can create and delete workspaces, replace documents with markdown, modify databases, publish or revoke documents, upload or delete blobs, update settings and profiles, and generate or revoke access tokens. Run these tools only against approved workspaces, and verify important changes in AFFiNE before relying on them.

AFFiNE content can include sensitive personal notes, team docs, comments, databases, attachments, notifications, profile data, and collaboration metadata. Protect API tokens, cookies, saved config files, HTTP bearer tokens, OAuth settings, exported markdown, logs, prompts, and transcripts. For HTTP mode, use HTTPS, strong auth, constrained allowed origins, and deployment-level network controls.

Duplicate Check

No AFFiNE MCP Server, DAWNCR0W/affine-mcp-server, affine-mcp-server, or dedicated AFFiNE workspace/document MCP entry was found in content/mcp, content/agents, content/guides, or content/skills. This entry is scoped to the AFFiNE MCP server for Cloud and self-hosted AFFiNE APIs and does not duplicate general note-taking, document, or database MCP entries.

Source citations

Add this badge to your README

Show that AFFiNE MCP Server is listed on HeyClaude. Paste this Markdown into your README — it renders the badge and links back to this page.

Listed on HeyClaude
[![Listed on HeyClaude](https://heyclau.de/badge/mcp/affine-mcp-server.svg)](https://heyclau.de/entry/mcp/affine-mcp-server)

How it compares

AFFiNE MCP Server side by side with 3 alternatives on trust, install, platform support, and disclosed safety notes — all from reviewed registry metadata.

Field

MCP server for connecting Claude to AFFiNE Cloud or self-hosted AFFiNE workspaces, documents, databases, comments, collections, folders, tags, notifications, blobs, access tokens, semantic page composition, templates, edgeless canvas data, and workspace organization workflows over stdio or HTTP.

Open dossier

Official Yuque MCP server that connects Claude to Yuque knowledge bases for user lookup, search, books, documents, notes, resources, and table-of-contents workflows, including read, create, and update tools over stdio with personal or group API tokens.

Open dossier

Official Agentset MCP server that lets Claude retrieve cited knowledge-base results from an Agentset namespace through the `knowledge-base-retrieve` tool, with optional tenant scoping and custom tool descriptions.

Open dossier

Apache-licensed TypeScript MCP server for Obsidian vaults with stdio and Streamable HTTP transports, Local REST API access, note search, section-aware edits, tag/frontmatter management, path policies, and read-only controls.

Open dossier
Next steps
Trust
Review statusNot reviewedNot reviewedNot reviewedNot reviewed
Package trustPackage not verifiedPackage not verifiedPackage not verifiedPackage not verified
Source provenanceSource-backedSource-backedSource-backedSource-backed
Submitteroktofeesh1oktofeesh1oktofeesh1oktofeesh1
Install riskReview firstReview firstReview firstReview first
Notes Safety ✓ Privacy ✓ Safety ✓ Privacy ✓ Safety ✓ Privacy ✓ Safety ✓ Privacy ✓
BrandAgentset logoAgentset
Categorymcpmcpmcpmcp
SourceSource-backedSource-backedSource-backedSource-backed
AuthorDAWNCR0WYuqueAgentsetcyanheads
Added2026-06-062026-06-062026-06-062026-06-06
Platforms
Harness
Source repo
Safety notesThe full tool surface can create, update, publish, revoke, move, replace, and delete AFFiNE workspaces, documents, folders, collections, comments, database rows, blobs, surface elements, tags, and access tokens. Start with AFFINE_TOOL_PROFILE=read_only or disable groups such as destructive, admin, blobs, users, access_tokens, docs.database, or write when the assistant only needs discovery or reading. HTTP mode exposes MCP endpoints and must be protected with bearer or OAuth authentication, HTTPS, allowed origins, and deployment-level access controls. AFFiNE Cloud requires API tokens for MCP usage; avoid trying to automate email/password login against Cloud deployments. Cookie and password-based auth can grant broad account access and should be avoided for unattended or shared deployments.Yuque MCP Server can search and read content, but it also exposes create, update, and delete workflows for books, documents, notes, resources, and tables of contents. The upstream security policy recommends read-only tokens when only read access is needed. Tokens passed as CLI arguments can appear in shell history, process listings, or client logs; prefer environment variables or a secrets manager. Custom YUQUE_BASE_URL values should point only to trusted Yuque deployments and should use HTTPS for remote services. Rate limits, deleted resources, token expiration, private-deployment behavior, and Yuque API changes can affect tool results.The MCP server sends Claude's retrieval queries to the Agentset API using the configured API key and namespace. The `knowledge-base-retrieve` tool can return up to 100 results per call and can rerank results by relevance. Namespace and tenant selection control which indexed documents are searchable; review them before connecting a shared agent. API keys should be scoped, rotated, and stored only in the MCP server environment or a secret manager. Custom tool descriptions can influence when the model calls the retrieval tool, so review them before use in production workflows.Cyanheads Obsidian MCP can read, list, search, create, append, patch, replace, delete, tag, and edit frontmatter in the configured vault through the Local REST API plugin. The server defaults to full-vault access unless read paths, write paths, or read-only mode are configured. Set `OBSIDIAN_READ_ONLY=true` for research-only workflows, then narrow writes with `OBSIDIAN_WRITE_PATHS` before allowing note edits. Delete operations are permanent in the vault and should require human review even when the MCP host supports destructive-tool prompts. Command-palette tools are disabled unless `OBSIDIAN_ENABLE_COMMANDS=true`; command execution can trigger opaque or destructive Obsidian plugin behavior. Streamable HTTP deployments should use JWT or OAuth auth before being exposed beyond a trusted local machine.
Privacy notesWorkspaces, document titles, document bodies, comments, tags, database schemas, database rows, edgeless canvas data, notifications, user profiles, access-token metadata, blobs, and exported markdown can be sent to the MCP client and model. API tokens, cookies, passwords, bearer tokens, OAuth config, and saved config files should be treated as secrets and kept out of prompts, logs, screenshots, issues, and committed MCP config. Generated or modified documents can persist in AFFiNE and may become visible to collaborators depending on workspace permissions and sharing state. Blob upload, cleanup, export, and publish/revoke workflows can expose files, generated content, or collaboration state beyond the current prompt.Yuque searches, user details, book metadata, document titles, document bodies, notes, resources, TOC data, group names, repo namespaces, slugs, and private deployment URLs can be sent to the MCP client and model. Created or updated Yuque content persists in the selected knowledge base and may be visible to collaborators according to Yuque permissions. Keep YUQUE_PERSONAL_TOKEN, YUQUE_GROUP_TOKEN, YUQUE_TOKEN, and private deployment URLs out of prompts, committed config, screenshots, public issues, and shared logs.Retrieved chunks can include private documents, product specs, policies, support content, internal procedures, historical project information, or customer-specific data. Retrieval queries, namespace IDs, tenant IDs, document chunks, citations, and tool outputs may be visible to the MCP client, model provider, Agentset logs, and application telemetry. Tenant IDs are useful for data segregation, but incorrect tenant or namespace configuration can expose the wrong knowledge base. Do not paste API keys, namespace IDs, tenant IDs, or retrieved private chunks into shared issue reports, screenshots, or repository files.Vault notes, headings, block references, frontmatter, tags, file metadata, outgoing links, search queries, command names, plugin status, and edit history may be exposed to the MCP client and model provider. API keys, local plugin endpoints, HTTP auth settings, path allowlists, logs, OpenTelemetry traces, and Docker environment variables can reveal private vault structure or credentials. Tag listing is vault-wide in upstream behavior and can reveal tag names outside narrowed read paths. Notes may contain personal journals, client work, credentials, meeting notes, research plans, health data, or other sensitive knowledge-base content.
Prerequisites
  • Node.js and npm for installing the affine-mcp-server package.
  • AFFiNE Cloud API token or approved self-hosted AFFiNE credentials.
  • AFFiNE base URL for the Cloud or self-hosted deployment.
  • Clear workspace scope and least-privilege tool profile before enabling write, admin, destructive, blob, or access-token tools.
  • Node.js 18 or newer and npx.
  • Yuque personal, group, or legacy API token with the minimum scope needed for the workflow.
  • Yuque Cloud account or approved private Yuque deployment base URL.
  • Read-only token for search and retrieval workflows whenever document or book writes are not required.
  • Agentset account or self-hosted Agentset deployment with a populated namespace.
  • Agentset API key with access to the namespace Claude should query.
  • Node.js 18.17 or newer for running the `@agentset/mcp` package.
  • Namespace ID selected with `--ns` or `AGENTSET_NAMESPACE_ID`.
  • Node.js 24 or newer, or Bun 1.3.11 or newer.
  • Obsidian vault with the Obsidian Local REST API community plugin enabled.
  • Local REST API key stored in the MCP client environment.
  • Stdio MCP client, or reviewed Streamable HTTP deployment with authentication.
Install
npm i -g affine-mcp-server
npx -y yuque-mcp
Run `npx @agentset/mcp --ns <namespace-id>` with `AGENTSET_API_KEY` set in the MCP server environment.
npx -y obsidian-mcp-server@latest
Config
{
  "mcpServers": {
    "affine": {
      "command": "affine-mcp",
      "env": {
        "AFFINE_BASE_URL": "<affine-base-url>",
        "AFFINE_API_TOKEN": "<affine-api-token>",
        "AFFINE_TOOL_PROFILE": "read_only"
      }
    }
  }
}
{
  "mcpServers": {
    "yuque": {
      "command": "npx",
      "args": ["-y", "yuque-mcp"],
      "env": {
        "YUQUE_PERSONAL_TOKEN": "<yuque-personal-token>",
        "YUQUE_BASE_URL": "<yuque-api-base-url>"
      }
    }
  }
}
{
  "mcpServers": {
    "agentset": {
      "command": "npx",
      "args": ["-y", "@agentset/mcp@latest", "--ns", "ns_xxx"],
      "env": {
        "AGENTSET_API_KEY": "agentset_xxx"
      }
    }
  }
}
{
  "mcpServers": {
    "cyanheads-obsidian": {
      "command": "npx",
      "args": ["-y", "obsidian-mcp-server@latest"],
      "env": {
        "MCP_TRANSPORT_TYPE": "stdio",
        "OBSIDIAN_API_KEY": "{obsidian-local-rest-api-key}",
        "OBSIDIAN_READ_ONLY": "true"
      }
    }
  }
}
Citations
ClaimUnclaimedUnclaimedUnclaimedUnclaimed
Open 4 picks in the interactive comparison tool

Signals

Loading live community signals…

More like this, weekly

A short, calm digest of reviewed Claude resources. Unsubscribe any time.