See Postman example
If you want to filter your dataset, you have to use the filter object. You can filter on both properties and metrics.
Filter on number
| PARAMETER | DESCRIPTION |
|---|
| $eq | Equals to |
| $neq | Does not equal |
| $in | Array |
| $gt | Greater than |
| $gte | Greater or equal to |
| $lt | Lower than |
| $lte | Lower or equal to |
| $na | true or false – NULL value |
| $undefined | true or false – undefined |
| $empty | true or false – combinaison of $na and $undefined |
Filter on string
| PARAMETER | DESCRIPTION |
|---|
| $eq | Equals to |
| $neq | Does not equal |
| $in | Array |
| $lk | Contains |
| $nlk | Does not contain |
| $start | Start with |
| $nstart | Does not start with |
| $end | End with |
| $nend | Does not end with |
| $na | true or false – NULL value |
| $undefined | true or false – undefined |
| $empty | true or false – combinaison of $na and $undefined |
Filter on date
| PARAMETER | DESCRIPTION |
|---|
| $eq | Equals to |
| $gt | Greater than |
| $gte | Greater or equal to |
| $lt | Lower than |
| $lte | Lower or equal to |
Filter on boolean
| PARAMETER | DESCRIPTION |
|---|
| $eq | Equals to |
| $neq | Does not equal |
| $na | true or false – NULL value |
| $undefined | true or false – undefined |
| $empty | true or false – combinaison of $na and $undefined |
For all types of filters it is possible to filter on several values at the same time, for example if you want to make a “contains” filter with values “A” OR “B” OR “C” you can separate them by commas in an array "$lk": [
"A",
"B",
"C"
]
Examples:
// Example: (visit equal to 19) AND (device type equal to Tablet or Desktop) AND (source start by Referrer )
"filter": {
"metric": {
"m_visits": {
"$eq": 19
}
},
"property": {
"$AND": [
{
"$OR": [{
"device_type": {
"$in": ["Tablet","Desktop"]
}
}]
},
{
"visit_src": {
"$start": "Referrer"
}
}
]
}
}# Example: (visit equal to 19) AND (device type equal to Tablet or Desktop) AND (source start by Referrer )
"filter": {
"metric": {
"m_visits": {
"$eq": 19
}
},
"property": {
"$AND": [
{
"$OR": [{
"device_type": {
"$in": ["Tablet","Desktop"]
}
}]
},
{
"visit_src": {
"$start": "Referrer"
}
}
]
}
}# Example: (visit equal to 19) AND (device type equal to Tablet or Desktop) AND (source start by Referrer )
"filter": {
"metric": {
"m_visits": {
"$eq": 19
}
},
"property": {
"$AND": [
{
"$OR": [{
"device_type": {
"$in": ["Tablet","Desktop"]
}
}]
},
{
"visit_src": {
"$start": "Referrer"
}
}
]
}
}# Example: (visit equal to 19) AND (device type equal to Tablet or Desktop) AND (source start by Referrer )
"filter": {
"metric": {
"m_visits": {
"$eq": 19
}
},
"property": {
"$AND": [
{
"$OR": [{
"device_type": {
"$in": ["Tablet","Desktop"]
}
}]
},
{
"visit_src": {
"$start": "Referrer"
}
}
]
}
}