Get a List of Workflow Tasks bizproc.task.list
Scope:
bizprocWho can execute the method: any user
The method bizproc.task.list retrieves a list of workflow tasks.
A portal administrator can request all tasks or tasks for any user. A regular user can only request their own tasks or those of their subordinate.
When requesting their own tasks, the USER_ID filter does not need to be specified.
In cloud Bitrix24, information about tasks is available for 24 hours after the workflow is completed.
Method Parameters
Required parameters are marked with *
|
Name |
Description |
|
SELECT |
An array containing a list of fields to select. You can specify only the fields that are necessary. By default, it returns the fields |
|
FILTER |
An object for filtering the list of tasks in the format
If
If the method is called by a non-administrator and the |
|
ORDER |
An object for sorting the list of tasks in the format
The sorting direction can take the following values:
You can specify multiple fields for sorting, for example, |
|
START |
This parameter is used for managing pagination. The page size of results is always static — 50 records. To select the second page of results, you need to pass the value The formula for calculating the
|
Code Examples
How to Use Examples in Documentation
curl -X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"select":["ID","WORKFLOW_ID","DOCUMENT_NAME","DESCRIPTION","NAME","MODIFIED","WORKFLOW_STARTED","WORKFLOW_STARTED_BY","OVERDUE_DATE","WORKFLOW_TEMPLATE_ID","WORKFLOW_TEMPLATE_NAME","WORKFLOW_STATE","STATUS","USER_ID","USER_STATUS","MODULE_ID","ENTITY","DOCUMENT_ID","ACTIVITY","ACTIVITY_NAME","DOCUMENT_URL","PARAMETERS"],"order":{"ID":"DESC"},"filter":{"USER_ID":1,"STATUS":0,"ACTIVITY":"RequestInformationOptionalActivity"}}' \
https://**put_your_bitrix24_address**/rest/**put_your_user_id_here**/**put_your_webhook_here**/bizproc.task.list
curl -X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{"select":["ID","WORKFLOW_ID","DOCUMENT_NAME","DESCRIPTION","NAME","MODIFIED","WORKFLOW_STARTED","WORKFLOW_STARTED_BY","OVERDUE_DATE","WORKFLOW_TEMPLATE_ID","WORKFLOW_TEMPLATE_NAME","WORKFLOW_STATE","STATUS","USER_ID","USER_STATUS","MODULE_ID","ENTITY","DOCUMENT_ID","ACTIVITY","ACTIVITY_NAME","DOCUMENT_URL","PARAMETERS"],"order":{"ID":"DESC"},"filter":{"USER_ID":1,"STATUS":0,"ACTIVITY":"RequestInformationOptionalActivity"},"auth":"**put_access_token_here**"}' \
https://**put_your_bitrix24_address**/rest/bizproc.task.list
// callListMethod: Retrieves all data at once. Use only for small selections (< 1000 items) due to high memory load.
const parameters = {
select: [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
order: {
ID: 'DESC'
},
filter: {
'USER_ID': 1,
'STATUS': 0,
'ACTIVITY': 'RequestInformationOptionalActivity'
}
};
try {
const response = await $b24.callListMethod('bizproc.task.list', parameters);
const items = response.getData() || [];
for (const entity of items) { console.log('Entity:', entity); }
} catch (error) {
console.error('Request failed', error);
}
// fetchListMethod: Retrieves data in parts using an iterator. Use for large volumes of data for efficient memory consumption.
const parameters = {
select: [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
order: {
ID: 'DESC'
},
filter: {
'USER_ID': 1,
'STATUS': 0,
'ACTIVITY': 'RequestInformationOptionalActivity'
}
};
try {
const generator = $b24.fetchListMethod('bizproc.task.list', parameters, 'ID');
for await (const page of generator) {
for (const entity of page) { console.log('Entity:', entity); }
}
} catch (error) {
console.error('Request failed', error);
}
// callMethod: Manual control of pagination through the start parameter. Use for precise control over request batches. Less efficient for large data than fetchListMethod.
const parameters = {
select: [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
order: {
ID: 'DESC'
},
filter: {
'USER_ID': 1,
'STATUS': 0,
'ACTIVITY': 'RequestInformationOptionalActivity'
}
};
try {
const response = await $b24.callMethod('bizproc.task.list', parameters, 0);
const result = response.getData().result || [];
for (const entity of result) { console.log('Entity:', entity); }
} catch (error) {
console.error('Request failed', error);
}
try {
$response = $b24Service
->core
->call(
'bizproc.task.list',
[
'select' => [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
'order' => [
'ID' => 'DESC'
],
'filter' => [
'USER_ID' => 1,
'STATUS' => 0,
'ACTIVITY' => 'RequestInformationOptionalActivity'
]
]
);
$result = $response
->getResponseData()
->getResult();
if ($result->error()) {
echo 'Error: ' . $result->error();
} else {
echo 'Success: ' . print_r($result->data(), true);
}
} catch (Throwable $e) {
error_log($e->getMessage());
echo 'Error: ' . $e->getMessage();
}
BX24.callMethod(
'bizproc.task.list',
{
select: [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
order: {
ID: 'DESC'
},
filter: {
'USER_ID': 1,
'STATUS': 0,
'ACTIVITY': 'RequestInformationOptionalActivity'
}
},
function(result)
{
if(result.error())
alert("Error: " + result.error());
else
console.log(result.data());
}
);
require_once('crest.php');
$result = CRest::call(
'bizproc.task.list',
[
'select' => [
'ID',
'WORKFLOW_ID',
'DOCUMENT_NAME',
'DESCRIPTION',
'NAME',
'MODIFIED',
'WORKFLOW_STARTED',
'WORKFLOW_STARTED_BY',
'OVERDUE_DATE',
'WORKFLOW_TEMPLATE_ID',
'WORKFLOW_TEMPLATE_NAME',
'WORKFLOW_STATE',
'STATUS',
'USER_ID',
'USER_STATUS',
'MODULE_ID',
'ENTITY',
'DOCUMENT_ID',
'ACTIVITY',
'ACTIVITY_NAME',
'DOCUMENT_URL',
'PARAMETERS'
],
'order' => [
'ID' => 'DESC'
],
'filter' => [
'USER_ID' => 1,
'STATUS' => 0,
'ACTIVITY' => 'RequestInformationOptionalActivity'
]
]
);
echo '<PRE>';
print_r($result);
echo '</PRE>';
Response Handling
HTTP Status: 200
{
"result": [
{
"ENTITY": "BizprocDocument",
"DOCUMENT_ID": "2249",
"ID": "1477",
"WORKFLOW_ID": "67a2ffdb2c57a3.35276854",
"DOCUMENT_NAME": "Partner Conference",
"DESCRIPTION": "",
"NAME": "Add Contractor Information",
"MODIFIED": "2025-02-05T09:06:19+01:00",
"WORKFLOW_STARTED": "2025-02-05T09:06:19+01:00",
"WORKFLOW_STARTED_BY": "1",
"OVERDUE_DATE": null,
"WORKFLOW_TEMPLATE_ID": "565",
"WORKFLOW_TEMPLATE_NAME": "Event Organization",
"WORKFLOW_STATE": "Waiting for Additional Information",
"STATUS": "0",
"USER_ID": "1",
"USER_STATUS": "0",
"MODULE_ID": "lists",
"ACTIVITY": "RequestInformationActivity",
"ACTIVITY_NAME": "A3651_68033_56029_16413",
"PARAMETERS": {
"CommentLabel": "Comment",
"CommentRequired": "Y",
"ShowComment": "Y",
"StatusOkLabel": "Save Result",
"Fields": [
{
"Id": "contractor",
"Type": "E:ECrm",
"Name": "Contractor",
"Description": "Who performs the work",
"Multiple": false,
"Required": true,
"Options": {
"LEAD": "N",
"CONTACT": "Y",
"COMPANY": "Y",
"DEAL": "N",
"SMART_INVOICE": "N",
"DYNAMIC_136": "N",
"DYNAMIC_1038": "N"
},
"Settings": null,
"Default": [
"C_607"
]
},
{
"Id": "phone_number",
"Type": "string",
"Name": "Phone Number",
"Description": "",
"Multiple": false,
"Required": true,
"Options": null,
"Settings": null,
"Default": ""
}
]
},
"DOCUMENT_URL": "/bizproc/processes/?livefeed=y&list_id=171&element_id=2249"
},
{
"ENTITY": "BizprocDocument",
"DOCUMENT_ID": "2237",
"ID": "1471",
...
}
],
"total": 2,
"time": {
"start": 1738735796.4730229,
"finish": 1738735796.510215,
"duration": 0.037192106246948242,
"processing": 0.0080459117889404297,
"date_start": "2025-02-05T09:09:56+01:00",
"date_finish": "2025-02-05T09:09:56+01:00",
"operating_reset_at": 1738736396,
"operating": 0
}
}
Returned Data
|
Name |
Description |
|
result |
The root element of the response. Contains an array of objects with information about workflow tasks. Each object contains fields of the task specified in the |
|
total |
The total number of records found |
|
time |
Information about the request execution time |
Task Fields
|
Name |
Description |
|
ID |
Task identifier |
|
WORKFLOW_ID |
Workflow identifier |
|
DOCUMENT_NAME |
Document name |
|
DESCRIPTION |
Task description |
|
NAME |
Task name |
|
MODIFIED |
Modification date |
|
WORKFLOW_STARTED |
Workflow start date |
|
WORKFLOW_STARTED_BY |
Who started the workflow |
|
OVERDUE_DATE |
Deadline |
|
WORKFLOW_TEMPLATE_ID |
Workflow template identifier |
|
WORKFLOW_TEMPLATE_NAME |
Workflow template name |
|
WORKFLOW_STATE |
Workflow status |
|
STATUS |
Task status. Possible values:
|
|
USER_ID |
User identifier |
|
USER_STATUS |
User response. Possible values:
|
|
MODULE_ID |
Module identifier by document |
|
ENTITY |
Symbolic identifier of the object by document |
|
DOCUMENT_ID |
Document identifier |
|
ACTIVITY |
Task type identifier. Possible values:
|
|
ACTIVITY_NAME |
Action identifier in the template |
|
PARAMETERS |
An object describing the task parameters |
|
DOCUMENT_URL |
Link to the document |
PARAMETERS Object
|
Name |
Description |
|
CommentLabel |
Name of the Comment field |
|
CommentRequired |
Comment requirement. Possible values:
|
|
ShowComment |
Show comment. Possible values:
|
|
StatusOkLabel |
Text for the Acknowledged button |
|
StatusYesLabel |
Text for the Approve button |
|
StatusNoLabel |
Text for the Reject button |
|
Fields |
An array of objects. Each object contains a description of the field in the task |
Fields Object
|
Name |
Description |
|
Id |
Symbolic identifier of the task parameter |
|
Type |
Parameter type. Basic values:
Other types depend on the document with which the workflow operates |
|
Name |
Name of the parameter |
|
Description |
Description of the parameter |
|
Multiple |
Parameter multiplicity. Possible values:
|
|
Required |
Parameter requirement. Possible values:
|
|
Options |
Field settings. Values depend on the parameter type. Examples:
|
|
Settings |
Additional field settings |
|
Default |
Default value of the parameter |
Error Handling
HTTP Status: 400
{
"error": "ACCESS_DENIED",
"error_description": "Access denied!"
}
|
Name |
Description |
|
error |
String error code. It may consist of digits, Latin letters, and underscores |
|
error_description |
Textual description of the error. The description is not intended to be shown to the end user in its raw form |
Possible Error Codes
|
Code |
Error Message |
Description |
|
|
Access denied! |
The method was called by a non-administrator or you cannot view the tasks of the specified employee |
Statuses and System Error Codes
HTTP Status: 20x, 40x, 50x
The errors described below may occur when calling any method.
|
Status |
Code |
Description |
|
|
|
An internal server error has occurred, please contact the server administrator or Bitrix24 technical support |
|
|
|
An internal server error has occurred, please contact the server administrator or Bitrix24 technical support |
|
|
|
The request intensity limit has been exceeded |
|
|
|
The current method is not allowed to be called using batch |
|
|
|
The maximum length of parameters passed to the batch method has been exceeded |
|
|
|
Invalid access token or webhook code |
|
|
|
The methods must be called using the HTTPS protocol |
|
|
|
The REST API is blocked due to overload. This is a manual individual block, to remove it you need to contact Bitrix24 technical support |
|
|
|
The REST API is available only on commercial plans |
|
|
|
The user whose access token or webhook was used to call the method lacks permissions |
|
|
|
The manifest is not available |
|
|
|
The request requires higher privileges than those provided by the webhook token |
|
|
|
The provided access token has expired |
|
|
|
The user does not have access to the application. This means that the application is installed, but the account administrator has allowed access to this application only for specific users |
|
|
|
The public part of the site is closed. To open the public part of the site on an on-premise installation, disable the option "Temporary closure of the public part of the site". Path to the setting: Desktop > Settings > Product Settings > Module Settings > Main Module > Temporary closure of the public part of the site |
Continue Learning
- Workflow Tasks: Overview of Methods
- Complete a business process task bizproc.task.complete
- Delegate a workflow task bizproc.task.delegate
- How to Complete Business Processes of a Terminated Employee
- How to Mass Finish Workflows with Date Filter