{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/asterwise-com/json-schema/asterwise-com-api-response-hora-response-schema.json",
  "title": "ApiResponse[HoraResponse]",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/asterwise-com-astro-api-openapi.yml#/components/schemas/ApiResponse_HoraResponse_",
  "properties": {
    "success": {
      "type": "boolean",
      "title": "Success",
      "description": "True if the request succeeded",
      "default": true
    },
    "message": {
      "type": "string",
      "title": "Message",
      "description": "Human-readable status message",
      "default": "success"
    },
    "data": {
      "$ref": "#/$defs/HoraResponse",
      "description": "The endpoint response payload"
    }
  },
  "type": "object",
  "required": [
    "data"
  ],
  "$defs": {
    "HoraPeriod": {
      "properties": {
        "hora": {
          "type": "integer",
          "title": "Hora",
          "description": "Hora number, 1 to 24."
        },
        "ruling_planet": {
          "type": "string",
          "title": "Ruling Planet",
          "description": "Planet ruling this hora."
        },
        "start": {
          "type": "string",
          "title": "Start",
          "description": "Hora start time in HH:MM local time."
        },
        "start_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Start At",
          "description": "Hora start time, ISO 8601 local time with date and UTC offset."
        },
        "start_utc": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Start Utc",
          "description": "Hora start time, ISO 8601 UTC with Z."
        },
        "end": {
          "type": "string",
          "title": "End",
          "description": "Hora end time in HH:MM local time."
        },
        "end_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "End At",
          "description": "Hora end time, ISO 8601 local time with date and UTC offset."
        },
        "end_utc": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "End Utc",
          "description": "Hora end time, ISO 8601 UTC with Z."
        },
        "quality": {
          "type": "string",
          "title": "Quality",
          "description": "Activities suited to this planetary hora."
        },
        "is_current": {
          "type": "boolean",
          "title": "Is Current",
          "description": "True if this hora is currently active."
        }
      },
      "type": "object",
      "required": [
        "hora",
        "ruling_planet",
        "start",
        "end",
        "quality",
        "is_current"
      ],
      "title": "HoraPeriod"
    },
    "HoraResponse": {
      "properties": {
        "status": {
          "type": "string",
          "enum": [
            "ok",
            "no_sunrise"
          ],
          "title": "Status",
          "description": "ok, or no_sunrise when the place has no sunrise or sunset on that date (polar latitudes): the window fields are then null.",
          "default": "ok"
        },
        "status_detail": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Status Detail",
          "description": "Plain-English reason when status is not ok."
        },
        "date": {
          "type": "string",
          "title": "Date",
          "description": "Date for which Hora is calculated (YYYY-MM-DD)."
        },
        "convention": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Convention",
          "description": "Hora division used. ``unequal_seasonal`` = 12 day + 12 night parts from real sunrise/sunset (panchanga / electional)."
        },
        "sunrise": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunrise",
          "description": "Sunrise time in HH:MM local time."
        },
        "sunrise_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunrise At",
          "description": "Sunrise time, ISO 8601 local time with date and UTC offset."
        },
        "sunrise_utc": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunrise Utc",
          "description": "Sunrise time, ISO 8601 UTC with Z."
        },
        "sunset": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunset",
          "description": "Sunset time in HH:MM local time."
        },
        "sunset_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunset At",
          "description": "Sunset time, ISO 8601 local time with date and UTC offset."
        },
        "sunset_utc": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sunset Utc",
          "description": "Sunset time, ISO 8601 UTC with Z."
        },
        "next_sunrise": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Next Sunrise",
          "description": "Next day sunrise time in HH:MM local time."
        },
        "next_sunrise_at": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Next Sunrise At",
          "description": "Next day sunrise time, ISO 8601 local time with date and UTC offset."
        },
        "next_sunrise_utc": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Next Sunrise Utc",
          "description": "Next day sunrise time, ISO 8601 UTC with Z."
        },
        "horas": {
          "anyOf": [
            {
              "items": {
                "$ref": "#/$defs/HoraPeriod"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Horas",
          "description": "24 planetary hours: 12 from sunrise to sunset, then 12 from sunset to next sunrise."
        }
      },
      "type": "object",
      "required": [
        "date"
      ],
      "title": "HoraResponse"
    }
  }
}