Skip to main content
POST
Create

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

orgId
string
required

The organization's id (UUID) or slug — either form is accepted.

projectId
string
required

The project's id (UUID) or slug — either form is accepted.

Query Parameters

environment
string

Environment slug to scope this operation to. Defaults to "production". An environment that does not exist on the project answers 404. The cron job is created in the addressed environment.

Pattern: ^[a-z][a-z0-9-]{0,38}$

Body

application/json
name
string
required
Pattern: ^[a-z][a-z0-9-]{1,61}$
schedule
string
required
target
object
required

Exactly one same-environment target: a signed project-relative HTTP invocation or a queue publication.

timezone
string
enabled
boolean
retry
object
concurrencyPolicy
enum<string>
Available options:
allow,
skip,
replace
timeoutSeconds
integer

Target timeout in seconds, bounded below the durable execution lease.

Required range: 1 <= x <= 840

Response

Cron job created.

id
string
required
name
string
required
Pattern: ^[a-z][a-z0-9-]{1,61}$
environment
string
required
schedule
string
required

Five-field cron expression.

timezone
string
required

IANA timezone name. Defaults to UTC.

enabled
boolean
required
catchUp
enum<boolean>
required

Missed invocations are skipped; catch-up is not performed at launch.

Available options:
false
target
object
required

Exactly one same-environment target: a signed project-relative HTTP invocation or a queue publication.

retry
object
required
concurrencyPolicy
enum<string>
required
Available options:
allow,
skip,
replace
timeoutSeconds
integer
required

Target timeout in seconds, bounded below the durable execution lease.

Required range: 1 <= x <= 840
lastRunAt
string<date-time> | null
required
nextRunAt
string<date-time> | null
required
createdAt
string<date-time>
required
updatedAt
string<date-time>
required