Specifying filters
Rules
Rule
type
enum<string>
required
Allowed value:
rule
dimension
enum<string>
required
Allowed values:
apprenticeship_levelapprenticeship_typecategorycompanycontract_hourscontract_typeeducation_levelindustrylocationoccupationqualificationsalaryseniorityskillskill_tagworkplace_modelyears_of_experience
operator
enum<string>
required
Allowed values:
eqneqgteltegtltanynone
target
required
One of
type
enum<string>
required
Allowed value:
object
id
integer
required
name
string
required
taxonomy_id
integer
optional
Example
"filter": {
"type": "rule",
"dimension": "category",
"operator": "eq",
"target": {
"type": "object",
"id": 2,
"name": "IT Jobs"
}
}
Combined rules
CombinedRule
type
enum<string>
required
Allowed value:
combined_rule
logic
enum<string>
required
Allowed values:
andor
groups
array [anyOf]
required
object (Rule)
optional
object (CombinedRule)
optional
Example
"filter": {
"type": "combined_rule",
"logic": "and",
"groups": [
{
"type": "rule",
"dimension": "category",
"operator": "eq",
"target": {
"type": "object",
"id": 2,
"name": "IT Jobs"
}
},
{
"type": "rule",
"dimension": "apprenticeship_level",
"operator": "none"
}
]
}
Any and None operators
any
or none
. When there operators are used, the target
property must be omitted from the rule definition."filter": {
"type": "rule",
"dimension": "apprenticeship_level",
"operator": "any"
}
Filter targets
target
must be specified (unless using the any
or none
operator).ObjectFilterTarget
ObjectFilterTarget
type
enum<string>
required
Allowed value:
object
id
integer
required
name
string
required
Example
"filter": {
"type": "rule",
"dimension": "category",
"operator": "eq",
"target": {
"type": "object",
"id": 2,
"name": "IT Jobs"
}
}
StringFilterTarget
StringFilterTarget
type
enum<string>
required
Allowed value:
string
value
string
required
Example
"filter": {
"type": "rule",
"dimension": "apprenticeship_level",
"operator": "eq",
"target": {
"type": "string",
"value": "level_2"
}
}
ScalarFilterTarget
ScalarFilterTarget
type
enum<string>
required
Allowed value:
scalar
value
number
required
Example
"filter": {
"type": "rule",
"dimension": "salary",
"operator": "gte",
"target": {
"type": "scalar",
"value": 30000
}
}
Modified at 2024-07-24 15:36:34