Skip to main content
MCP server CX Codex

activitypub-mcp — Claude Code MCP server: what it does, how to install

Connect LLMs to the Fediverse. It lets assistants inspect Mastodon, Misskey, and ActivityPub actors in read-only mode or publish posts.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env ACTIVITYPUB_ENABLE_WRITES=<ACTIVITYPUB_ENABLE_WRITES> --env LOG_LEVEL=<LOG_LEVEL> --transport stdio activitypub-mcp -- npx -y activitypub-mcp
Open on GitHub

What activitypub-mcp does

The server bridges language models with federated social platforms. By default, it operates in read-only mode. The model can inspect actors, fetch outboxes, and review trending topics without risking unwanted mutations from untrusted posts.

Actor lookups rely on standard ActivityPub endpoints, so instances like Lemmy or PeerTube work immediately. Search tools and trending lists require Mastodon or Misskey REST APIs. Mutations stay blocked until you set ACTIVITYPUB_ENABLE_WRITES=true.

The package requires Node.js 20 or higher. Running authentication stores credentials locally in ~/.config/activitypub-mcp/accounts.json, supporting OAuth and MiAuth flows.

What it helps with

  • Inspect profiles and retrieve outbox posts across ActivityPub servers
  • Check trending hashtags and public posts on Mastodon or Misskey
  • Publish notes, replies, and reactions after enabling write tools
  • Manage notifications and bookmarks directly from the model session

Example prompts for the agent

  • Show trending posts and hashtags from mastodon.social.
  • Fetch recent notifications for my authenticated account.

How to install activitypub-mcp

Platform CLI

claude mcp add --env ACTIVITYPUB_ENABLE_WRITES=<ACTIVITYPUB_ENABLE_WRITES> --env LOG_LEVEL=<LOG_LEVEL> --transport stdio activitypub-mcp -- npx -y activitypub-mcp

Replace <…> with your own values

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about activitypub-mcp

How do I install activitypub-mcp in Claude Code?

Run claude mcp add activitypub-mcp -- npx -y activitypub-mcp in your terminal. You must have Node.js 20 or newer installed.

What does activitypub-mcp do?

It exposes tools for assistants to query Fediverse actors, read posts, and fetch server trends. It also supports posting and managing reactions when write mode is active.

Why are write tools turned off out of the box?

Disabling mutations prevents Fediverse content from tricking the agent into modifying your account. You must pass ACTIVITYPUB_ENABLE_WRITES=true to enable posting.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor