New MCP server: let ChatGPTClaudeClaude CodeCodexCursorOpenClaw or any AI agent schedule your posts See how it works

Claude Code + Mastodon

Post to Mastodon from Claude Code

Through iHatePosting, Claude Code can publish posts with pictures or video to your Mastodon account. Register iHatePosting in Claude Code with a single terminal command and a browser sign-in, then ask it for the post you want.

Setup takes about a minute. A post can hold up to 500 characters.

MastodonClaude Code15 networks

Posting to Mastodon from Claude Code

Add iHatePosting to Claude Code once, connect Mastodon, and then describe the post. Setup takes about a minute.

Step 1

Add iHatePosting to Claude Code once

Register iHatePosting in Claude Code with a single terminal command and a browser sign-in. Then connect Mastodon in iHatePosting if you have not already.

terminal
claude mcp add --transport http ihateposting https://app.ihateposting.com/mcp/oauth
Step 2

Ask for the Mastodon post

Describe the post in plain language. Claude Code writes it, applies the settings and schedules it.

Claude Code
> Post a short note about the new release on Mastodon tomorrow at 9:00. Claude Code: Done. Scheduled on Mastodon.

What Claude Code can do on Mastodon

On Mastodon, Claude Code can publish posts with pictures or video to your Mastodon account.

Posts

Publish text posts to your account on mastodon.social, the server iHatePosting connects to.

Threads

Ask for a thread and the text is split into connected posts.

Media

Attach pictures or video from your media library.

Scheduling

Choose a date and time for the post.

How Claude Code gets a post onto Mastodon

You say what you want and Claude Code makes the calls. A typical conversation goes like this.

Find your Mastodon channel

Which Mastodon accounts do I have in iHatePosting?

What happens

  • Claude Code lists your channels and finds Mastodon
  • It also reads the channel's rules and settings

Compose your content

Split this article summary into a Mastodon thread and schedule it for Friday at 11:00.

What happens

  • Claude Code drafts the text for Mastodon
  • It uploads any media you mention

Schedule and publish

Yes, schedule it for tomorrow at 9:00.

What happens

  • Claude Code schedules the post in iHatePosting
  • iHatePosting publishes it to Mastodon at that time

Mastodon settings reference

Mastodon needs nothing beyond the text, the media and the time.

FieldTypeRequiredDescription
(none)-NoNo extra settings: Claude Code sends the text, the media and the time

Mastodon requests to try in Claude Code

A post

Post a short note about the new release on Mastodon tomorrow at 9:00.

A thread

Split this article summary into a Mastodon thread and schedule it for Friday at 11:00.

A picture

Post diagram.png on Mastodon with a one-sentence explanation.

Mastodon limits and gotchas to know

A few of Mastodon's rules shape how Claude Code writes your request, so it helps to know them.

  • A post can hold up to 500 characters.
  • The channel has no extra settings to choose.

What is Claude Code?

Claude Code is Anthropic's agentic tool for software work. It lives in a terminal, with extensions for popular editors, understands the code around it, runs commands and can call MCP tools such as iHatePosting.

That makes it a natural place to announce a release: it can read the changelog, write the copy and schedule it in iHatePosting without you leaving the project.

How iHatePosting works with Claude Code

Once connected, iHatePosting hands Claude Code its tools: your channels, posts, media and each channel's settings (14 tools in all). Claude Code calls them while you describe what you want.

  • iHatePosting MCP server (sign in): claude mcp add --transport http ihateposting https://app.ihateposting.com/mcp/oauth
  • iHatePosting plugin: /plugin marketplace add iHatePostingOrg/iHatePosting-Agent
  • iHatePosting skill (command line): npx skills add iHatePostingOrg/iHatePosting-Agent
Set up Claude Code
# iHatePosting MCP server (sign in) claude mcp add --transport http ihateposting https://app.ihateposting.com/mcp/oauth

Mastodon and the other platforms Claude Code reaches

Ask for Mastodon and other channels in a single message; every channel still applies its own settings.

Frequently asked questions

Start free for 30 days

Register iHatePosting in Claude Code with a single terminal command and a browser sign-in, connect Mastodon in iHatePosting, then ask Claude Code for the post in plain language. It schedules the post and iHatePosting publishes it at the time you set.

Hand your Mastodon posts to Claude Code

Start free for 30 days.