{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/rotageek/json-schema/rotageek-rotageek-asp-net-core-public-api-models-location-response-model-schema.json",
  "title": "Rotageek.AspNetCore.PublicApi.Models.LocationResponseModel",
  "description": "Container for location response object",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/rotageek-locations-api-openapi.yml#/components/schemas/Rotageek.AspNetCore.PublicApi.Models.LocationResponseModel",
  "required": [
    "id",
    "name",
    "region"
  ],
  "type": "object",
  "properties": {
    "id": {
      "minLength": 1,
      "type": "string",
      "description": "Location id"
    },
    "name": {
      "minLength": 1,
      "type": "string",
      "description": "Location name"
    },
    "region": {
      "$ref": "#/$defs/Rotageek.AspNetCore.PublicApi.Models.LocationRegion"
    },
    "addressLine1": {
      "type": [
        "string",
        "null"
      ],
      "description": "Location first address line"
    },
    "addressLine2": {
      "type": [
        "string",
        "null"
      ],
      "description": "Location second address line"
    },
    "town": {
      "type": [
        "string",
        "null"
      ],
      "description": "Location town"
    },
    "country": {
      "type": [
        "string",
        "null"
      ],
      "description": "Location country"
    },
    "postcode": {
      "type": [
        "string",
        "null"
      ],
      "description": "Location post code"
    },
    "hierarchy": {
      "type": [
        "object",
        "null"
      ],
      "additionalProperties": {
        "type": [
          "string",
          "null"
        ]
      },
      "description": "A sequence (non-ordered) of cluster item specified as \"tier-name\": \"cluster-name\"\nExample:\n{\n    \"Country\": \"England\",\n    \"City\": \"London\",\n    \"Area\": \"West End\"\n}"
    },
    "coordinates": {
      "$ref": "#/$defs/Rotageek.AspNetCore.PublicApi.Models.LocationCoordinates"
    }
  },
  "additionalProperties": false,
  "$defs": {
    "Rotageek.AspNetCore.PublicApi.Models.LocationCoordinates": {
      "type": "object",
      "properties": {
        "latitude": {
          "maximum": 90,
          "minimum": -90,
          "type": "number",
          "description": "Location latitude. Valid range -90 to 90.",
          "format": "double"
        },
        "longitude": {
          "maximum": 180,
          "minimum": -180,
          "type": "number",
          "description": "Location longitude. Valid range -180 to 180.",
          "format": "double"
        }
      },
      "additionalProperties": false
    },
    "Rotageek.AspNetCore.PublicApi.Models.LocationRegion": {
      "enum": [
        "England",
        "Scotland",
        "NorthernIreland",
        "Wales",
        "AustraliaMelbourne",
        "Ireland",
        "Germany",
        "Netherlands",
        "HongKong"
      ],
      "type": "string",
      "description": "Describes available regions for the location"
    }
  }
}