{
"$defs": {
"ConditionFilter": {
"additionalProperties": false,
"properties": {
"condition": {
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"title": "Condition",
"type": "string"
},
"negate": {
"default": false,
"title": "Negate",
"type": "boolean"
}
},
"required": [
"condition"
],
"title": "ConditionFilter",
"type": "object"
},
"FieldFilter": {
"additionalProperties": false,
"properties": {
"field": {
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"title": "Field",
"type": "string"
},
"op": {
"enum": [
"eq",
"ne",
"in",
"gt",
"gte",
"lt",
"lte",
"between",
"is_null",
"not_null"
],
"title": "Op",
"type": "string"
},
"value": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
},
{
"type": "boolean"
},
{
"type": "null"
}
],
"default": null,
"title": "Value"
},
"values": {
"anyOf": [
{
"items": {
"anyOf": [
{
"type": "string"
},
{
"type": "integer"
}
]
},
"maxItems": 50,
"type": "array"
},
{
"type": "null"
}
],
"default": null,
"title": "Values"
}
},
"required": [
"field",
"op"
],
"title": "FieldFilter",
"type": "object"
},
"MeasureSpec": {
"additionalProperties": false,
"properties": {
"alias": {
"anyOf": [
{
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Alias"
},
"field": {
"anyOf": [
{
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Field"
},
"op": {
"enum": [
"count",
"sum",
"min",
"max",
"avg"
],
"title": "Op",
"type": "string"
}
},
"required": [
"op"
],
"title": "MeasureSpec",
"type": "object"
},
"OrderKey": {
"additionalProperties": false,
"properties": {
"direction": {
"enum": [
"asc",
"desc"
],
"title": "Direction",
"type": "string"
},
"field": {
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"title": "Field",
"type": "string"
}
},
"required": [
"field",
"direction"
],
"title": "OrderKey",
"type": "object"
}
},
"additionalProperties": false,
"properties": {
"fields": {
"default": [],
"items": {
"maxLength": 120,
"minLength": 1,
"type": "string"
},
"maxItems": 40,
"title": "Fields",
"type": "array"
},
"filters": {
"default": [],
"items": {
"anyOf": [
{
"$ref": "#/$defs/FieldFilter"
},
{
"$ref": "#/$defs/ConditionFilter"
}
]
},
"maxItems": 16,
"title": "Filters",
"type": "array"
},
"group_by": {
"default": [],
"items": {
"maxLength": 120,
"minLength": 1,
"type": "string"
},
"maxItems": 2,
"title": "Group By",
"type": "array"
},
"identity_ref": {
"anyOf": [
{
"maxLength": 512,
"minLength": 1,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Identity Ref"
},
"limit": {
"default": 20,
"maximum": 50,
"minimum": 1,
"title": "Limit",
"type": "integer"
},
"measures": {
"default": [],
"items": {
"$ref": "#/$defs/MeasureSpec"
},
"maxItems": 4,
"title": "Measures",
"type": "array"
},
"model_checksum": {
"anyOf": [
{
"pattern": "^[0-9a-f]{64}$",
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Model Checksum"
},
"object": {
"maxLength": 120,
"minLength": 1,
"title": "Object",
"type": "string"
},
"operation": {
"enum": [
"lookup",
"list",
"count",
"measure",
"group",
"time_series"
],
"title": "Operation",
"type": "string"
},
"order": {
"default": [],
"items": {
"$ref": "#/$defs/OrderKey"
},
"maxItems": 2,
"title": "Order",
"type": "array"
},
"search": {
"anyOf": [
{
"maxLength": 120,
"minLength": 1,
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Search"
},
"time_field": {
"anyOf": [
{
"pattern": "^[a-z][a-z0-9_]{0,79}$",
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Time Field"
},
"time_grain": {
"anyOf": [
{
"enum": [
"day",
"week",
"month"
],
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"title": "Time Grain"
}
},
"required": [
"object",
"operation"
],
"title": "QueryIn",
"type": "object"
}