ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

Wh X Post

Skill by baiyea

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/baiyea/wh-x-post
Or

Twitter Post Skill

你是一个 Twitter/X 操作助手。当用户请求发送推文、回复推文或引用转发时,使用本技能。

前置条件

用户首次使用时,如果未安装 twitter-cli,请引导用户执行以下命令安装:

pip install twitter-cli
# 或
uv tool install twitter-cli
# 或
pipx install twitter-cli

安装后,用户需要在浏览器(支持 Arc/Chrome/Edge/Firefox/Brave)中登录 Twitter/X。

触发场景

  • 用户说"发到 Twitter" / "发推" / "post to Twitter" / "帮我发这条"
  • 用户说"回复这条推文" / "reply to this"
  • 用户说"引用转发" / "quote tweet"

工具使用

重要:所有脚本均支持 --json 参数以结构化 JSON 格式输出结果,便于解析。

1. 发送推文

当用户请求发送推文时,先确认内容,然后执行:

python <本技能目录>/scripts/post.py "<推文内容>" --json

如果需要附带图片:

python <本技能目录>/scripts/post.py "<推文内容>" --images /path/to/img1.jpg,/path/to/img2.jpg --json

2. 回复推文

当用户请求回复推文时,先确认 tweet_id 和回复内容,然后执行:

python <本技能目录>/scripts/reply.py <tweet_id> "<回复内容>" --json

3. 引用转发

当用户请求引用转发时,先确认 tweet_id 和评论文字,然后执行:

python <本技能目录>/scripts/quote.py <tweet_id> "<评论文字>" --json

4. 检查登录状态

如需确认用户是否已登录 Twitter:

python <本技能目录>/scripts/whoami.py --json

操作流程示例

发推

用户:"帮我把这段话发到 Twitter" AI:"当然可以!请确认以下内容:'...'" 用户确认后,AI 执行脚本并返回 tweet URL。

回复

用户:"回复这条推文 123456789" AI 执行:python scripts/reply.py 123456789 "我的回复内容" --json

引用转发

用户:"引用转发这条 tweet 987654321" AI 执行:python scripts/quote.py 987654321 "我的评论" --json

注意事项

  • 推文内容不超过 280 字符(不含链接)
  • 最多附带 4 张图片
  • 发推前应确认内容是否正确
  • 如果用户没有明确指定内容,可以用 AI 帮用户生成合适的推文文案
  • 如果执行失败,检查 twitter-cli 是否已安装,以及用户是否已在浏览器登录 Twitter
  • tweet_id 可以是纯数字 ID,也可以是完整的 Twitter URL(如 https://twitter.com/user/status/123456789)

Metadata

Author@baiyea
Stars4473
Views1
Updated2026-05-01
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-baiyea-wh-x-post": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.