- Type:
string
- Default:
""
(no filters) - Scope:
search
filters
parameter lets you specify numeric,
facet, and tag filters using an SQL-like syntax with support for boolean operators and parentheses.
Usage
- All filterable attributes must be listed in
attributesForFaceting
, except for_tags
, which is always available. - You can combine filters using
AND
,OR
, andNOT
, and group expressions with parentheses. - Use quotes for:
- Attribute names or values with spaces.
- Values that conflict with keywords (
AND
,OR
,NOT
). - Values that contain single (
'
) or double ("
) quotes.
Filter types
-
Facet filters
Syntax:
facet:value
Example:category:Book
→ Matches records wherecategory
isBook
Facet names are case-sensitive, facet values are not. -
Boolean filters
Syntax:
facet:true
orfacet:false
Example:isEnabled:true
→ Matches records whereisEnabled
istrue
or"true"
-
Numeric comparisons
Syntax:
facet <operator> value
Operators:<
,<=
,=
,!=
,>=
,>
Example:price > 12.99
-
Numeric ranges
Syntax:
facet:low TO high
Example:price:5.99 TO 100
→ Includes both bounds. -
Tag filters
Syntax:
_tags:value
orvalue
Example:published
→ Matches records where_tags
ispublished
.
Tag matching is case-sensitive. -
Array attributes
A filter matches if it matches any element in the array.
Example:
genres:thriller
matchesgenres: ["fiction", "thriller", "sci-fi"]
. -
Nested attributes
You can filter nested fields if they’re declared in
attributesForFaceting
. Example:authors.mainAuthor:"John Doe"
.
Examples
Current API clients
Current API clients