Resource for managing the scheduler
List scheduler jobs
name | type | description | default | constraints |
---|---|---|---|---|
active | query | If set to true , only active jobs will be returned. If set to false , only inactive jobs will be returned.
If not set (default), all jobs will be returned. |
boolean | |
failed | query | If set to true , only failed jobs will be returned. If set to false , only successful jobs will be returned (include jobs that were not yet executed).
If not set (default), all jobs will be returned. |
boolean | |
page | query | Returned page, if paging is used. Paging starts with 1 |
1 | int |
pageSize | query | Page size for paging. If this is set to -1 no paging is used (all matching items are returned).
Setting this to 0 will return no items. |
-1 | int |
q | query | Query string for filtering | ||
sort | query | Comma separated list of sorted attributes.
Each attribute name may be prefixed with + for sorting in ascending order or - for sorting in descending order |
name |
code | condition |
---|---|
200 | Jobs are returned. |
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
media type | data type | description |
---|---|---|
application/json | JobsResponse (JSON) | list of jobs |
GET /scheduler/jobs
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"items" : [ { }, { } ],
"hasMoreItems" : true,
"numItems" : 12345,
"perms" : {
"property1" : [ "updateinheritance", "userassignment" ],
"property2" : [ "updatefolder", "deletetemplates" ]
},
"stagingStatus" : {
"property1" : {
"packageName" : "...",
"included" : true
},
"property2" : {
"packageName" : "...",
"included" : true
}
},
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Resume the scheduler
code | condition |
---|---|
200 | Scheduler is resumed. |
405 | Feature suspend_scheduler is not activated. |
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
media type | data type | description |
---|---|---|
application/json | SchedulerStatusResponse (JSON) | status |
PUT /scheduler/resume
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"status" : "running",
"executorStatus" : "NOT_RUNNING",
"allowRun" : [ 12345, 12345 ],
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
List scheduler schedules.
The result can be filtered by
id
name
description
taskId
id
name
description
taskId
cdate
edate
name | type | description | default | constraints |
---|---|---|---|---|
page | query | Returned page, if paging is used. Paging starts with 1 |
1 | int |
pageSize | query | Page size for paging. If this is set to -1 no paging is used (all matching items are returned).
Setting this to 0 will return no items. |
-1 | int |
perms | query | Flag to add permission information for the returned items. | false | boolean |
q | query | Query string for filtering | ||
sort | query | Comma separated list of sorted attributes.
Each attribute name may be prefixed with + for sorting in ascending order or - for sorting in descending order |
name |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The list of schedules is returned. |
media type | data type | description |
---|---|---|
application/json | ScheduleListResponse (JSON) | response containing a list of schedules |
GET /scheduler/schedule
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"items" : [ { }, { } ],
"hasMoreItems" : true,
"numItems" : 12345,
"perms" : {
"property1" : [ "publish", "updatefolder" ],
"property2" : [ "translatepages", "importitems" ]
},
"stagingStatus" : {
"property1" : {
"packageName" : "...",
"included" : true
},
"property2" : {
"packageName" : "...",
"included" : true
}
},
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Create a new Schedule
media type | data type | description |
---|---|---|
application/json | ScheduleModel (JSON) | schedule |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
201 | The schedule was created |
media type | data type | description |
---|---|---|
application/json | ScheduleResponse (JSON) | response containing the created schedule |
POST /scheduler/schedule
Content-Type: application/json
Accept: application/json
{
"id" : 12345,
"name" : "...",
"description" : "...",
"taskId" : 12345,
"scheduleData" : {
"type" : "interval",
"startTimestamp" : 12345,
"endTimestamp" : 12345,
"interval" : {
"value" : 12345,
"unit" : "hour"
},
"follow" : {
"scheduleId" : [ 12345, 12345 ],
"onlyAfterSuccess" : true
}
},
"parallel" : true,
"active" : true,
"status" : "IDLE",
"notificationEmail" : [ "...", "..." ],
"runs" : 12345,
"averageTime" : 12345,
"lastExecution" : {
"id" : 12345,
"scheduleId" : 12345,
"startTime" : 12345,
"endTime" : 12345,
"duration" : 12345,
"result" : true,
"log" : "...",
"running" : true
},
"creator" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"cdate" : 12345,
"editor" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"edate" : 12345
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Get the scheduler status and optionally restart the scheduler executor if it is not running.
name | type | description | constraints |
---|---|---|---|
fixExecutor | query | Whether to restart the scheduler executor if it is not running currently. | required boolean |
code | condition |
---|---|
200 | Scheduler status is returned. |
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
media type | data type | description |
---|---|---|
application/json | SchedulerStatusResponse (JSON) | status |
GET /scheduler/status
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"status" : "suspended",
"executorStatus" : "NOT_RUNNING",
"allowRun" : [ 12345, 12345 ],
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Suspend the scheduler
media type | data type | description |
---|---|---|
application/json | SuspendRequest (JSON) | suspend request |
code | condition |
---|---|
200 | Scheduler is suspended. |
405 | Feature suspend_scheduler is not activated. |
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
media type | data type | description |
---|---|---|
application/json | SchedulerStatusResponse (JSON) | status |
PUT /scheduler/suspend
Content-Type: application/json
Accept: application/json
{
"allowRun" : [ 12345, 12345 ]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"status" : "suspending",
"executorStatus" : "RUNNING",
"allowRun" : [ 12345, 12345 ],
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
List scheduler tasks.
The result can be filtered by
id
name
description
command
id
name
description
command
cdate
edate
name | type | description | default | constraints |
---|---|---|---|---|
page | query | Returned page, if paging is used. Paging starts with 1 |
1 | int |
pageSize | query | Page size for paging. If this is set to -1 no paging is used (all matching items are returned).
Setting this to 0 will return no items. |
-1 | int |
perms | query | Flag to add permission information for the returned items. | false | boolean |
q | query | Query string for filtering | ||
sort | query | Comma separated list of sorted attributes.
Each attribute name may be prefixed with + for sorting in ascending order or - for sorting in descending order |
name |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The list of tasks is returned. |
media type | data type | description |
---|---|---|
application/json | TaskListResponse (JSON) | response containing a list of tasks |
GET /scheduler/task
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"items" : [ { }, { } ],
"hasMoreItems" : true,
"numItems" : 12345,
"perms" : {
"property1" : [ "linkoverview", "updatefolder" ],
"property2" : [ "edit", "userassignment" ]
},
"stagingStatus" : {
"property1" : {
"packageName" : "...",
"included" : true
},
"property2" : {
"packageName" : "...",
"included" : true
}
},
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Create a new task
media type | data type | description |
---|---|---|
application/json | TaskModel (JSON) | task |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
201 | The task was created |
media type | data type | description |
---|---|---|
application/json | TaskResponse (JSON) | response containing the created task |
POST /scheduler/task
Content-Type: application/json
Accept: application/json
{
"id" : 12345,
"name" : "...",
"description" : "...",
"command" : "...",
"internal" : true,
"creator" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"cdate" : 12345,
"editor" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"edate" : 12345
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Load an execution
name | type | description |
---|---|---|
id | path | execution ID |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The schedule is returned |
404 | The schedule with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | ExecutionResponse (JSON) | response containing the execution |
GET /scheduler/execution/{id}
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Delete a schedule
name | type | description |
---|---|---|
id | path | schedule ID |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The schedule was deleted |
404 | The schedule with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | GenericResponse (JSON) | response |
DELETE /scheduler/schedule/{id}
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Load a schedule
name | type | description |
---|---|---|
id | path | schedule ID |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The schedule is returned |
404 | The schedule with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | ScheduleResponse (JSON) | response containing the schedule |
GET /scheduler/schedule/{id}
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Update a schedule
name | type | description |
---|---|---|
id | path | schedule ID |
media type | data type | description |
---|---|---|
application/json | ScheduleModel (JSON) | schedule to update |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The schedule was updated |
404 | The schedule with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | ScheduleResponse (JSON) | updated task |
PUT /scheduler/schedule/{id}
Content-Type: application/json
Accept: application/json
{
"id" : 12345,
"name" : "...",
"description" : "...",
"taskId" : 12345,
"scheduleData" : {
"type" : "once",
"startTimestamp" : 12345,
"endTimestamp" : 12345,
"interval" : {
"value" : 12345,
"unit" : "month"
},
"follow" : {
"scheduleId" : [ 12345, 12345 ],
"onlyAfterSuccess" : true
}
},
"parallel" : true,
"active" : true,
"status" : "RUNNING",
"notificationEmail" : [ "...", "..." ],
"runs" : 12345,
"averageTime" : 12345,
"lastExecution" : {
"id" : 12345,
"scheduleId" : 12345,
"startTime" : 12345,
"endTime" : 12345,
"duration" : 12345,
"result" : true,
"log" : "...",
"running" : true
},
"creator" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"cdate" : 12345,
"editor" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"edate" : 12345
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Delete a task
name | type | description |
---|---|---|
id | path | task ID |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The task was deleted |
404 | The task with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | GenericResponse (JSON) | response |
DELETE /scheduler/task/{id}
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Load a task
name | type | description |
---|---|---|
id | path | task ID |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The task is returned |
404 | The task with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | TaskResponse (JSON) | response containing the task |
GET /scheduler/task/{id}
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Update a task
name | type | description |
---|---|---|
id | path | task ID |
media type | data type | description |
---|---|---|
application/json | TaskModel (JSON) | task data to update |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The task was updated |
404 | The task with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | TaskResponse (JSON) | updated task |
PUT /scheduler/task/{id}
Content-Type: application/json
Accept: application/json
{
"id" : 12345,
"name" : "...",
"description" : "...",
"command" : "...",
"internal" : true,
"creator" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"cdate" : 12345,
"editor" : {
"id" : 12345,
"firstName" : "...",
"lastName" : "...",
"description" : "...",
"email" : "...",
"groups" : [ {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
}, {
"id" : 12345,
"name" : "...",
"description" : "...",
"children" : [ { }, { } ]
} ],
"login" : "...",
"password" : "..."
},
"edate" : 12345
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"item" : { },
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
Execute the specified schedule now.
There is no check if the schedule schould be executed, besides a check if it is active.
name | type | description |
---|---|---|
id | path | The schedule to execute |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | Execution of the schedule was startet |
404 | The schedule with given ID does not exist |
media type | data type | description |
---|---|---|
application/json | GenericResponse (JSON) | response |
POST /scheduler/schedule/{id}/execute
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}
List all executions of the given schedule which match the filters.
The result can be filtered by
id
scheduleId
log
id
startTime
endTime
duration
result
name | type | description | default | constraints |
---|---|---|---|---|
id | path | schedule ID | ||
failed | query | Filter for result status.
If set to |
boolean | |
page | query | Returned page, if paging is used. Paging starts with 1 |
1 | int |
pageSize | query | Page size for paging. If this is set to -1 no paging is used (all matching items are returned).
Setting this to 0 will return no items. |
-1 | int |
q | query | Query string for filtering | ||
sort | query | Comma separated list of sorted attributes.
Each attribute name may be prefixed with + for sorting in ascending order or - for sorting in descending order |
name | |
ts_max | query | Filter for maximum starting time.
Only executions which have been started before the given timestamp will be returned. Note that if #timestampMax is less than #timestampMin it will be ignored. |
int | |
ts_min | query | Filter for minimum starting time.
Only executions which have been started after the given timestamp will be returned. |
int |
code | condition |
---|---|
401 | No valid sid and session secret cookie were provided. |
403 | User has insufficient permissions on the scheduler. |
200 | The list of executions is returned. |
media type | data type | description |
---|---|---|
application/json | ExecutionListResponse (JSON) | Response containing the list of executions |
GET /scheduler/schedule/{id}/execution
Content-Type: */*
Accept: application/json
...
HTTP/1.1 200 OK
Content-Type: application/json
{
"items" : [ { }, { } ],
"hasMoreItems" : true,
"numItems" : 12345,
"perms" : {
"property1" : [ "publishpages", "createoverview" ],
"property2" : [ "createform", "updateitems" ]
},
"stagingStatus" : {
"property1" : {
"packageName" : "...",
"included" : true
},
"property2" : {
"packageName" : "...",
"included" : true
}
},
"messages" : [ { }, { } ],
"responseInfo" : {
"responseCode" : "OK",
"responseMessage" : "...",
"property" : "..."
}
}