Skip to main content
PATCH
/
api
/
deployments
/
{id}
/
schedules
/
{schedule_id}
Update Deployment Schedule
curl --request PATCH \
  --url https://api.example.com/api/deployments/{id}/schedules/{schedule_id} \
  --header 'Content-Type: application/json' \
  --data '
{
  "active": true,
  "schedule": {
    "interval": 123,
    "anchor_date": "2023-11-07T05:31:56Z",
    "timezone": "America/New_York"
  },
  "max_scheduled_runs": 1,
  "parameters": {},
  "slug": "<string>"
}
'
{
  "detail": [
    {
      "loc": [
        "<string>"
      ],
      "msg": "<string>",
      "type": "<string>"
    }
  ]
}

Headers

x-prefect-api-version
string

Path Parameters

id
string<uuid>
required

The deployment id

schedule_id
string<uuid>
required

The schedule id

Body

application/json

The updated schedule

active
boolean | null

Whether or not the schedule is active.

schedule
IntervalSchedule · object

The schedule for the deployment.

max_scheduled_runs
integer | null

The maximum number of scheduled runs for the schedule.

Required range: x > 0
parameters
Parameters · object

A dictionary of parameter value overrides.

slug
string | null

A unique identifier for the schedule.

Response

Successful Response