{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "type": "object",
  "title": "Coralogix Query Tool",
  "description": "Query Coralogix logs and aggregations",
  "properties": {
    "query": {
      "type": "string",
      "minLength": 1,
      "pattern": "^\\s*\\S+.*$",
      "description": "Lucene/DataPrime query string (non-empty, not just whitespace)"
    },
    "syntax": {
      "type": "string",
      "enum": ["QUERY_SYNTAX_LUCENE", "QUERY_SYNTAX_DATAPRIME"],
      "default": "QUERY_SYNTAX_DATAPRIME",
      "description": "Query syntax type"
    },
    "startDate": {
      "type": "string",
      "format": "date-time",
      "description": "ISO-8601 start date (default: now - 15 min)"
    },
    "endDate": {
      "type": "string",
      "format": "date-time",
      "description": "ISO-8601 end date (default: now)"
    },
    "limit": {
      "type": "integer",
      "minimum": 1,
      "maximum": 1000,
      "description": "Maximum number of results to return"
    }
  },
  "required": ["query"],
  "additionalProperties": false
}
