Examples of URIs Accessing BPM Tasks
This topic shows some examples of how to use uniform resource identifiers (URI) to access BPM tasks or perform an operation on a task.
Filtering Tasks
For collections of tasks, the supported operators for filter expressions are: eq, ne, lt, le, gt, ge, and, or, not, (). The supported function is substringof.
You can optimize task filtering by ensuring that the following conditions are met:
-
Tasks are filtered by one or all of the following properties: Status, Priority, CreatedBy, TaskDefinitionID, CreatedOn, CompletionDeadLine, SubstitutedUser.
-
The or operator is used to logically connect expressions for the same property.
Example: Status eq 'READY' or Status eq 'RESERVED'
-
The and operator is used to logically connect expressions for different properties, or expressions for the same property if they create a date range.
Example: Status eq 'READY' and Priority eq 'HIGH'
Example: CreatedOn ge datetime'2014-01-01T00:00:00' and CreatedOn le datetime'2014-12-31T23:59:59'
-
The following comparison operators are used: eq, ge, le.
Ordering of Tasks
When ordering tasks you can specify the order direction. The default order direction is ascending (asc).
User Search
Creation of Substitution Rules
Getting Number of Tasks
To get a number of tasks, you must specify the $filter query option in the service request URL. The service only considers filter expressions for the Status property of the Task entity type with the value of the $filter query option. The service ignores filter expressions for other properties of the Task entity type without returning an error.