Get Historic Activity Instance Count (POST)
Queries for the number of historic activity instances that fulfill the given parameters.
Method
POST /history/activity-instance/count
Parameters
Request Body
A JSON object with the following properties:
Name | Description |
---|---|
activityInstanceId | Filter by activity instance id. |
processInstanceId | Filter by process instance id. |
processDefinitionId | Filter by process definition id. |
executionId | Filter by the id of the execution that executed the activity instance. |
activityId | Filter by the activity id (according to BPMN 2.0 XML). |
activityName | Filter by the activity name (according to BPMN 2.0 XML). |
activityType | Filter by activity type. |
taskAssignee | Only include activity instances that are user tasks and assigned to a given user. |
finished | Only include finished activity instances. Value may only be true , as false is the default behavior. |
unfinished | Only include unfinished activity instances. Value may only be true , as false is the default behavior. |
canceled | Only include canceled activity instances. Value may only be true , as false is the default behavior. |
completeScope | Only include activity instances which completed a scope. Value may only be true , as false is the default behavior. |
startedBefore | Restrict to instances that were started before the given date. The date must have the format yyyy-MM-dd'T'HH:mm:ss , e.g., 2013-01-23T14:42:45 . |
startedAfter | Restrict to instances that were started after the given date. The date must have the format yyyy-MM-dd'T'HH:mm:ss , e.g., 2013-01-23T14:42:45 . |
finishedBefore | Restrict to instances that were finished before the given date. The date must have the format yyyy-MM-dd'T'HH:mm:ss , e.g., 2013-01-23T14:42:45 . |
finishedAfter | Restrict to instances that were finished after the given date. The date must have the format yyyy-MM-dd'T'HH:mm:ss , e.g., 2013-01-23T14:42:45 . |
tenantIdIn | Filter by a list of tenant ids. An activity instance must have one of the given tenant ids. Must be a JSON array of Strings. |
Result
A JSON object that contains the count as the only property.
Name | Value | Description |
---|---|---|
count | Number | The number of matching historic activity instances. |
Response Codes
Code | Media type | Description |
---|---|---|
200 | application/json | Request successful. |
400 | application/json | Returned if some of the query parameters are invalid. See the Introduction for the error response format. |
Example
Request
POST /history/activity-instance/count
Request Body:
{
"activityType": "userTask"
}
Response
{
"count": 1
}