Tomorrow.io · JSON Structure

Insight Condition Structure

A single condition that must hold for an insight to fire.

Type: object Properties: 3 Required: 3
WeatherClimateForecastHistorical WeatherAir QualityPollenFireFloodRoutesMap TilesAviationMaritimePublic APIs

InsightCondition is a JSON Structure definition published by Tomorrow.io, describing 3 properties, of which 3 are required. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

field operator value

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/tomorrow/refs/heads/main/json-structure/insight-condition-structure.json",
  "name": "InsightCondition",
  "description": "A single condition that must hold for an insight to fire.",
  "type": "object",
  "properties": {
    "field": {
      "type": "string",
      "example": "windSpeed"
    },
    "operator": {
      "type": "string",
      "enum": [
        "eq",
        "neq",
        "gt",
        "gte",
        "lt",
        "lte"
      ],
      "example": "gt"
    },
    "value": {
      "type": "double",
      "example": 15
    }
  },
  "required": [
    "field",
    "operator",
    "value"
  ]
}