twitter-monitor
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseTwitter Monitor
Twitter 监控工具
Workflow
工作流程
Use this skill as an execution workflow, not as a long-running daemon. First complete a one-shot fetch, then offer optional Feishu sync and scheduling only when useful.
- Ask for X/Twitter account ids when missing. Accept handles such as ,
sama, profile URLs, or multiple comma-separated ids.@sama - Ask the user to provide or configure a API key when
twitterapi.iois unavailable. Do not write API keys into files committed to a repository.TWITTER_API_KEY - Confirm pagination depth. Default to ; use a larger number only when the user asks for more history or accepts higher API usage.
--pages 1 - Run and generate JSON or CSV output.
scripts/twitter_monitor.py - If the user wants Feishu/Lark Bitable output, follow .
references/feishu-output.md - After the one-shot command works, ask whether they want recurring execution. If yes, follow , including OpenClaw when appropriate.
references/scheduling.md
请将该技能作为执行工作流使用,而非长期运行的守护进程。先完成一次性数据抓取,仅在有需要时再提供可选的飞书同步和定时调度功能。
- 若缺少X/Twitter账号ID,请向用户询问。支持用户名(如、
sama)、个人主页链接,或以逗号分隔的多个账号ID。@sama - 当不可用时,请让用户提供或配置
TWITTER_API_KEYAPI密钥。请勿将API密钥写入提交到代码仓库的文件中。twitterapi.io - 确认分页深度。默认值为;仅当用户需要更多历史数据或同意更高API调用量时,才使用更大的数值。
--pages 1 - 运行并生成JSON或CSV格式的输出。
scripts/twitter_monitor.py - 若用户需要将输出保存至飞书/Lark多维表格,请遵循中的指引。
references/feishu-output.md - 一次性命令执行成功后,询问用户是否需要定期执行。若需要,请遵循中的指引,适当时可使用OpenClaw。
references/scheduling.md
Quick Start
快速开始
From this skill directory:
bash
export TWITTER_API_KEY="..."
python scripts/twitter_monitor.py --accounts sama --pages 1 --format jsonFor multiple accounts:
bash
python scripts/twitter_monitor.py --accounts sama,elonmusk,OpenAI --pages 1 --format csvFor a JSON account list:
bash
python scripts/twitter_monitor.py --accounts-file assets/accounts.example.json --pages 1Read when the user needs API key setup, account input examples, or command variants.
references/twitterapi-setup.md在该技能目录下执行以下命令:
bash
export TWITTER_API_KEY="..."
python scripts/twitter_monitor.py --accounts sama --pages 1 --format json针对多个账号的情况:
bash
python scripts/twitter_monitor.py --accounts sama,elonmusk,OpenAI --pages 1 --format csv针对JSON格式的账号列表:
bash
python scripts/twitter_monitor.py --accounts-file assets/accounts.example.json --pages 1若用户需要API密钥配置、账号输入示例或命令变体说明,请查阅。
references/twitterapi-setup.mdOutput Schema
输出 Schema
The script writes one record per tweet with these fields:
推文内容日期推文链接推文ID作者作者ID阅读量点赞数转发数评论数收藏数是否回复抓取时间
Deduplicate by before appending to any durable destination.
推文ID脚本会为每条推文生成一条记录,包含以下字段:
推文内容日期推文链接推文ID作者作者ID阅读量点赞数转发数评论数收藏数是否回复抓取时间
在将记录追加至任何持久化存储前,请通过进行去重。
推文IDFeishu
飞书
Do not require Feishu configuration for normal fetches. Only enter the Feishu workflow when the user asks to write, append, or sync records to Feishu/Lark Bitable.
Prefer over hard-coded Feishu app credentials. If is missing, ask whether to install and configure it. See for the field mapping and sync rules.
feishu-clifeishu-clireferences/feishu-output.md常规数据抓取无需要求用户配置飞书。仅当用户明确要求将记录写入、追加或同步至飞书/Lark多维表格时,才进入飞书工作流。
优先使用而非硬编码的飞书应用凭证。若未安装,请询问用户是否需要安装并配置。字段映射和同步规则请查阅。
feishu-clifeishu-clireferences/feishu-output.mdScheduling
定时调度
Offer scheduling only after a successful one-shot fetch or when the user explicitly asks for ongoing monitoring.
Prefer OpenClaw when the user wants an agent-managed recurring job or already uses OpenClaw. Otherwise choose Codex automations, cron, or launchd based on the runtime environment. See .
references/scheduling.md仅在一次性抓取成功后,或用户明确要求持续监控时,才提供定时调度选项。
若用户需要由Agent管理的定期任务,或已在使用OpenClaw,则优先选择OpenClaw。否则根据运行环境选择Codex自动化工具、cron或launchd。详细说明请查阅。
references/scheduling.mdSafety
安全注意事项
Never commit real API keys, Feishu tokens, output files containing private monitoring data, or local status caches. Keep secrets in environment variables, secret managers, or the user's existing CLI auth.
请勿提交真实的API密钥、飞书令牌、包含隐私监控数据的输出文件或本地状态缓存。请将机密信息存储在环境变量、密钥管理器或用户已有的CLI认证中。