Skip To Content ArcGIS for Developers Sign In Dashboard

All User Scheduled Tasks

  • URL:https://<user-url>/tasks
  • Version Introduced:10.8.1

Description

This resource returns a list of all the scheduled tasks owned by a user. These results can be further filtered by specifying the task ID, it's active statue, or it's task type.

Request parameters

ParameterDetails
itemId

(Optional)

The ID of a task owned by a user. This is a single item ID filter, and does not support a list of task IDs as values.

Example

029b61ca770e428d9468a2a55f40b9fb
active

(Optional)

Filters user owned tasks by their active state. Tasks that are scheduled to continue running will have an active state of true, whereas tasks that are completed, paused, or deleted will have an active state of false.

Values: true | false

types

(Optional)

The task type. The task type is specified during task creation.

Values: ExecuteNotebook | UpdateInsightsWorkbook

f

The response format. The default format is html.

Values: html | json | pjson

Example usage

Below is a sample request URL for tasks that filters for a specific item (itemId=029b61ca770e428d9468a2a55f40b9fb) that has an inactive (active=false) ExecuteNotebook task associated with it:

https://machine.domain.com/webadaptor/sharing/rest/community/users/NBadmin/tasks?types=ExecuteNotebook&active=false&itemId=b181b9ab14d0442faa183215ec2c615e&f=pjson

JSON Response example

{
  "total": 1,
  "start": 1,
  "num": 1,
  "nextStart": -1,
  "activeTasksAvailable": 20,
  "tasks": [
    {
      "id": "5837c7bc37ac404e8e3c16d9022b2b59",
      "itemId": "029b61ca770e428d9468a2a55f40b9fb",
      "type": "ExecuteNotebook",
      "title": "OnceAMinute30times",
      "userId": "NBadmin",
      "cronSchedule": {
        "minute": "*/1",
        "hour": "*",
        "dayOfMonth": "*",
        "month": "*",
        "dayOfWeek": "?"
      },
      "runIntervalSeconds": 60,
      "lastStart": 1589457360000,
      "maxOccurrences": 10,
      "parameters": {
        "updatePortalItem": true,
        "saveInjectedParameters": false,
        "notebookParameters": "{}"
      },
      "created": 1589456737000,
      "updated": 1589457404000,
      "startDate": 1589428800000,
      "active": false,
      "taskState": "completed"
    }
  ]
}