curl --request POST \
--url https://zeus-api.agentspro.cn/scheduled-task/sync \
--header 'X-Internal-Secret: your-secret' \
--header 'Content-Type: application/json' \
--data '{
"action": "add",
"task_id": "task_123",
"task": {
"id": "task_123",
"user_id": "user_456",
"title": "每日邮件摘要",
"prompt": "检查收件箱并生成今日邮件摘要",
"repeat_type": "daily",
"scheduled_time": "09:00",
"timezone": "Asia/Shanghai"
}
}'
{
"success": true,
"action": "add",
"task_id": "task_123"
}
定时任务 API
同步任务
同步定时任务到调度器(内部 API)
POST
/
scheduled-task
/
sync
curl --request POST \
--url https://zeus-api.agentspro.cn/scheduled-task/sync \
--header 'X-Internal-Secret: your-secret' \
--header 'Content-Type: application/json' \
--data '{
"action": "add",
"task_id": "task_123",
"task": {
"id": "task_123",
"user_id": "user_456",
"title": "每日邮件摘要",
"prompt": "检查收件箱并生成今日邮件摘要",
"repeat_type": "daily",
"scheduled_time": "09:00",
"timezone": "Asia/Shanghai"
}
}'
{
"success": true,
"action": "add",
"task_id": "task_123"
}
这是内部 API,由 Web 端通过
X-Internal-Secret header 调用,不对外暴露。curl --request POST \
--url https://zeus-api.agentspro.cn/scheduled-task/sync \
--header 'X-Internal-Secret: your-secret' \
--header 'Content-Type: application/json' \
--data '{
"action": "add",
"task_id": "task_123",
"task": {
"id": "task_123",
"user_id": "user_456",
"title": "每日邮件摘要",
"prompt": "检查收件箱并生成今日邮件摘要",
"repeat_type": "daily",
"scheduled_time": "09:00",
"timezone": "Asia/Shanghai"
}
}'
{
"success": true,
"action": "add",
"task_id": "task_123"
}