
This is a full CRUD interface for managing cron jobs in CountBot. It handles the usual stuff like creating scheduled tasks with cron expressions, listing them, updating schedules, and deleting jobs. The interesting bits are the built-in retry logic (defaults to one retry after 60 seconds, configurable up to five), auto-delete on success for one-off reminders, and channel-aware delivery that can push task results directly to Feishu, Telegram, or other platforms. It also manages session data per task, so you can view execution history or clean up old messages. The CLI is the main interface, though it wraps a REST API running on localhost:8000. Useful when you need scheduled reminders or recurring tasks that interact with the bot's conversational context instead of just running headless jobs.
$ npx -y skills add countbot-ai/countbot --skill cron-manager --agent claude-codeInstalls into .claude/skills of the current project.
通过命令行管理 CountBot 的定时任务系统,支持完整的 CRUD 操作和会话数据管理。
开始前先快速确认后端可用:
curl -s http://127.0.0.1:8000/api/cron/jobs || echo "后端服务没在运行!"
所有操作优先通过 exec 工具执行这个脚本:
python3 skills/cron-manager/scripts/cron_manager.py <command> [args]
硬性规则:
skills/cron-manager/scripts/cron_manager.py 这个脚本名,不要猜 cron.pyinfo/delete/enable/disable/run/messages/clean/reset 都优先传位置参数 <job_id>ls、再 help、再试错多次;优先直接按下面的准确命令执行-h 查看帮助# 基本创建(默认启用自动重试1次)
python3 skills/cron-manager/scripts/cron_manager.py create --name "每日天气" --schedule "0 9 * * *" --message "查询今天的天气并生成播报"
# 创建不重试的任务
python3 skills/cron-manager/scripts/cron_manager.py create --name "简单任务" --schedule "0 9 * * *" --message "执行简单任务" --max-retries 0
Sponsors