Scaleway logo
Serverless Functions API

Crons allow you to schedule the execution of functions


List all crons

GET
https://api.scaleway.com
/functions/v1beta1/regions/{region}/crons

List all the cronjobs in a specified region.

List all crons › path Parameters

region
​string · enum · required

The region you want to target

Enum values:
fr-par
nl-ams
pl-waw

List all crons › query Parameters

function_id
​string · required

UUID of the function.

page
​integer · int32

Page number.

page_size
​integer · uint32

Number of crons per page.

Order of the crons.

Enum values:
created_at_asc
created_at_desc
Default: created_at_asc

List all crons › Responses

200

Array of crons.

total_count
​integer · uint32

Total number of crons.


Create a new cron

POST
https://api.scaleway.com
/functions/v1beta1/regions/{region}/crons

Create a new cronjob for a function with the specified ID.

Create a new cron › path Parameters

region
​string · enum · required

The region you want to target

Enum values:
fr-par
nl-ams
pl-waw

Create a new cron › Request Body

function_id
​string

UUID of the function to use the cron with.

schedule
​string

Schedule of the cron in UNIX cron format.

​object

Arguments to use with the cron.

name
​string | null

Name of the cron.

Create a new cron › Responses

200
id
​string

UUID of the cron.

srn
​string · pattern: ^srn://functions\.[^…

SRN of the cron.

function_id
​string

UUID of the function the cron applies to.

schedule
​string

Schedule of the cron.

​object

Arguments to pass with the cron.

status
​scaleway.functions.v1beta1.Cron.Status · enum

Status of the cron.

Enum values:
unknown
ready
deleting
error
locked
creating
pending
Default: unknown
name
​string

Name of the cron.

region
​string

Region in which the cron is located.


Get a cron

GET
https://api.scaleway.com
/functions/v1beta1/regions/{region}/crons/{cron_id}

Get the cron associated with the specified ID.

Get a cron › path Parameters

region
​string · enum · required

The region you want to target

Enum values:
fr-par
nl-ams
pl-waw
cron_id
​string · required

UUID of the cron to get.

Get a cron › Responses

200
id
​string

UUID of the cron.

srn
​string · pattern: ^srn://functions\.[^…

SRN of the cron.

function_id
​string

UUID of the function the cron applies to.

schedule
​string

Schedule of the cron.

​object

Arguments to pass with the cron.

status
​scaleway.functions.v1beta1.Cron.Status · enum

Status of the cron.

Enum values:
unknown
ready
deleting
error
locked
creating
pending
Default: unknown
name
​string

Name of the cron.

region
​string

Region in which the cron is located.


Update an existing cron

PATCH
https://api.scaleway.com
/functions/v1beta1/regions/{region}/crons/{cron_id}

Update the cron associated with the specified ID.

Update an existing cron › path Parameters

region
​string · enum · required

The region you want to target

Enum values:
fr-par
nl-ams
pl-waw
cron_id
​string · required

UUID of the cron to update.

Update an existing cron › Request Body

function_id
​string | null

UUID of the function to use the cron with.

schedule
​string | null

Schedule of the cron in UNIX cron format.

​object

Arguments to use with the cron.

name
​string | null

Name of the cron.

Update an existing cron › Responses

200
id
​string

UUID of the cron.

srn
​string · pattern: ^srn://functions\.[^…

SRN of the cron.

function_id
​string

UUID of the function the cron applies to.

schedule
​string

Schedule of the cron.

​object

Arguments to pass with the cron.

status
​scaleway.functions.v1beta1.Cron.Status · enum

Status of the cron.

Enum values:
unknown
ready
deleting
error
locked
creating
pending
Default: unknown
name
​string

Name of the cron.

region
​string

Region in which the cron is located.


Delete an existing cron

DELETE
https://api.scaleway.com
/functions/v1beta1/regions/{region}/crons/{cron_id}

Delete the cron associated with the specified ID.

Delete an existing cron › path Parameters

region
​string · enum · required

The region you want to target

Enum values:
fr-par
nl-ams
pl-waw
cron_id
​string · required

UUID of the cron to delete.

Delete an existing cron › Responses

200
id
​string

UUID of the cron.

srn
​string · pattern: ^srn://functions\.[^…

SRN of the cron.

function_id
​string

UUID of the function the cron applies to.

schedule
​string

Schedule of the cron.

​object

Arguments to pass with the cron.

status
​scaleway.functions.v1beta1.Cron.Status · enum

Status of the cron.

Enum values:
unknown
ready
deleting
error
locked
creating
pending
Default: unknown
name
​string

Name of the cron.

region
​string

Region in which the cron is located.