Post to social media from Claude Code

By Abhishek BR · Published · 7 min read

You already ship from Claude Code. It can also write the launch post, turn the changelog into a thread, and schedule both to X, LinkedIn, Threads and Bluesky, without leaving the terminal. Here is the setup, two ways, and the prompts that work.

Short answer: install the social0 CLI, log in with an API key, and tell Claude Code it can use it. Claude Code has a shell, so a CLI is the simplest tool for it: it runs social0 schedule … like any other command. If you prefer MCP, add Social0's hosted MCP server with one claude mcp add command instead.

This is the developer version of posting from ChatGPT or Claude. The difference is context: Claude Code can read your git log, diff and changelog, so it writes posts about what you actually shipped.

  1. Connect your accounts in Social0 under Connections (OAuth stays in the dashboard).
  2. Create an API key under Developer → API keys.
  3. Install and log in:
npm install -g social0
social0 login        # paste sk_live_… (input is masked)
social0 accounts     # lists your connected accounts with short IDs

That's all the setup. Claude Code can now run commands like these when you ask it to:

social0 publish -c "v2.3 is out: faster exports and dark mode" -p twitter linkedin
social0 schedule -c "Launch day tomorrow" -p twitter threads bluesky -t "tomorrow 9am"
social0 upload ./screenshot.png --json   # returns a media ID to attach with -m

Times like tomorrow 9am, next monday or in 2 hours use your local time. The CLI page has every command.

Tell Claude Code how you post

Add a few lines to your project's CLAUDE.md so every session knows the rules without you repeating them:

## Social posts
- Use the `social0` CLI to post. Run `social0 accounts` first.
- Never publish without showing me the exact text first.
- Default: schedule with `-t`, don't publish immediately.
- X max 280 chars; LinkedIn can be longer; no hashtags on X.

Option B: MCP

If you'd rather Claude Code use structured tools than shell commands, add Social0's hosted MCP server:

claude mcp add --transport http social0 https://mcp.social0.app/mcp

Then run /mcp inside Claude Code and sign in to Social0 when the browser opens. No API key goes in a config file; the sign-in creates a key you can revoke in the dashboard. Ask "show my connected Social0 accounts" to check it works.

CLI or MCP in Claude Code?
CLIMCP
Setupnpm install + API keyOne claude mcp add + browser sign-in
Local files (screenshots, videos)Upload straight from diskPass a public URL or base64 data
Also works in CI and scriptsYes, same commandsNo
Best forDevelopers who live in the terminalStructured tools, no global install

Prompts that work

From Claude Code to CI

Once a prompt works well, you can make it automatic. The CLI reads SOCIAL0_API_KEY from the environment, so the same social0 publish command runs in a GitHub Action on every release. Social media automation for developers covers release pipelines and webhooks, and the n8n guide covers no-code workflows.

Install the CLI and let Claude Code post your launches. Free plan includes the CLI, API and MCP. Use Social0 with Claude

Frequently asked questions

Can Claude Code post to social media?

Yes. Give it a tool to call: a CLI such as social0, which it runs in its shell, or an MCP server added with claude mcp add. It can then publish or schedule posts to the accounts you connected.

Should I use the CLI or MCP with Claude Code?

Claude Code has a shell, so the CLI is the simplest option and handles local files directly. MCP is a good fit if you want structured tools without installing a global npm package.

Which networks can Claude Code post to through Social0?

X, LinkedIn, Instagram, TikTok, YouTube, Threads, Bluesky, Facebook and Pinterest, as long as the account is connected in Social0.

Is it safe to give Claude Code access to my social accounts?

It never sees your social passwords: accounts are connected in the Social0 dashboard, and Claude Code only gets an API key you can revoke at any time. Add a CLAUDE.md rule that it must show you the post before publishing.

Can Claude Code schedule posts for later?

Yes. With the CLI, use social0 schedule with -t and a time such as "tomorrow 9am". Through MCP, ask it to schedule for a date and time.

Related

All guides · Social0 · Pricing