Install
$ agentstack add skill-floomhq-moto-post-to-x ✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.
Security review
✓ PassedNo issues found. Passed automated security review. · v0.1.0 How review works →
- ✓ Prompt-injection patterns
- ✓ Secret / credential exfiltration
- ✓ Dangerous shell & filesystem operations
- ✓ Untrusted network calls
- ✓ Known-malicious package signatures
What it can access
- ✓ Network access No
- ✓ Filesystem access No
- ✓ Shell / process execution No
- ● Environment & secrets Used
- ✓ Dynamic code execution No
From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.
About
Post to X (Twitter)
Cross-post LinkedIn content to X, adapting text and attaching media.
Prerequisites
X API credentials must be set in ~/.claude/skills/post-to-x/.env:
X_API_KEY=your_api_key
X_API_SECRET=your_api_secret
X_ACCESS_TOKEN=your_access_token
X_ACCESS_TOKEN_SECRET=your_access_token_secret
These come from the X Developer Portal (developer.x.com). You need a project with "Read and Write" permissions. The access token must be generated with read+write scope.
Workflow
Step 1: Find the LinkedIn post content
Look for the post text in the current directory or the directory the user references:
post-copy-final.txtorpost-copy*.txtfor text*.mp4,*.mov,*.webmfor video*.jpg,*.jpeg,*.pngfor imagesthumbnail*.jpg,thumbnail*.pngfor thumbnail images
If the user provides text directly, use that instead.
Step 2: Adapt the text for X
LinkedIn posts are long-form. X has character limits:
- 280 characters for text-only posts
- 280 characters for posts with media (text portion)
- Threads: up to 25 tweets, each 280 chars
Strategy:
- Extract the core hook/message from the LinkedIn post
- Create a concise X version (aim for 200-250 chars to leave room for links)
- Remove LinkedIn-specific CTAs ("DM me", "Comment below")
- Replace with X-appropriate CTAs if needed ("Link in replies", thread format)
- Keep hashtags minimal (0-2 max, only if truly relevant)
- No emojis unless the user explicitly requests them
If the post is too rich for a single tweet, propose a thread (2-4 tweets max).
Always show the adapted text to the user for approval before posting.
Step 3: Upload media (if any)
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py upload-media
This returns a media_id to use in Step 4.
For video: the script handles chunked upload (INIT, APPEND, FINALIZE, STATUS polling). For images: simple upload.
Size limits:
- Images: 5 MB (JPEG, PNG, GIF, WEBP)
- Video: 512 MB, up to 2:20 duration (MP4 with H.264 video, AAC audio)
- GIF: 15 MB
Step 4: Post the tweet
# Text only
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py post --text "Your tweet text"
# With media
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py post --text "Your tweet text" --media-ids "media_id_1,media_id_2"
# Thread
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py thread --texts "Tweet 1|||Tweet 2|||Tweet 3"
# Thread with media on first tweet
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py thread --texts "Tweet 1|||Tweet 2" --media-ids "media_id_1"
# Dry run (show what would be posted without actually posting)
python3 ~/.claude/skills/post-to-x/scripts/post_to_x.py post --text "Your tweet" --dry-run
Step 5: Verify
The script prints the tweet URL on success. Confirm the post looks correct.
Text Adaptation Examples
LinkedIn (long):
I genuinely stopped using PowerPoint.
Spending days aligning boxes feels insane when you can build a whole app in the same time.
So I made an app for building slides.
Three prompts. Full deck. 2 minutes.
No Figma. No templates. Just prompts.
Open source. Free forever.
DM "DECK" if you want early access.
X (short):
I stopped using PowerPoint and built an app that generates full slide decks from prompts.
3 prompts. Full deck. 2 minutes.
Open source, free forever.
github.com/yourorg/yourrepo
Error Handling
- 401 Unauthorized: Check API credentials in
.env - 403 Forbidden: App needs "Read and Write" permissions, not just "Read"
- 413 Payload Too Large: Video exceeds 512 MB or image exceeds 5 MB
- 429 Rate Limited: Wait and retry (script handles this automatically)
- Media processing failed: Video codec/format issue, try re-encoding with ffmpeg
Rules
- Always show the adapted text to the user before posting. Never auto-post.
- No emojis unless user requests them.
- No em dashes. Use commas, semicolons, colons.
- Keep it punchy. X rewards brevity. Cut ruthlessly.
- Dry run first if unsure. Use
--dry-runflag.
Source & license
This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.
- Author: floomhq
- Source: floomhq/moto
- License: MIT
- Homepage: https://github.com/floomhq/moto#readme
Install and usage instructions live in the source repository linked above.
Reviews
No reviews yet — be the first.
Write a review
Versions
- v0.1.0 Imported from the upstream source.