Skip to main content
POST
/
api
/
captain
/
agents
/
{id}
/
cron
curl --request POST \
  --url http://localhost:63372/api/captain/agents/{id}/cron \
  --header 'Content-Type: application/json' \
  --cookie captain_session= \
  --data '
{
  "name": "daily-report",
  "message": "Generate the daily report",
  "schedule": {
    "every": "24h"
  },
  "delivery_connector": "discord",
  "delivery_channel": "123456789"
}
'
{
  "ok": true
}

Authorizations

captain_session
string
cookie
required

HMAC-signed session cookie returned by /api/captain/auth/login. Valid for 7 days. Invalidated when password changes.

Path Parameters

id
string
required

Agent ID

Body

application/json
name
string
required
Example:

"daily-report"

message
string
required
Example:

"Generate the daily report"

schedule
object
required

Exactly one of 'every', 'cron', or 'at' must be set.

delivery_connector
string
Example:

"discord"

delivery_channel
string
Example:

"123456789"

Response

Success

ok
boolean
required
Example:

true