Agent skill · writing content · jimliu

baoyu-post-to-x

Posts content and articles to X (Twitter). Supports regular posts with images/videos and X Articles (long-form Markdown). In Codex, honor explicit requests for the Codex Chrome plugin/@chrome by using the Chrome Extension workflow; otherwise use Chrome Computer Use when available and fall back to real Chrome CDP scripts only when allowed. Use when user asks to "post to X", "tweet", "publish to Twitter", or "share on X".

Why this skill is useful

Adds multiple executable scripts for posting to X (Twitter) that automate interactions not covered in public documentation.

What it needs

Requires bun, npx installed locally. Requires twitter account access. About 10k tokens when loaded. Last updated 2026-07-04. 24,677 stars on the source repository.

What this skill does

Post to X (Twitter) Posts text, images, videos, and long-form articles to X via a real Chrome browser. In Codex, do not conflate these browser paths: Codex Chrome plugin / @chrome / Chrome Extension: use the bundled chrome:Chrome skill and its Node REPL browser client. This is required whenever the user says "Codex Chrome plugin", "Codex 自带的 Chrome 插件", @chrome, or similar. Chrome Computer Use: use mcpcomputeruse. against the visible Google Chrome UI only when the user asks for Computer Use or no Chrome-plugin preference is stated and Computer Use is available. CDP script mode: use only as a fallback when the selected mode is unavailable or the user explicitly asks for CDP/script mode. Script Directory Important: All scripts are located in the scripts/ subdirectory of this skill. Agent Execution Instructions: 1. Determine this SKILL.md file's directory path as {baseDir} 2. Script path = {baseDir}/scripts/<script-name>.ts 3. Replace all {baseDir} in this document with the actual path 4. Resolve ${BUNX} runtime: if bun installed → bun; if npx available → npx -y bun; else suggest installing bun Script Reference: Script Purpose -------- --------- scripts/x-browser.ts Regular posts (text + images), CDP fallback scripts/x-video.ts Video posts (text + video), CDP fallback scripts/x-quote.ts Quote tweet with comment, CDP fallback scripts/x-article.ts Long-form article publishing (Markdown), CDP fallback scripts/md-to-html.ts Markdown → HTML conversion scripts/copy-to-clipboard.ts Copy content to clipboard scripts/paste-from-clipboard.ts Send real paste keystroke scripts/check-paste-permissions.ts Verify environment & permissions Execution Mode Selection (Required) Choose exactly one mode before interacting with X: 1. If the user explicitly asks for the Codex Chrome plugin, @chrome, the Chrome extension, or "Codex 自带的 Chrome 插件", use Codex Chrome Plugin Mode. Do not call Computer Use first. 2. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills jimliu/baoyu-post-to-x

View the source on GitHub

Browse the @skills marketplace