Mastodon MCP server: let Claude or any agent post to your Mastodon account
https://postwire.io/api/mcp to Claude, ChatGPT, Cursor or any MCP client as a remote MCP server, paste your Mastodon server's address and an access token once, and the agent publishes a post, a thread or up to 4 images or videos with alt text using post_to_social, or queues it with schedule_post. It works with mastodon.social and with any other instance, and it takes about two minutes: the token comes from your own Mastodon preferences, with permission to post and nothing else. The free plan includes Mastodon and the MCP server: 1 business, 20 posts a month, 5 AI drafts a day, 2 networks per post, no card.PostWire reads your server's own character limit when you connect, counts a link as 23 characters the way Mastodon does, and generate_posts writes the way the fediverse expects: no marketing-speak, CamelCase hashtags and alt text on every image.
Updated . Written from PostWire's own code; vendor prices read on Oct 13, 2026. Live networks: TikTok, Instagram, YouTube, LinkedIn (personal profiles), Facebook Pages, Bluesky, Mastodon, Telegram, Discord, and X on paid plans.
Set it up and post, step by step
- Add PostWire's MCP server to your agent
In Claude, open PostWire in the connector directory and press Connect. Anywhere else, add the remote server
https://postwire.io/api/mcp(Streamable HTTP; OAuth sign-in or an API key) — in Claude Code:claude mcp add --transport http postwire https://postwire.io/api/mcp. Cursor, VS Code, Windsurf, Codex and Gemini CLI configs: MCP client configs. - Sign in with your email
The first time the agent uses a PostWire tool, a sign-in window asks for your email and a 6-digit code; that also creates a free PostWire account if you have none. No password and no card. Agents that cannot do OAuth send an API key instead (dashboard → API & MCP → Copy key).
- Create an access token in Mastodon
On your Mastodon server, open Preferences → Development → New application, name it "PostWire", tick only
write:statusesandwrite:media, save, and copy Your access token. With those two scopes the token can post and upload media; it cannot read your timeline or your messages. Deleting the application in Mastodon disconnects PostWire. - Connect Mastodon
Ask "connect my Mastodon".
create_connect_linkgives you a one-hour link; choose Mastodon there and paste your server's address (https://mastodon.social, or your own instance) and the token. There is no sign-in screen. Before saving, PostWire asks your server whether the token is valid, so a wrong token is refused on that page with the fix, and it reads the server's post length limit to measure your posts against it. - Let PostWire write the post
"Write a Mastodon post about our open-source release, and the LinkedIn post for it."
generate_postsreturns one draft per network and publishes nothing. Mastodon's draft stays within 500 characters, is community-first with no marketing-speak, and carries 2 to 4 hashtags in CamelCase (#OpenSource, which screen readers can read out). When the idea is too long for one post, or you ask for one, it comes back as a thread. - Publish, or schedule it
After you approve, the agent calls
post_to_social(orschedule_postwith arun_attime, or"next_slot"). Images and videos go inmedia, each with its ownalt;threadholds the posts after the first, andfirst_commentis a reply under the last one, a good place for the link:{ "name": "post_to_social", "arguments": { "platforms": ["mastodon"], "per_platform": { "mastodon": { "text": "We open-sourced our scheduler today. It runs on one small server and a Postgres database. #OpenSource #SelfHosted", "thread": ["What took longest was daylight saving: a post set for 02:30 on the night the clocks change has to go out exactly once."], "first_comment": "Code and install notes: https://example.com/repo" } }, "media": [ { "url": "https://postwire.io/m/…/calendar.jpg", "alt": "A weekly calendar with six posts queued" } ] } } - Open the post, and see how it did
The result carries the post's link on your server and, for a thread, the link of every post in it.
get_post_statusreturns them again later, andget_post_performanceranks your Mastodon posts against your own median by favourites, boosts and replies, the numbers Mastodon reports.list_scheduled_postsshows what is queued andcancel_scheduled_postremoves one before it goes out.
An image or a video from your phone or laptop gets there through create_upload_link: a 24-hour page where you pick the file (up to 100 MB on the free plan and 1 GB on paid plans), then get_uploaded_file returns its media_url. The same post from your own code: POST /api/post with {"platforms": ["mastodon"], "text": "…"} and your API key, or the PostWire node in n8n. Prefer to set it up by hand first? Open the dashboard, connect the account under Accounts and copy your key under API & MCP.
Mastodon MCP servers for posting, side by side
Each vendor's endpoint, sign-in and price, read on its own Mastodon MCP or plans page on Oct 13, 2026.
| Server | Endpoint | Sign-in | Free to start | Cheapest paid plan | Writes the post |
|---|---|---|---|---|---|
| PostWire | https://postwire.io/api/mcp | OAuth 2.1 or API key | Free plan: 1 business, 20 posts a month, 5 AI drafts a day, 2 networks per post, no card | $9/mo — 3 businesses, every network in each post | Yes — generate_posts writes the Mastodon post and each other network's from one idea |
| Upload-Post | mcp.upload-post.com/mcp | OAuth or API key | Free plan: 10 uploads a month | $24/mo — 5 profiles | Not listed |
Checked on Oct 13, 2026 (2026-10-13) on each vendor's own pricing or docs page, linked in the first column and below. Monthly billing in USD unless noted. "Not listed" means we could not find it on their page, not that it is missing.
Where PostWire is ahead
- The post is written for Mastodon, and so is every other network's version:
generate_poststurns one idea into a community-first Mastodon post with CamelCase hashtags, a Bluesky post and a LinkedIn post in one call. - 20 posts a month on the free plan, without a card. Upload-Post's free plan has 10 uploads a month.
- Threads and a first comment in the same call: the posts after the first go in
thread, the link infirst_comment, and the result returns the link of every post. - Your instance's own character limit is respected: it is read when you connect, and links are counted as 23 characters, so a post that fits on your server is not cut to 500.
- The token is tested before it is saved, and again later: a wrong token is caught when you connect, not when a scheduled post was due.
- Mastodon plus nine more networks in the same call: TikTok, Instagram, YouTube, LinkedIn, Facebook Pages, Bluesky, Telegram, Discord, and X on paid plans.
- Upload-Post — Mastodon MCP server (endpoint, API key header, tools, "works with any Upload-Post plan, including the free tier"): www.upload-post.com/mcp/mastodon/
- Upload-Post — LinkedIn MCP server (the same server: "Sign in with OAuth or paste an Upload-Post API key"): www.upload-post.com/mcp/linkedin/
- Upload-Post plans (llms-full.txt: Free 10 uploads a month; Basic $24, 5 profiles): www.upload-post.com/llms-full.txt
Mastodon's rules the agent works within
- Your server's own length limit: 500 characters on mastodon.social, more on many instances. PostWire reads the limit your server publishes when you connect and measures each post against it; without one, it uses 500.
- A link counts 23 characters, whatever its real length, as Mastodon counts it. So a long URL does not push a post over the limit.
- Up to 4 attachments, each with alt text of up to 1,500 characters. A fifth is refused with a message that says so.
- Video is waited for: Mastodon processes a video after the upload and refuses a post that attaches it too early. PostWire waits for the processing to finish, up to 45 seconds, before it posts.
- Threads of up to 10 posts: each post is a reply to the one before. If a later post is refused, the earlier ones stay published and the result lists the ones that did not go out. A reply is never posted twice.
- Any instance, over https: the server address has to start with
https://and be a public server, so your token never travels unencrypted. - Revoked tokens are noticed: PostWire's connection check asks your server whether the token still belongs to an account; if you deleted the application, the dashboard asks you to reconnect before a scheduled post is due.
Source: PostWire's Mastodon publisher, read Oct 13, 2026.
What it does not do
PostWire publishes and schedules your own posts on Mastodon, at your account's default visibility. It does not read your timeline or notifications, boost, favourite, follow or send direct messages, it does not add content warnings or polls, and Mastodon does not report views, so there are none to show.
Questions people ask
Is there an MCP server that posts to Mastodon?
Yes. PostWire's hosted MCP server (https://postwire.io/api/mcp) publishes posts, threads, images and videos to your Mastodon account from Claude, ChatGPT, Cursor or any MCP client, and can schedule them. It is in Claude's connector directory.
Does it work with my own instance?
Yes. You paste your server's address, so it works with mastodon.social and with any other Mastodon instance that is reachable over https. PostWire reads that server's own character limit when you connect.
Which permissions does the access token need?
Two: write:statuses and write:media. Create it under Preferences → Development → New application. With those scopes the token can post and upload media and cannot read your timeline or messages; deleting the application disconnects PostWire.
Does it work with Claude and Claude Code?
Yes. In Claude, press Connect on PostWire in the connector directory and sign in with your email. Claude Code adds it with: claude mcp add --transport http postwire https://postwire.io/api/mcp. Then ask it to connect your Mastodon.
Can it post a thread, or images with alt text?
Yes. A thread is the first post plus up to 9 more in thread, each a reply to the one before. Up to 4 images or videos go in media as { url, alt }, with alt text of up to 1,500 characters each.
Can the agent schedule Mastodon posts?
Yes. schedule_post takes a run_at time up to 365 days ahead, or "next_slot" for your next free queue slot. The free plan keeps 3 posts waiting in the queue at once.
How much does it cost?
The free plan includes Mastodon and the MCP server: 1 business, 20 posts a month, 5 AI drafts a day, 2 networks per post, no card. Starter is $9 a month for 3 businesses and Pro $29 for 10, with every network in each post; paid plans have a 14-day refund.
Try it on one business, free.
The free plan is 1 business, 20 posts a month, 5 AI drafts a day (about 20 a month) and 2 networks per post — every network connects free, no card, no time limit. Paid plans start at $9 a month and have a 14-day refund; Pro can be tried free for 7 days, with a card at checkout and nothing charged that day.