📦 toutiaoAutoPublish — 技能工具

v1.0.0

今日头条微头条自动发布工具。自动发布短内容到今日头条平台,支持文本和图片。 使用场景:(1) 用户说"发布头条"、"发微头条"、"头条发布"时触发 (2) 需要自动发布社交媒体内容时 (3) 需要定时发布今日头条时

0· 636·4 当前·4 累计
by @devilsbibble·MIT-0
下载技能包
License
MIT-0
最后更新
2026/4/11
0
安全扫描
VirusTotal
无害
查看报告
OpenClaw
可疑
medium confidence
The skill largely matches its stated purpose (automating Toutiao posts) but contains surprising/incoherent elements (mismatched debugging port, a built-in default message that will post autonomously, and truncated code review uncertainty) that warrant caution before use.
安全有层次,运行前请审查代码。

License

MIT-0

可自由使用、修改和再分发,无需署名。

运行时依赖

无特殊依赖

版本

latestv1.0.02026/3/10

publish jinri toutiao news use browser agent

无害

安装命令

点击复制
官方npx clawhub@latest install toutiao-auto-publish
🇨🇳 镜像加速npx clawhub@latest install toutiao-auto-publish --registry https://cn.longxiaskill.com

技能文档

使用此 skill 可以自动发布微头条到今日头条平台。

前置要求

  • Chrome 远程调试已启动
   /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222
   
  • Chrome 已登录今日头条:访问 https://mp.toutiao.com 完成登录
  • Python 依赖
   pip3 install playwright --break-system-packages
   playwright install chromium
   

使用方法

基本发布

cd ~/.openclaw/workspace/skills/toutiao-publisher/scripts
python3 toutiao_publish.py "要发布的文字内容"

带话题发布

# 单个话题
python3 toutiao_publish.py "内容文字" --topic "#AI#"

# 多个话题 python3 toutiao_publish.py "内容文字" --topic "#AI#,#OpenClaw#,#科技#"

带图片发布

python3 toutiao_publish.py "内容" --image /path/to/image.jpg

从文件读取内容

python3 toutiao_publish.py -f content.txt

参数说明

参数说明示例
content发布内容"今天天气很好"
-f, --file从文件读取-f post.txt
-i, --image图片路径--image pic.jpg
-t, --topic话题标签,多个用逗号分隔--topic "#AI#,#OpenClaw#"
--headless无头模式--headless
--no-wait不等待登录--no-wait

话题格式

话题必须使用 双 # 格式:

  • ✅ 正确:#AI##OpenClaw##科技前沿#
  • ❌ 错误:#AIAI#

多个话题用逗号分隔,脚本会自动用空格连接。

输出

  • 成功截图~/Desktop/toutiao_publish_success.png
  • 错误截图~/Desktop/toutiao_error.png

故障排除

问题解决方案
无法连接 Chrome确保 Chrome 已启动并开启 9222 端口
未检测到登录在 Chrome 中访问 mp.toutiao.com 完成登录
发布失败检查网络连接,查看错误截图
数据来源:ClawHub ↗ · 中文优化:龙虾技能库