{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/open-government-portugal/json-schema/open-government-portugal-geo-jsonfeature-collection-schema.json",
  "title": "GeoJSONFeatureCollection",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/open-government-portugal-spatial-api-openapi.yml#/components/schemas/GeoJSONFeatureCollection",
  "properties": {
    "features": {
      "items": {
        "$ref": "#/$defs/GeoJSONFeature"
      },
      "type": "array"
    },
    "type": {
      "enum": [
        "FeatureCollection"
      ],
      "type": "string"
    }
  },
  "required": [
    "features",
    "type"
  ],
  "type": "object",
  "$defs": {
    "GeoJSON": {
      "properties": {
        "coordinates": {
          "description": "The geometry as coordinates lists",
          "items": {
            "type": "object"
          },
          "type": "array"
        },
        "type": {
          "description": "The GeoJSON Type",
          "enum": [
            "Point",
            "LineString",
            "Polygon",
            "MultiPoint",
            "MultiLineString",
            "MultiPolygon"
          ],
          "type": "string"
        }
      },
      "required": [
        "coordinates",
        "type"
      ],
      "type": "object"
    },
    "GeoJSONFeature": {
      "properties": {
        "geometry": {
          "$ref": "#/$defs/GeoJSON"
        },
        "id": {
          "type": "string"
        },
        "properties": {
          "type": "object"
        },
        "type": {
          "enum": [
            "Feature"
          ],
          "type": "string"
        }
      },
      "required": [
        "geometry",
        "type"
      ],
      "type": "object"
    }
  }
}