Post to Mastodon from Claude Code
Connect Claude Code to Mastodon with the Postscheduling.com MCP server and schedule Mastodon posts and threads from your terminal. No API key, and every post lands on a calendar you can check.
Cancel anytime · 7 days free
Connect Claude Code from the AI & API page
Use your API key to automate Postscheduling.com — hook up an AI agent over MCP, script it from the CLI, or call the REST API directly.
API keys
A key authenticates the MCP server, the REST API, and the CLI. Shown once — store it safely.
pb_live_…9c1eMCP client configuration
Connect the Postscheduling.com MCP server to your AI tool so it can schedule and publish for you.
Authentication
No key to manage — your tool signs in through Postscheduling.com.
Client
Run this — Claude Code opens a browser for you to sign in to Postscheduling.com.
claude mcp add --transport http postscheduling https://mcp.postscheduling.com/mcpCopyConnected apps
Tools you've signed in to Postscheduling.com from. Revoking cuts off their access immediately.
Set up in three steps
- 1
Connect Mastodon to Postscheduling.com
On your instance, open Preferences → Development, create an application with read and write access and copy its access token. Paste it with your instance URL on the Channels page.
- 2
Add the server
Run the command in your terminal. Claude Code registers Postscheduling.com as a remote MCP server over HTTP.
- 3
Ask for Mastodon posts and threads
Tell Claude Code what to post on Mastodon and when. Everything it schedules shows up in your Postscheduling.com calendar.
claude mcp add --transport http postscheduling https://mcp.postscheduling.com/mcpWhat to ask Claude Code
A few Mastodon requests that work well.
- Announce the release on Mastodon in plain language, with #opensource and the project hashtag.
- Write a Mastodon thread explaining the breaking change in this release and how to migrate.
- Cancel the Mastodon post scheduled for 3pm; the version number is wrong.
How Claude Code's posts work on Mastodon
- Length
- 500
- 500 characters per post, the default on most instances.
- Instances
- Any server
- Works with any server you've connected in Postscheduling.com: mastodon.social, fosstodon.org or your own.
- Threads
- Threads
- Ask for a thread and each post is published as a reply to the one before.
Tips for better Mastodon posts
- 1
- Mastodon readers expect plain, human posts. Ask for no marketing language.
- 2
- Use a few relevant hashtags at the end: they're how people find posts on Mastodon.
- 3
- Ask for a separate, shorter version for X rather than sharing the 500-character text.
Frequently asked questions
Does it work with my Mastodon instance?
Yes. Connect your account in Postscheduling.com with your instance URL and an access token, and the agent can post to it like any other channel.
Can it post to Mastodon and Bluesky together?
Yes. Ask for both, and it can send one post to both channels or a separate version to each.
Does Claude Code need my Mastodon password?
No. You connect Mastodon to Postscheduling.com once, and Claude Code signs in to Postscheduling.com, not to Mastodon. You can revoke Claude Code's access from the AI & API page at any time.
Can Claude Code delete my Mastodon posts?
No. It can list channels, find files in your media library, create drafts and scheduled posts, list the queue and cancel a scheduled post. There's no tool for deleting anything.
Related
- Claude Code + X
Post to X from Claude Code.
- Claude Code + LinkedIn
Post to LinkedIn from Claude Code.
- Claude Code + Bluesky
Post to Bluesky from Claude Code.
- Claude + Mastodon
Post to Mastodon from Claude.
- Cursor + Mastodon
Post to Mastodon from Cursor.
- Mastodon scheduler
Posts and threads on any instance, up to 500 characters.
Ready to get started?
Connect Claude Code in a minute. It writes and schedules your Mastodon posts, and you see every one in your calendar.
Cancel anytime · 7 days free