{
  "$id": "https://schema.nfh.global/Pathway/v2.0",
  "x-iri": "https://schema.nfh.global/Pathway/v2.0",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Pathway",
  "type": "object",
  "description": "A connection between two points within a transit station (e.g., stairway, elevator, walkway) used for indoor navigation and accessibility routing.",
  "properties": {
    "pathwayId": {
      "description": "Unique identifier for the pathway",
      "type": "string"
    },
    "fromStopId": {
      "description": "Stop at the start of the pathway",
      "$ref": "https://schema.nfh.global/Stop/v2.0/schema.json"
    },
    "toStopId": {
      "description": "Stop at the end of the pathway",
      "$ref": "https://schema.nfh.global/Stop/v2.0/schema.json"
    },
    "pathwayMode": {
      "description": "Type of pathway (1=walkway, 2=stairs, 3=moving_sidewalk, 4=escalator, 5=elevator, 6=fare_gate, 7=exit_gate)",
      "type": "string"
    },
    "isBidirectional": {
      "description": "Whether the pathway can be traversed in both directions",
      "type": "boolean"
    },
    "length": {
      "description": "Length of the pathway in metres",
      "type": "number"
    },
    "traversalTime": {
      "description": "Time in seconds to traverse the pathway",
      "type": "number"
    },
    "id": {
      "description": "Unique identifier for the location",
      "type": "string"
    },
    "descriptor": {
      "description": "Human-readable description of the location",
      "$ref": "https://schema.nfh.global/Descriptor/v2.1/schema.json"
    },
    "gps": {
      "description": "GPS coordinates as a latitude,longitude string",
      "type": "string"
    },
    "address": {
      "description": "Physical address of the location",
      "$ref": "https://schema.nfh.global/Address/v2.0/schema.json"
    },
    "city": {
      "description": "City name",
      "type": "string"
    },
    "country": {
      "description": "ISO 3166-1 alpha-2 country code",
      "type": "string"
    },
    "geojson": {
      "description": "GeoJSON geometry object representing this location",
      "$ref": "https://schema.nfh.global/GeoJSONGeometry/v2.0/schema.json"
    }
  },
  "additionalProperties": false,
  "x-tags": [
    "mobility",
    "geosparql",
    "ride-hailing"
  ]
}
