Skip to main content
POST
Create scheduled command
Required permission: environment_instance.edit

Authorizations

Authorization
string
header
required

The Bearer Token generated on the Cloud UI.

Path Parameters

instance
string
required

The instance identifier

Body

application/json
command
string
required

The command to run. Each command can only be scheduled once per instance.

Maximum string length: 500
Example:

"php artisan model:prune"

schedule
string
required

A five-field cron expression, evaluated in UTC. The @yearly, @annually, @monthly, @weekly, @daily, @midnight, and @hourly descriptors are also accepted.

Maximum string length: 255
Example:

"0 0 * * *"

name
string | null

A friendly name for the scheduled command.

Maximum string length: 255
Example:

"Prune stale models"

Response

ScheduledCommandResource

data
ScheduledCommandResource · object
required
included
InstanceResource · object[]