X (Twitter) Marketing Skills for Claude Code and Codex
Part of the linkedin-skills family (400+ stars). Same voice engine and approve-before-publish flow, now for X. Also available for Instagram · YouTube · TikTok · Threads · Facebook.
9 skills that turn Claude Code and Codex into your X (Twitter) content team. They write tweets and threads in your voice with corpus-validated hooks, extract the hook from any viral tweet, draft replies and quote tweets, and plan a week of content. Every draft gets the AI tells stripped and waits for your approval before anything publishes. No coding required.
Once installed, just ask Claude Code or Codex things like:
- "Write a tweet about [topic]"
- "Turn these notes into a thread"
- "What's working in my niche on X right now? (reads real data via Apify)"
- "Rewrite this tweet so it doesn't sound like AI"
The right skill activates automatically. Then you review and approve.
Install
Pick whichever way you use Claude Code or Codex:
Codex CLI
codex plugin marketplace add sergebulaev/x-skills
codex plugin add x-skills@x-skills
To test a local clone before publishing changes:
git clone https://github.com/sergebulaev/x-skills.git
cd x-skills
codex plugin marketplace add .
codex plugin add x-skills@x-skills
claude.ai (web)
- Open https://claude.ai/code
- Go to Skills in the sidebar
- Click Add from GitHub
- Paste:
sergebulaev/x-skills
- Done. The skills activate automatically when you ask about X or Twitter.
Claude Desktop (Mac / Windows)
- Open Claude Desktop
- Open Settings (gear icon)
- Go to Skills
- Click Add from GitHub
- Paste:
sergebulaev/x-skills
- Done. Start a new conversation and ask Claude to write a tweet.
Claude Code (CLI / VS Code / JetBrains)
/plugin marketplace add sergebulaev/x-skills
/plugin install x-skills@x-skills
Or clone the repo and open it as your working directory:
git clone https://github.com/sergebulaev/x-skills.git
cd x-skills
OpenClaw
- Open your OpenClaw working directory
- Clone the skills into it:
git clone https://github.com/sergebulaev/x-skills.git
- In OpenClaw settings, add this to your system prompt:
You have X (Twitter) marketing skills in ./x-skills/.
For any X (Twitter) task, read the relevant skills/*/SKILL.md first.
Use lib/url_parser.py for URL parsing and lib/publora_client.py for publishing.
- Done. Ask OpenClaw to write a X (Twitter) post.
Hermes Agent
Hermes Agent (Nous Research) follows the agentskills.io open standard and loads skills/*/SKILL.md directly. Clone the bundle into your Hermes skills folder:
git clone https://github.com/sergebulaev/x-skills.git ~/.hermes/skills/x-skills
Coming from OpenClaw? hermes claw migrate imports these skills automatically. Then call /<skill-name> from any of your Hermes chat surfaces.
Any agent (skills CLI)
One command that works across Claude Code, Codex, Cursor, and any other agent that reads SKILL.md files:
npx skills add sergebulaev/x-skills
Found this useful? Star the repo. Curated Claude Code and Codex directories rank and gate by star count, so a star is what makes these skills findable for the next person. It is the only thing we ask. No signup, no email.
What you can do
Once installed, just ask Claude Code or Codex for help with X. The right skill activates automatically.
Write a tweet:
"Write me a tweet about why most AI agents fail on retries, not reasoning. Make it sharp."
Turn an idea into a thread:
"Turn my notes into a thread on how we cut agent latency from 9s to 2.1s."
Check a draft before posting:
"Audit this tweet for AI tells and the 280-char limit: [paste your text]"
Reverse-engineer a viral tweet:
"What hook does this thread use? https://x.com/someone/status/123 (I'll paste the text)"
Reply to a creator:
"Draft a reply to this tweet, I want to add value not dunk: https://x.com/someone/status/123"
Plan your week:
"Plan a week of X content. I'm building an AI agent in public for indie devs."
Every skill shows you a draft first and waits for your OK. Nothing gets posted without your approval.
The 9 skills
| Skill | What it does |
|---|
| Post Writer | Drafts a single tweet (or short auto-thread) using a 2026 X hook formula picked by goal: replies, reposts, likes, or bookmarks. Respects the 280-char limit (25,000 on Premium) |
| Thread Builder | Builds long-form tweetstorms (listicle, story, curiosity-gap, how-I teardown). Structures tweet 1 as a promise plus open loop, front-loads value, closes for the repost |
| Humanizer | Removes the AI tells human readers react to: 2026 AI vocabulary scored by density per tweet, reveal bridges, staccato fragment stacks, stacked triads, performed sincerity; caps em dashes at one per tweet instead of banning them, and never forces rhythm on a single tweet (uniform rhythm wins on short posts). Does not promise to beat detectors (no edit reliably does). Bundles a --mode audit pre-publish check (280-char fit, hook, hashtags, link placement) |
| Hook Extractor | Reverse-engineers the hook from any viral tweet or thread. Maps it to one of the 11 X formulas and returns a blank template you can fill |
| Reply Drafter | Drafts a reply or a value-add quote tweet for any tweet URL. Decides reply vs quote tweet. X has no LinkedIn-style thread flattening, so a reply is just a tweet |
| Content Planner | Creates a weekly plan with a single-to-thread mix, per-day hooks, posting times, daily reply targets, and a goal-mix balance check |
| Repurposer | Turns content from another platform (LinkedIn post, blog, YouTube script, newsletter) into a native X tweet or thread: re-hooks for the no-fold first line, refits to 280 or a thread, strips off-platform artifacts, runs the humanizer |
| Profile Optimizer | Audits and rewrites your X profile for 2026: bio (160 chars), searchable display name, header, pinned tweet, and link. Turns a default profile into one that converts visitors into followers |
| Audience Insights | Reads your X audience and niche from real Apify data: your/competitor tweets ranked by engagement, the pattern behind the winners, the repliers on a tweet (X gates likers), and a niche scan. No login |
How threads work on X
X caps a standard tweet at 280 characters (emoji count as 2 each), or 25,000 on X Premium. For anything longer, you build a thread. Doing that on the native X API means posting tweet 1, capturing its id, posting tweet 2 as a reply to it, and handling partial failures.
This bundle hands the whole chain to Publora. You write the thread as one block (or split it with ---), and Publora auto-splits it into a numbered (1/N) thread at sentence boundaries, reserves room for the marker, and posts it in one call. The Thread Builder and Post Writer skills use this on approval.
Optional: auto-post with Publora
By default, the skills draft content for you to copy-paste into X. If you want Claude Code or Codex to publish tweets and threads directly, connect Publora. It takes about 2 minutes.
What is Publora?
Publora is a publishing API that turns one create-post call into a full X thread (and can cross-post the same content to LinkedIn, Threads, and more).
Publora also ships official MCP skills (npx skills add publora/skills): one skill per platform, covering the publish side only. This bundle is the layer above them, adding the reading, the writing craft and the approval flow.
Setup (2 minutes)
Step 1. Sign up at https://app.publora.com/signup (free)
Step 2. Connect X: click Channels in the left sidebar, then Add Channel, pick X / Twitter, authorize.
Step 3. Find your Platform ID: go to Channels, click your X account. The ID looks like twitter-123456789. Copy the whole thing including twitter-.
Step 4. Get your API key: click Settings (gear icon, bottom-left), then API, then Create Key. Copy the sk_... string.
Step 5. Create a file called .env in the x-skills folder:
PUBLORA_API_KEY=sk_paste_your_key_here
X_PLATFORM_ID=twitter-paste_your_id_here
If you cloned the repo, copy the template instead:
cp .env.example .env
Then open .env and replace the placeholders with your real values.
Step 6. Install two small Python packages:
pip install requests python-dotenv
Step 7. Test it. Ask Claude Code or Codex:
"Schedule a test tweet via Publora 24 hours from now: 'testing the API connection, will cancel in dashboard'."
If Publora returns a postGroupId, you're set. Cancel the post in the Publora dashboard before the scheduled time. If you get HTTP 401, your API key is wrong. If you get a Invalid platform ID format error, your X_PLATFORM_ID is wrong. See Troubleshooting.
Note on replies: X has no reply endpoint on Publora, so the Reply Drafter always returns its draft as a copy-paste block for you to post yourself. Single tweets and threads auto-publish.
Optional: generate illustrations with Pixfaro
A tweet with a visual gets more engagement. The Post Writer can generate an inline image or a quote-card of your hook and attach it automatically when publishing. Without a key it drafts the image prompt and asks you to generate it yourself, so nothing breaks.
Pixfaro is a single image API over multiple models (from flux-schnell at $0.004 to gpt-5-image). It composites your handle, brand color, or logo onto the image as a pixel-exact overlay, so a cheap base model still renders crisp text on a quote-card. Pull those brand fields from your Voice & Brand Profile (section 6) and every asset stays on-brand.
Setup: drop PIXFARO_TOKEN=pf_live_... into your .env. The thin client at lib/pixfaro_client.py and the wrappers lib.illustrate(prompt, kind="wide") / lib.refine(image_id, instruction) return a hosted URL that flows straight into lib.publish(..., media_urls=[url]). refine edits a prior image by its id (cheaper than regenerating); results carry cost, balance_after, and a premium flag so the skills never quietly spend on a pricey model.
Voice rules
Every skill follows these rules automatically:
- Em dashes capped at one per tweet. The character stopped being a tell in 2026; the density is.
- Capitalize names. Always. Lowercase a brand reads as careless.