...
In the response there is no next page token, so there is no more page to display, no more request is needed.
Filtering
With the “filters” query parameter filtering criteria list can be set to reduce the result list for certain entities. The filters are in a JSON structure that is shown below. If there are multiple filtering criteria, the system links them with the logical AND operator.
Code Block | ||
---|---|---|
| ||
{
"filtersList": [
{
"field": "login",
"operator": "STARTS_WITH",
"values": ["john"]
},
{
"field": "id",
"operator": "GREATER_THAN_OR_EQUAL",
"values": [100]
}
]
} |
The example above can be used to search for user entities whose “login” property starts with “john” and their “id” property is grater or equal to 100.
Info |
---|
Not necessarily every property of an entity can be used for filtering. Also, the available operators may be different for the different types of properties. |
The supported properties for filtering can be retrieved from a specific endpoint. Every resource type has their own “options” endpoints. The naming convention of that endpoints follows the structure: /v1/{resource}Options/getAllowedFilters
The following example lists the allowed filtering properties and their allowed operators for user entities.
Request
Code Block |
---|
GET https://{vcf_mr_domain}/verba/restapi/v1/userOptions/getAllowedFilters |
Response
Code Block |
---|
[
{
"operators": [
"EQUAL",
"NOT_EQUAL",
"GREATER_THAN",
"GREATER_THAN_OR_EQUAL",
"LESS_THAN",
"LESS_THAN_OR_EQUAL",
"CONTAINS",
"ENDS_WITH",
"STARTS_WITH",
"LIKE",
"BETWEEN",
"IN",
"NOT_IN"
],
"paramName": "login"
},
{
"operators": [
"EQUAL",
"NOT_EQUAL",
"GREATER_THAN",
"GREATER_THAN_OR_EQUAL",
"LESS_THAN",
"LESS_THAN_OR_EQUAL",
"BETWEEN",
"IN",
"NOT_IN"
],
"paramName": "id"
}
] |
Sorting
The order of entities in the list response can be modified with the “sortBy“ and the “sortOrder“ query parameters. The allowed values of the “sortOrder” parameter is “asc” for ascending and “desc” for descending order.
Info |
---|
Not necessarily every property of an entity can be used for sorting. |
The supported properties for sorting can be retrieved from a specific endpoint. Every resource type has their own “options” endpoints. The naming convention of that endpoints follows the structure: /v1/{resource}Options/getSortableFields
The following example lists the allowed sorting properties for user entities.
Request
Code Block |
---|
GET https://{vcf_mr_domain}/verba/restapi/v1/userOptions/getSortableFields |
Response
Code Block |
---|
[
"login",
"id"
] |