Skip to main content

Get Pending Task

Overview

Getting Activity inside process by providing the Process Instance Id and Activity Instance Id.

URL:

/api/task/pending?userName=?&processName=?

Method: GET

Request Header:

{ "accept": "'*/*'", "Authorization": Bearer ACCESS_TOKEN }

Query Parameter:

  • userName=demouser1,
  • processName=LeaveApplication_demo
http://<Control Room server>/api/task/pending?userName=demouser1&processName=LeaveApplication_demo

Response:

  • Status: 200 OK

  • Body:

       {
    "data": [
    {
    "taskId": 205,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "d6b5c730d7204790b71fa635f72c0b59",
    "statusId": 2,
    "status": "Assigned",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-07-10T04:18:42.231048",
    "created": "2024-07-09T04:18:42.250691",
    "createdBy": "2#demouser1 1",
    "modified": "2024-07-10T09:28:35.853284",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "aa1c4358-7853-430c-8154-9470260b2771",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 122,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "5db238f80be04bc39be76175169ee61a",
    "statusId": 2,
    "status": "Assigned",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-05-09T08:28:41.700046",
    "created": "2024-05-08T08:28:41.746752",
    "createdBy": "2#demouser1 1",
    "modified": "2024-05-08T08:33:04.451622",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "912c91f7-2aeb-4d0b-8999-cf19824c78e7",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 58,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "bc80edca9ada492fb5375ada2c746ff6",
    "statusId": 2,
    "status": "Assigned",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-03T08:36:49.34951",
    "created": "2024-01-02T08:36:49.415073",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-02T08:36:54.77676",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "423dbbb1-02c6-4fc3-896a-5ce92577b44b",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 55,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "ede0264231e0448fbc0737d66d779b3e",
    "statusId": 1,
    "status": "New",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-03T08:34:23.216745",
    "created": "2024-01-02T08:34:23.286842",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-02T08:34:23.286842",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "32c57764-f8e2-4ca9-8359-195686f0ab4e",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 52,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "167be1855d494d5b8441d1cbeeda59fd",
    "statusId": 2,
    "status": "Assigned",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-02T11:03:08.298036",
    "created": "2024-01-01T11:03:08.31921",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-02T08:34:26.064478",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "949499e9-e4b7-4173-a609-30b316533bdc",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 49,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "167be1855d494d5b8441d1cbeeda59fd",
    "statusId": 3,
    "status": "Overdue",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-02T10:59:41.480062",
    "created": "2024-01-01T10:59:41.499681",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-01T10:59:41.499681",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "cd3740fb-dce1-41c2-b831-a8e463c55c5e",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 46,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "167be1855d494d5b8441d1cbeeda59fd",
    "statusId": 3,
    "status": "Overdue",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-02T10:58:38.858863",
    "created": "2024-01-01T10:58:38.893206",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-01T10:58:38.893206",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "4fd497ab-787c-4970-b882-508472a3184b",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    },
    {
    "taskId": 33,
    "name": "Approve",
    "form": "DemoForm.iform",
    "processInstanceId": "167be1855d494d5b8441d1cbeeda59fd",
    "statusId": 3,
    "status": "Overdue",
    "priorityId": 2,
    "arguments": null,
    "assignedTo": 2,
    "assignedUserTitle": "demouser1 1",
    "dueDate": "2024-01-02T10:34:42.956592",
    "created": "2024-01-01T10:34:42.980518",
    "createdBy": "2#demouser1 1",
    "modified": "2024-01-01T10:34:42.980518",
    "modifiedBy": "2#demouser1 1",
    "processName": "LeaveApplication_demo",
    "creatorName": "demouser1 1",
    "modifierName": "demouser1 1",
    "isExternalForm": false,
    "activityId": "StandardTaskWithTimeout1",
    "activityInstanceId": "b6b9c77c-22c7-497c-ad77-e746922a9c88",
    "isAssignedToGroup": true,
    "originalAssignedUserTitle": "demouser1 1",
    "input": null,
    "output": null
    }
    ],
    "totalCount": 8
    }
  • Header:

       {
    content-length: 5704
    content-security-policy: default-src 'self' fonts.googleapis.com fonts.gstatic.com;script-src 'self' 'unsafe-inline' 'unsafe-eval' fonts.googleapis.com fonts.gstatic.com cdn.form.io blob:;style-src 'self' 'unsafe-inline' fonts.googleapis.com fonts.gstatic.com;img-src 'self' fonts.googleapis.com fonts.gstatic.com data:;font-src 'self' fonts.googleapis.com fonts.gstatic.com
    content-type: application/json; charset=utf-8
    date: Wed,10 Jul 2024 09:30:48 GMT
    referrer-policy: no-referrer
    x-content-type-options: nosniff
    x-xss-protection: 1; mode=block
    }