Update schedule
PUT/v2/schedules/:scheduleId
Updates a schedule using values specified by a schedule object passed as JSON in the POST payload. If the object does not define a specific property, its value will not be updated.
The response is the full schedule object as returned by the Get schedule endpoint.
The request needs to specify the Content-Type: application/json HTTP
header!
When providing your API authentication token, we recommend using the
request's Authorization header, rather than the URL. (More
info).
Request
Path Parameters
scheduleId string required
Schedule ID.
Example:asdLZtadYvn4mBZmmBodyrequired
- name string | null nullableExample:
my-schedule - isEnabled boolean | null nullableExample:
true - isExclusive boolean | null nullableExample:
true - cronExpression string | null nullableExample:
* * * * * - timezone string | null nullableExample:
UTC - description string | null nullableExample:
Schedule of actor ... actions object[]
- type ScheduleActionType (string) required
Type of action to perform when the schedule triggers.
Possible values: [
RUN_ACTOR,RUN_ACTOR_TASK] - actorId string requiredExample:
jF8GGEvbEg4Au3NLA runInput object
- anyOf
- ScheduleActionsRunInput
- null
- body string | null nullableExample:
{\n "foo": "actor"\n} - contentType string | null nullableExample:
application/json; charset=utf-8
runOptions object
- anyOf
- ScheduleActionsRunOptions
- null
- build string | null nullableExample:
latest - timeoutSecs integer | null nullableExample:
60 - memoryMbytes integer | null nullableExample:
1024 - restartOnError boolean | null nullableExample:
false
- type ScheduleActionType (string) required
Status 200
Response Headers
{
"data": {
"id": "asdLZtadYvn4mBZmm",
"userId": "wRsJZtadYvn4mBZmm",
"name": "my-schedule",
"cronExpression": "* * * * *",
"timezone": "UTC",
"isEnabled": true,
"isExclusive": true,
"description": "Schedule of actor ...",
"createdAt": "2019-12-12T07:34:14.202Z",
"modifiedAt": "2019-12-20T06:33:11.202Z",
"nextRunAt": "2019-04-12T07:34:10.202Z",
"lastRunAt": "2019-04-12T07:33:10.202Z",
"actions": [
{
"id": "c6KfSgoQzFhMk3etc",
"type": "RUN_ACTOR",
"actorId": "jF8GGEvbEg4Au3NLA",
"runInput": {
"body": "{\\n \"foo\": \"actor\"\\n}",
"contentType": "application/json; charset=utf-8"
},
"runOptions": {
"build": "latest",
"timeoutSecs": 60,
"memoryMbytes": 1024,
"restartOnError": false
}
}
]
}
}
Schema
data object required
- id string requiredExample:
asdLZtadYvn4mBZmm - userId string requiredExample:
wRsJZtadYvn4mBZmm - name string requiredExample:
my-schedule - cronExpression string requiredExample:
* * * * * - timezone string requiredExample:
UTC - isEnabled boolean requiredExample:
true - isExclusive boolean requiredExample:
true - description string | null nullableExample:
Schedule of actor ... - createdAt string<date-time> requiredExample:
2019-12-12T07:34:14.202Z - modifiedAt string<date-time> requiredExample:
2019-12-20T06:33:11.202Z - nextRunAt string,null<date-time> nullableExample:
2019-04-12T07:34:10.202Z - lastRunAt string,null<date-time> nullableExample:
2019-04-12T07:33:10.202Z actions object[] required
- id string requiredExample:
c6KfSgoQzFhMk3etc - type ScheduleActionType (string) required
Type of action to perform when the schedule triggers.
Possible values: [
RUN_ACTOR,RUN_ACTOR_TASK] - actorId string requiredExample:
jF8GGEvbEg4Au3NLA runInput object
- anyOf
- ScheduleActionsRunInput
- null
- body string | null nullableExample:
{\n "foo": "actor"\n} - contentType string | null nullableExample:
application/json; charset=utf-8
runOptions object
- anyOf
- ScheduleActionsRunOptions
- null
- build string | null nullableExample:
latest - timeoutSecs integer | null nullableExample:
60 - memoryMbytes integer | null nullableExample:
1024 - restartOnError boolean | null nullableExample:
false
- id string requiredExample:
- id string requiredExample:
Status 400
Bad request - invalid input parameters or request body.
{
"error": {
"type": "invalid-input",
"message": "Invalid input: The request body contains invalid data."
}
}
Schema
error object required
- type string requiredExample:
run-failed - message string requiredExample:
Actor run did not succeed (run ID: 55uatRrZib4xbZs, status: FAILED)
- type string requiredExample: