Search and filtering
In v2, every searchable resource uses the same search model. Learn it once, and it works for work orders, operations, items and every resource released later.
This page applies to the v2 API. v1 uses its own
…/bysearchparameterscalls, described in each API's documentation.
Search calls
POST /<resource>/filterreturns rows that match the search criteria.GET /<resource>/inforeturns the resource's fields, their types and its relations to other resources.GET /<resource>/schemareturns the resource structure as JSON Schema.
Get field names from /info. Do not hard-code them from documentation examples.
Search request structure
{
"sf": ["code", "itemCode", "customerName", "department.departmentCode"],
"filter": {
"and": [
{ "department.departmentCode": { "eq": "OS1" } },
{ "customerName": { "like": "oy" } },
{ "plannedCompletionDate": { "gte": 1767225600000 } }
]
},
"sort": [{ "field": "plannedCompletionDate", "specifier": "asc" }],
"pageNumber": 1,
"pageSize": 100
}
sf– the fields the response contains.filter– the search criteria.sort– the sort order.pageNumber,pageSize– paging, see Responses and paging.
Select the returned fields (sf)
Send sf with every search. Without it, the response can contain every field of the row, and its structure is not guaranteed.
To get a field of a related resource, use a dot-separated path, for example department.departmentCode. In the response, related fields come as a nested structure:
{ "code": "J05385", "department": { "departmentCode": "OS1" } }
Search criteria (filter)
A single condition has the form { "<field>": { "<operator>": <value> } }.
eq– equal. Exact match, case-sensitive.not– not equal.lt,lte,gt,gte– less than, less than or equal, greater than, greater than or equal.like– contains the text. Case-insensitive.nlike– does not contain the text. Case-insensitive.in– the value is in the list, for example{ "itemCode": { "in": ["N1", "N2"] } }.nin– the value is not in the list.
An empty-value condition is given as text, without an operator:
{ "customerCode": "isnull" }
{ "customerCode": "isnotnull" }
Combining conditions
Combine conditions with and and or lists. Lists can be nested:
{
"or": [
{ "code": { "eq": "J05385" } },
{ "and": [
{ "itemCode": { "eq": "N1" } },
{ "materials.plannedItemCode": { "in": ["M1", "M2"] } }
] }
]
}
Two rules that are important to know:
- Use one key at the root of the
filterobject. If you have several conditions, put them under oneandlist. Parallel root keys are not combined reliably. - Give one operator per field per condition. A range such as "1–5" takes two conditions in an
andlist:{ "and": [ { "plannedQuantity": { "gte": 1 } }, { "plannedQuantity": { "lte": 5 } } ] }.
Dates
You can give a date field's value in milliseconds since the Unix epoch (UTC). For example, 1767225600000 is 1 January 2026 00:00 UTC.
Sorting (sort)
sort is a list where each item has a field and a direction:
[{ "field": "plannedCompletionDate", "specifier": "asc" }, { "field": "code", "specifier": "desc" }]
The direction is asc or desc. Sorting is applied in list order.
Invalid search criteria
An unknown operator or a malformed value returns a 400 response. The error structure is described on the Errors page.
