Filtering
Filters allow you to narrow down your query results. The API supports different filter operators depending on the field type.Filter Structure
- Field Filters
- Metadata Filters
For standard fields, use
fieldName:Filterable Fields
| Field | Type | Description |
|---|---|---|
modelName | string | The name of the LLM model |
requestType | string | Type of request (e.g., “chat”, “completion”) |
userEmail | string | The email of the user making requests |
virtualAccount | string | The virtual account name |
team | array | Teams associated with the request |
latencyMs | number | Request latency in milliseconds |
conversationID | string | The conversation identifier |
virtualModelName | string | The virtual model name |
inputTokens | number | Number of input tokens |
outputTokens | number | Number of output tokens |
Filter Operators
String Field Operators
| Operator | Description | Example Value |
|---|---|---|
EQUAL | Exact match | "gpt-4" |
IN | Match any value in the list | ["gpt-4", "gpt-3.5-turbo"] |
NOT_IN | Exclude values in the list | ["deprecated-model"] |
STRING_CONTAINS | Contains substring | "gpt" |
STRING_STARTS_WITH | Starts with prefix | "gpt-" |
STRING_ENDS_WITH | Ends with suffix | "-turbo" |
GREATER_THAN | Lexicographically greater than | "gpt-3" |
LESS_THAN | Lexicographically less than | "gpt-5" |
GREATER_THAN_EQUAL | Lexicographically greater than or equal | "gpt-3" |
LESS_THAN_EQUAL | Lexicographically less than or equal | "gpt-5" |
BETWEEN | Lexicographically between two values | ["a", "z"] |
Numeric Field Operators
| Operator | Description | Example Value |
|---|---|---|
EQUAL | Exact match | 1000 |
GREATER_THAN | Greater than value | 1000 |
LESS_THAN | Less than value | 5000 |
GREATER_THAN_EQUAL | Greater than or equal to | 100 |
LESS_THAN_EQUAL | Less than or equal to | 1000 |
BETWEEN | Between two values (inclusive) | [500, 5000] |
IN | Match any value in the list | [100, 200, 300] |
NOT_IN | Exclude values in the list | [0] |
Array Field Operators (Teams)
| Operator | Description | Example Value |
|---|---|---|
ARRAY_HAS_ANY | Match if array contains any of the values | ["team-alpha", "team-beta"] |
ARRAY_HAS_NONE | Match if array contains none of the values | ["excluded-team"] |