Query syntax in GET requests
You can filter for the objects you want to retrieve by specifying a query as the value of the search
query parameter in GET requests. Results are returned as a page of objects in a response message.
Several pages of results may be available, but the page that is returned is the one you request using the page
query parameter. If you want the next page, you must make another request and increment the page number. Set the pageSize
query parameter to the number of objects you want returned in the response message.
The query syntax for the search
parameter in any GET request using the Caseware Cloud API is the following:
<fieldName><operator><fieldValue>
Leaving the query blank will return all the objects in the list.
<fieldName>
is the name of the top-level field you wish to operate on.
Note: Not all fieldNames are valid. The field must be a primitive data type such as text, numbers, Booleans and dates. Complex data types such as collections or objects are not searchable.
Tip: Most of the fields (or query parameters) that can be used to form queries (specified as the value of the search
query parameter) are described in the request body schema in the POST Create operation for the object you are querying. For example, if you are querying entities, see the POST Create operation for entities:
https://{region}.casewarecloud.com/{firm}/sdk/{version-number}/caseware-cloud#tag/Entities/operation/createEntity
Supported relational operators
<operator>
can be any of the following:
- = (equal)
- < (less than)
- > (greater than)
- <> (not equal)
<fieldValue>
can be any scalar value, that is, any single value:
For text, that is, any field whose data type is String, you must specify the value within single quotation marks:
fieldName='test'
For fields whose data type contains special characters such as ‘ or \ must use an escape character (\) in the search query:
fieldName='randomText\’s randomText'
For fields whose data type is number, specify the numeric value without quotation marks:
fieldName=123
For fields whose data type is Boolean, specify either true or false:
fieldName=true
For fields whose data type is date, the date must follow this ISO format:
fieldName='YYYY-MM-DDTHH:MM:SS:Z'
Supported logical operators
To help filter your results, you can combine two or more filter statements with the logical operators AND or OR. The AND operator takes precedence over OR. You must specify a space before and after the operator:
<fieldName><operator><fieldValue> AND <fieldName><operator><fieldValue>
Operator | Description | Example |
---|---|---|
AND | Join two or more filter statements by the AND operator. | countryCode='CA' AND modifyDate>'2022-01-01' |
OR | Join two or more filter statements by the OR operator. | countryCode='US' OR countryCode='CA' |