3. Parameters & Filters
CentriCare APIs utilize bracket notation to handle specific field filtering. The base format for applying filters on collection endpoints is:
?field[operator]=value
In addition to specific filters, this API supports standard parameters for pagination and global search. Any empty parameters (null, undefined, or empty strings) will be omitted from the URL.
Standard Parameters (Pagination & Search)
Every collection endpoint (such as GET /v1/patients) accepts the following base parameters:
| Parameter | Type |
|---|---|
limit | number |
offset | number |
s | string |
Filter Operators (Field-Specific)
To perform structured searches on specific fields, use the field[operator]=value format. Multiple filters can be combined using the & symbol.
Nested Field Filtering
To perform searches on nested fields or sub-properties, use dot notation to specify the field path followed by the operator bracket: parent.child[operator]=value.
| Operator | Description |
|---|---|
[eq] | Equal |
[neq] | Not Equal |
[gt] | Greater Than |
[gte] | Greater Than / Equal |
[lt] | Less Than |
[lte] | Less Than / Equal |
[in] | In Array |
[contains] | Contains |