This API v3 documentation is currently still on progress. For any issue, please contact support@runcloud.io
Authorization: Bearer ********************
{
"label": "my first job",
"username": "root",
"command": "/bin/bash /root/clearitem.sh",
"minute": "*",
"hour": "*/2",
"dayOfMonth": "*",
"month": "*",
"dayOfWeek": "*"
}
curl --location -g --request POST 'https://manage.runcloud.io/api/v3/servers/{{serverId}}/cronjobs' \
--header 'Content-Type: application/json' \
--data-raw '{
"label": "my first job",
"username": "root",
"command": "/bin/bash /root/clearitem.sh",
"minute": "*",
"hour": "*/2",
"dayOfMonth": "*",
"month": "*",
"dayOfWeek": "*"
}'
{
"id": 35,
"label": "my first job",
"username": "root",
"time": "* */2 * * *",
"command": "/bin/bash /root/clearitem.sh",
"enabled": 1,
"created_at": "2024-07-18 06:27:19"
}