Change Priority

The Change Task Priority API allows you to change the priority of a task which is in Ready, Held or Created s status. External systems can also change the task priority of one or more tasks based on the urgency of other tasks which need to be executed on a priority. However, you can change the task priority with this API only if the Task/ Change task priority Permission is enabled.

The following are some ways for calling the Change task Priority API:

Using the Task ID:

  • POST.../entity/task/{id}/change_priority/

Options

Category Name Type Required Description
Options priority integer X Priority code of the task (3, 20 etc)
Note: You need to provide the task priority in the request body as this is a post operation of tasks to change the task priority.

Using the Task Number:

  • POST .../entity/task/change_priority/
Category Name Required Type Description
parameters facility_id Integer Facility context by id
parameters facility_id__code string Facility context by code
parameters company_id Integer Company context by id
parameters company_id__code string Company context by code
parameters task_nbr X string Task which needs to be updated

Options

Category Name Type Required Description
Options priority integer X Priority code of the task (3, 20 etc)
Note: The API body should include facility id/code, company id/code and task number. You are also required to provide the task priority in the request body as this is a post operation of tasks to change the task priority.

Using the Bulk Task Release:

  • POST.../entity/task/bulk_change_priority/
{ 
   "parameters": { 
         "id__in": [01, 02, 03] 
    }, 
   "options": { 
         "priority": "3",
         "commit_frequency": "0"
    } 
}
Note: The API body should have the task number list. You are also required to provide the task priority in the request body. You can send the commit frequency as an option as well. The commit frequency is by default set to 0. If it is set to 0, the system should roll back on first error/ If the commit frequency is set to 1, the system will commit per object.