{
 "openapi": "3.1.0",
 "info": {
  "title": "iBus Israel Transport API",
  "version": "1.1.0",
  "summary": "Stops, lines, timetables, realtime arrivals and alerts of Israel's public transport",
  "description": "Public, read-only data of Israel's public transport as served by **iBus Israel**: stops, lines, timetables,\nrealtime arrivals and official service alerts. Source: the Ministry of Transport (GTFS timetable, SIRI realtime, alerts),\nprocessed by iBus.\n\n* **Access by key.** A project gets access after iBus reviews its application (https://api.ibusisrael.online/access/).\n  Send the key in the header `Authorization: Bearer <key>` over HTTPS — never in the URL (`KEY_IN_QUERY`), never in a\n  browser page, an app package or a public repository. A project may restrict its keys to IP addresses.\n* **Limits are per project** (all its keys together): requests per minute with a short burst, per day (UTC), per month\n  (UTC), at the same time, and a separate budget for heavy operations. Over a limit the answer is `429` with\n  `Retry-After`; keyed answers carry `X-RateLimit-Limit` / `X-RateLimit-Remaining`.\n* **Without a key** (transition period): published operations still answer with limits per network; the end of this\n  period is announced on the access page in advance.\n* **Browsers:** cross-origin requests are allowed only for iBus's own web app. Call the API from your server.\n* Accounts, the Lior assistant and the iBus app's own functions are not part of this API.\n* **Times:** `*_utc` fields are UTC (ISO 8601, `Z`). Timetable times are GTFS times of the service date (Israel local\n  time, `HH:MM:SS`, may exceed 24:00:00). Coordinates are WGS 84 decimal degrees; distances in metres; speed in km/h;\n  fares in ILS.\n* **Realtime:** every realtime row carries `freshness` — use only `live` rows as realtime predictions.\n\nGuides in Hebrew, Russian, English and Arabic: https://api.ibusisrael.online/docs/",
  "contact": {
   "name": "iBus Israel",
   "url": "https://ibusisrael.online/contact"
  },
  "termsOfService": "https://ibusisrael.online/terms"
 },
 "servers": [
  {
   "url": "https://api.ibusisrael.online",
   "description": "Production"
  }
 ],
 "security": [
  {
   "ibusKey": []
  }
 ],
 "tags": [
  {
   "name": "Service",
   "description": "Health and data rules"
  },
  {
   "name": "Stops",
   "description": "Stops and stations"
  },
  {
   "name": "Realtime",
   "description": "Live arrivals (SIRI) with freshness"
  },
  {
   "name": "Timetable",
   "description": "GTFS timetable for a service date"
  },
  {
   "name": "Lines",
   "description": "Routes, variants and geometry"
  },
  {
   "name": "Alerts",
   "description": "Official service alerts"
  },
  {
   "name": "Reference",
   "description": "Operators and timetable versions"
  },
  {
   "name": "Access",
   "description": "Your key, project and address as the server sees them"
  }
 ],
 "paths": {
  "/api/transport/healthz": {
   "get": {
    "operationId": "getHealth",
    "tags": [
     "Service"
    ],
    "summary": "Service health",
    "description": "Answers `{\"status\":\"ok\"}` when the transport gateway runs. Cheap; use it for monitoring (not more often than once a minute).",
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Health"
        },
        "example": {
         "status": "ok",
         "env": "prod",
         "service": "ibus-app-transport"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/contract/freshness": {
   "get": {
    "operationId": "getFreshnessContract",
    "tags": [
     "Service"
    ],
    "summary": "Freshness rules of realtime data",
    "description": "The thresholds every realtime row is judged by (seconds): a vehicle observation up to `realtime_live_sec` old is **live**; older is **stale_observation**; past `realtime_hide_eta_sec` the ETA must not be shown as a time; alerts older than `alerts_fresh_sec` are delayed.",
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/FreshnessContract"
        },
        "example": {
         "version": 1,
         "realtime_live_sec": 120,
         "realtime_hide_eta_sec": 1800,
         "alerts_fresh_sec": 900,
         "future_skew_sec": 300,
         "states": [
          "live",
          "stale_observation",
          "scheduled_confirmed",
          "unknown_age"
         ],
         "source_states": [
          "ok",
          "no_data",
          "unavailable"
         ]
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=300"
   }
  },
  "/api/transport/stops/search": {
   "get": {
    "operationId": "searchStops",
    "tags": [
     "Stops"
    ],
    "summary": "Search stops by name or code",
    "description": "Free-text search over stop names (Hebrew / English / Arabic) and stop codes.",
    "parameters": [
     {
      "name": "q",
      "in": "query",
      "required": true,
      "description": "Search text (≥ 1 character)",
      "schema": {
       "type": "string",
       "minLength": 1
      },
      "example": "עזריאלי"
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "minimum": 1,
       "maximum": 100,
       "default": 10
      }
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/StopSearchHit"
         }
        },
        "example": [
         {
          "stop_code": "21378",
          "stop_name": "Azrieli Mall/Highway 20",
          "stop_lat": 32.072545,
          "stop_lon": 34.792553
         },
         {
          "stop_code": "21472",
          "stop_name": "Azrieli Mall/Menahem Begin Road",
          "stop_lat": 32.074584,
          "stop_lon": 34.790607
         },
         {
          "stop_code": "21669",
          "stop_name": "Azrieli Mall/Menahem Begin Road",
          "stop_lat": 32.075726,
          "stop_lon": 34.791623
         }
        ]
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/stop/{stopCode}": {
   "get": {
    "operationId": "getStop",
    "tags": [
     "Stops"
    ],
    "summary": "One stop",
    "description": "Name, position, address and the Rav-Kav tariff zone of a stop.",
    "parameters": [
     {
      "$ref": "#/components/parameters/StopCode"
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Stop"
        },
        "example": {
         "stop_id": "13103",
         "stop_code": "21472",
         "stop_name": "Azrieli Mall/Menahem Begin Road",
         "stop_lat": 32.074584,
         "stop_lon": 34.790607,
         "zone_id": "21472",
         "address": {
          "street": "דרך מנחם בגין",
          "city": "תל אביב יפו",
          "platform": null,
          "floor": null
         },
         "tariff": {
          "zone_code": "210",
          "zone_name": "גוש דן",
          "single": 8.0,
          "daily": 13.0,
          "weekly": 62.5,
          "monthly": 208.5,
          "currency": "ILS"
         }
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=300"
   }
  },
  "/api/transport/nearby_stops": {
   "get": {
    "operationId": "listNearbyStops",
    "tags": [
     "Stops"
    ],
    "summary": "Stops around a point",
    "description": "Stops within `radius` metres of a point, nearest first, with the public numbers of the lines serving each. Names are in Hebrew (source).",
    "parameters": [
     {
      "name": "lat",
      "in": "query",
      "required": true,
      "schema": {
       "type": "number",
       "description": "Latitude, WGS 84, decimal degrees",
       "minimum": -90,
       "maximum": 90
      },
      "example": 32.0745
     },
     {
      "name": "lon",
      "in": "query",
      "required": true,
      "schema": {
       "type": "number",
       "description": "Longitude, WGS 84, decimal degrees",
       "minimum": -180,
       "maximum": 180
      },
      "example": 34.7918
     },
     {
      "name": "radius",
      "in": "query",
      "required": false,
      "description": "Metres",
      "schema": {
       "type": "integer",
       "minimum": 50,
       "maximum": 5000,
       "default": 500
      }
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/NearbyStop"
         }
        },
        "example": [
         {
          "stop_code": "23014",
          "stop_name": "קניון עזריאלי/דרך מנחם בגין",
          "stop_lat": 32.074453,
          "stop_lon": 34.791116,
          "dist_m": 65,
          "lines": [
           "1",
           "148",
           "160",
           "186",
           "194",
           "222"
          ]
         },
         {
          "stop_code": "21472",
          "stop_name": "קניון עזריאלי/דרך מנחם בגין",
          "stop_lat": 32.074584,
          "stop_lon": 34.790607,
          "dist_m": 113,
          "lines": [
           "1",
           "101",
           "103",
           "104",
           "105",
           "111"
          ]
         }
        ]
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/gw/stops/brief": {
   "get": {
    "operationId": "getStopsBrief",
    "tags": [
     "Stops"
    ],
    "summary": "Names and positions of up to 50 stops",
    "description": "Names in three languages, city and position for up to 50 stop codes at once. Codes the timetable no longer has are listed in `missing`.",
    "parameters": [
     {
      "name": "codes",
      "in": "query",
      "required": true,
      "description": "Comma-separated stop codes (≤ 50 used)",
      "schema": {
       "type": "string"
      },
      "example": "21472,41092"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/StopsBrief"
        },
        "example": {
         "stops": [
          {
           "code": "21472",
           "names": {
            "he": "קניון עזריאלי/דרך מנחם בגין",
            "en": "Azrieli Mall/Menahem Begin Road",
            "ar": "مركز تجاري عزريئيلي/طريق مناخم بيغين"
           },
           "city": {
            "he": "תל אביב יפו",
            "en": "Tel Aviv Yafo",
            "ar": "تل ابيب - يافا"
           },
           "lat": 32.074584,
           "lon": 34.790607,
           "kind": "bus",
           "platform": null
          },
          {
           "code": "41092",
           "names": {
            "he": "דרך צרפת/מרסיי",
            "en": "Tsarfat Road/Marseille",
            "ar": "طريق تسرفات/مَرسي"
           },
           "city": {
            "he": "חיפה",
            "en": "Haifa",
            "ar": "حيفا"
           },
           "lat": 32.819942,
           "lon": 34.961482,
           "kind": "bus",
           "platform": null
          }
         ],
         "missing": [],
         "gtfs": "1573439:1792546520472590337"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=600"
   }
  },
  "/api/transport/v2/stop/{stopCode}/arrivals": {
   "get": {
    "operationId": "getStopArrivals",
    "tags": [
     "Realtime"
    ],
    "summary": "Expected arrivals at a stop (realtime)",
    "description": "Vehicles expected at the stop, from the Ministry of Transport's realtime feed (SIRI), soonest first. Each row carries its own `freshness`: only `live` rows are realtime predictions. A stale observation is never presented as live; when the timetable confirms the trip the row becomes `scheduled_confirmed` with the GTFS time. An unknown stop code answers 200 with `source: unknown_stop` and an empty list. Answers are shared for 5 s per stop.",
    "parameters": [
     {
      "$ref": "#/components/parameters/StopCode"
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "minimum": 1,
       "maximum": 200,
       "default": 50
      }
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Arrivals"
        },
        "example": {
         "stopId": "21472",
         "updatedAt": "2026-10-21T17:16:22+03:00",
         "stale": false,
         "arrivals": [
          {
           "vehicle_ref": "AVEexampleVehicle01",
           "line_ref": "9877",
           "route_short_name": "271",
           "agency_id": "3",
           "agency_name": "אגד",
           "stop_point_ref": "21472",
           "direction_ref": "1",
           "dated_vehicle_journey_ref": "9719820",
           "data_frame_ref": "2026-10-21",
           "item_identifier": "1433250322",
           "confidence_level": "probablyReliable",
           "call_order": 17,
           "distance_from_stop_m": 6887,
           "latitude": 32.0769,
           "longitude": 34.792049,
           "bearing": 206.0,
           "velocity": 0.0,
           "motion": "stopped",
           "destination_name": "Yerushalayim Boulevard/Mifrats Shlomo",
           "destination_ref": "35810",
           "direction_text": null,
           "current_stop_name": null,
           "current_stop_code": "21472",
           "origin_aimed_departure_utc": "2026-10-21T13:45:00Z",
           "expected_arrival_utc": "2026-10-21T14:17:00Z",
           "aimed_arrival_utc": null,
           "recorded_at_utc": "2026-10-21T14:16:05Z",
           "expected_in_min": 0,
           "wheelchair_accessible": 1,
           "stops_remaining": 16,
           "freshness": {
            "state": "live",
            "age_sec": 17,
            "observed_at_utc": "2026-10-21T14:16:05Z"
           },
           "observation_age_sec": 17,
           "gtfs_trip_id": "8947270_211026",
           "gtfs_stop_sequence": 17,
           "dest_code": "35810",
           "dest_names": {
            "he": "שדרות ירושלים/מפרץ שלמה",
            "en": "Yerushalayim Boulevard/Mifrats Shlomo",
            "ar": "جادة يروشلايم/خليج شلومو"
           },
           "trust": {
            "v": 1,
            "observed_at_utc": "2026-10-21T14:16:05Z",
            "received_at_utc": "2026-10-21T14:16:22Z",
            "age_sec": 17,
            "freshness": "live",
            "identity": "exact",
            "position": "ok",
            "checks": {
             "motion": "ok",
             "time": "ok",
             "geometry": "unknown",
             "direction": "unknown"
            },
            "issues": [],
            "forecast": "source",
            "verdict": "live"
           },
           "vtok": "EXAMPLEpass1"
          },
          {
           "vehicle_ref": "AVEexampleVehicle02",
           "line_ref": "2454",
           "route_short_name": "42",
           "agency_id": "5",
           "agency_name": "דן",
           "stop_point_ref": "21472",
           "direction_ref": "1",
           "dated_vehicle_journey_ref": "3019375",
           "data_frame_ref": "2026-10-21",
           "item_identifier": "1433250318",
           "confidence_level": "probablyReliable",
           "call_order": 24,
           "distance_from_stop_m": 8190,
           "latitude": 32.080585,
           "longitude": 34.79604,
           "bearing": 248.0,
           "velocity": 0.0,
           "motion": "stopped",
           "destination_name": "ת.רק''ל הקוממיות/דרך בגין",
           "destination_ref": "36108",
           "direction_text": null,
           "current_stop_name": null,
           "current_stop_code": "21472",
           "origin_aimed_departure_utc": "2026-10-21T13:35:00Z",
           "expected_arrival_utc": "2026-10-21T14:17:00Z",
           "aimed_arrival_utc": null,
           "recorded_at_utc": "2026-10-21T14:14:15Z",
           "expected_in_min": 0,
           "wheelchair_accessible": 1,
           "stops_remaining": 23,
           "freshness": {
            "state": "scheduled_confirmed",
            "age_sec": 127,
            "observed_at_utc": "2026-10-21T14:14:15Z",
            "basis": "gtfs_confirmed_stale_observation",
            "scheduled_arrival_utc": "2026-10-21T14:01:54Z"
           },
           "observation_age_sec": 127,
           "stale_observation": true,
           "schedule_confirmed": true,
           "gtfs_trip_id": "3019266_211026",
           "gtfs_stop_sequence": 24,
           "gtfs_scheduled_arrival_utc": "2026-10-21T14:01:54Z",
           "gtfs_scheduled_departure_utc": "2026-10-21T14:01:54Z",
           "dest_code": "36108",
           "dest_names": {
            "he": "ת.רק''ל הקוממיות/דרך בגין",
            "en": "ת.רק''ל הקוממיות/דרך בגין",
            "ar": "ת.רק''ל הקוממיות/דרך בגין"
           },
           "trust": {
            "v": 1,
            "observed_at_utc": "2026-10-21T14:14:15Z",
            "received_at_utc": "2026-10-21T14:16:22Z",
            "age_sec": 127,
            "freshness": "scheduled_confirmed",
            "identity": "exact",
            "position": "ok",
            "checks": {
             "motion": "ok",
             "time": "ok",
             "geometry": "unknown",
             "direction": "unknown"
            },
            "issues": [],
            "forecast": "timetable",
            "verdict": "schedule"
           },
           "vtok": "EXAMPLEpass2"
          }
         ],
         "source": "siri",
         "server_now_utc": "2026-10-21T14:16:22Z",
         "freshness_contract": 1,
         "source_state": "ok"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "realtime",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/stop/{stopCode}/day_schedule": {
   "get": {
    "operationId": "getStopDaySchedule",
    "tags": [
     "Timetable"
    ],
    "summary": "Timetable of a stop for a service date",
    "description": "Every scheduled departure at the stop on a service date (GTFS calendar + calendar_dates of the Ministry of Transport), sorted by GTFS time. Times of trips after midnight are 24:00:00 or later and belong to the SAME service date. Large: a busy stop has thousands of rows (gzip is supported).",
    "parameters": [
     {
      "$ref": "#/components/parameters/StopCode"
     },
     {
      "$ref": "#/components/parameters/Date"
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/StopDaySchedule"
        },
        "example": {
         "stop_code": "21472",
         "date": "20261021",
         "count": 3,
         "departures": [
          {
           "time": "00:03:09",
           "line": "412",
           "route_id": "15545",
           "headsign": "בית שמש_רמת בית שמש ד",
           "direction_id": "1",
           "agency_id": "35",
           "trip_id": "583197553_211026",
           "dest_code": "1448",
           "dest_names": {
            "he": "שדרות האמוראים/רבינא",
            "en": "HaAmora'im Blvd/Ravina",
            "ar": "جادة هأمورائيم/ رفينا"
           }
          },
          {
           "time": "00:20:36",
           "line": "60",
           "route_id": "2509",
           "headsign": "תל אביב יפו_תחנה מרכזית",
           "direction_id": "1",
           "agency_id": "5",
           "trip_id": "34453166_211026",
           "dest_code": "23013",
           "dest_names": {
            "he": "ת.מרכזית תל אביב קומה 7",
            "en": "Tel Aviv Central Bus Station 7th Floor",
            "ar": "محطة مركزية تل أبيب - الطابق 7"
           }
          },
          {
           "time": "25:04:48",
           "line": "840",
           "route_id": "7117",
           "headsign": "תל אביב יפו_תחנה מרכזית",
           "direction_id": "1",
           "agency_id": "3"
          }
         ],
         "server_now_utc": "2026-10-21T14:16:39Z"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "schedule",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/gw/rail/stations": {
   "get": {
    "operationId": "listRailStations",
    "tags": [
     "Stops"
    ],
    "summary": "Israel Railways stations",
    "description": "Stops served by rail trips (GTFS route_type 2) with names in three languages.",
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/RailStations"
        },
        "example": {
         "stations": [
          {
           "code": "17000",
           "names": {
            "he": "פאתי מודיעין",
            "en": "Mode'on Outskirts",
            "ar": "بآتي موديعين"
           },
           "city": null,
           "lat": 31.893133,
           "lon": 34.960682
          },
          {
           "code": "17002",
           "names": {
            "he": "מודיעין מרכז",
            "en": "Mode'ein Center",
            "ar": "موديعين مركز"
           },
           "city": null,
           "lat": 31.901238,
           "lon": 35.005712
          }
         ],
         "source": "GTFS (MOT): stops served by route_type 2 trips",
         "count": 2
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=3600"
   }
  },
  "/api/transport/routes/search": {
   "get": {
    "operationId": "searchLines",
    "tags": [
     "Lines"
    ],
    "summary": "Search lines by public number",
    "description": "Each row is one GTFS route_id (one direction / variant) with its operator and destination.",
    "parameters": [
     {
      "name": "q",
      "in": "query",
      "required": true,
      "description": "Line number (or its beginning)",
      "schema": {
       "type": "string",
       "minLength": 1
      },
      "example": "480"
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "schema": {
       "type": "integer",
       "minimum": 1,
       "maximum": 150,
       "default": 50
      }
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/LineSearchHit"
         }
        },
        "example": [
         {
          "route_id": "10958",
          "route_short_name": "480",
          "route_long_name": "רב החובל/אדם-ירושלים<->ת. רכבת תל אביב - סבידור/הורדה-תל אביב יפו-3ב",
          "agency_id": "3",
          "agency_name": "אגד",
          "dest_code": "27997",
          "dest_names": {
           "he": "ת. רכבת תל אביב - סבידור",
           "en": "Tel Aviv Savidor Train Station",
           "ar": "محطة قطار تل أبيب سفيدور"
          }
         },
         {
          "route_id": "7020",
          "route_short_name": "480",
          "route_long_name": "ת.רכבת תל אביב - סבידור/רציפים B-תל אביב יפו<->ת. מרכזית ירושלים/הורדה-ירושלים-1#",
          "agency_id": "3",
          "agency_name": "אגד",
          "dest_code": "6109",
          "dest_names": {
           "he": "ת. מרכזית ירושלים",
           "en": "Jerusalem Central Bus Station",
           "ar": "محطة مركزية يروشلايم"
          }
         }
        ]
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "422": {
      "$ref": "#/components/responses/Unprocessable"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/line/{routeId}/full": {
   "get": {
    "operationId": "getLine",
    "tags": [
     "Lines"
    ],
    "summary": "A route with its stops",
    "description": "The route, its operator, the calendar of a sample trip and the ordered stops of each direction.",
    "parameters": [
     {
      "$ref": "#/components/parameters/RouteId"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Line"
        },
        "example": {
         "line_ref": "7020",
         "routes": [
          {
           "route_id": "7020",
           "agency_id": "3",
           "route_short_name": "480",
           "route_long_name": "ת.רכבת תל אביב - סבידור/רציפים B-תל אביב יפו<->ת. מרכזית ירושלים/הורדה-ירושלים-1#",
           "route_type": 3,
           "route_color": null
          }
         ],
         "agencies": [
          {
           "agency_id": "3",
           "agency_name": "אגד",
           "agency_url": "http://www.egged.co.il",
           "agency_timezone": "Asia/Jerusalem",
           "agency_phone": "2800"
          }
         ],
         "directions": [
          {
           "route_id": "7020",
           "direction_id": "0",
           "headsign": "ירושלים_תחנה מרכזית",
           "trip_id": "1400822_211026",
           "shape_id": "163609",
           "service_id": "20818",
           "service_days": {
            "sunday": 1,
            "monday": 0,
            "tuesday": 0,
            "wednesday": 0,
            "thursday": 0,
            "friday": 0,
            "saturday": 0,
            "start_date": "20261004",
            "end_date": "22000101"
           },
           "exceptions": {
            "added": 4,
            "removed": 0
           },
           "schedule_window": {
            "first_departure": "00:10:00",
            "last_departure": "23:50:00"
           },
           "stops": [
            {
             "stop_sequence": 1,
             "stop_code": "20740",
             "stop_name": "ת.רכבת תל אביב - סבידור/רציפים B",
             "stop_lat": 32.082918,
             "stop_lon": 34.795635
            },
            {
             "stop_sequence": 2,
             "stop_code": "25069",
             "stop_name": "דרך קיבוץ גלויות/כביש 1",
             "stop_lat": 32.046861,
             "stop_lon": 34.784605
            },
            {
             "stop_sequence": 5,
             "stop_code": "6109",
             "stop_name": "ת. מרכזית ירושלים/הורדה",
             "stop_lat": 31.789082,
             "stop_lon": 35.202487
            }
           ],
           "dest_code": "6109",
           "dest_names": {
            "he": "ת. מרכזית ירושלים",
            "en": "Jerusalem Central Bus Station",
            "ar": "محطة مركزية يروشلايم"
           }
          }
         ],
         "server_now_utc": "2026-10-21T14:16:36Z"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/gw/line/{routeId}/shape": {
   "get": {
    "operationId": "getLineShape",
    "tags": [
     "Lines"
    ],
    "summary": "Road geometry of a route on a date",
    "description": "The shape (polyline) most trips of the route use on the date.",
    "parameters": [
     {
      "$ref": "#/components/parameters/RouteId"
     },
     {
      "$ref": "#/components/parameters/Date"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/LineShape"
        },
        "example": {
         "route_id": "7020",
         "date": "20261021",
         "runs_on_date": true,
         "trips_on_date": 39,
         "other_shapes_on_date": [],
         "shape_id": "163609",
         "coords": [
          [
           34.795694,
           32.082938
          ],
          [
           34.79561,
           32.082631
          ],
          [
           34.795781,
           32.082607
          ]
         ],
         "shape": [
          {
           "lat": 32.082938,
           "lon": 34.795694
          },
          {
           "lat": 32.082631,
           "lon": 34.79561
          },
          {
           "lat": 32.082607,
           "lon": 34.795781
          }
         ],
         "meta": {
          "route_id": "7020",
          "shape_id": "163609",
          "count": 1113,
          "date": "20261021",
          "basis": "most_trips_on_date"
         },
         "shapes_in_calendar": 1
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=600"
   }
  },
  "/api/transport/gw/line/{routeId}/variants": {
   "get": {
    "operationId": "getLineVariants",
    "tags": [
     "Lines"
    ],
    "summary": "Variants of the line a route belongs to",
    "description": "All directions / alternatives of the same public line (operator + Ministry line id) on a date, with first/last departure.",
    "parameters": [
     {
      "$ref": "#/components/parameters/RouteId"
     },
     {
      "$ref": "#/components/parameters/Date"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/RouteVariants"
        },
        "example": {
         "line": {
          "agency": {
           "id": "3",
           "name": "אגד"
          },
          "agency_id": "3",
          "agency_name": "אגד",
          "number": "480",
          "numbers": [
           "480"
          ],
          "makat": "10480",
          "group_basis": "agency+makat"
         },
         "date": "20261021",
         "variants": [
          {
           "route_id": "7020",
           "line": "480",
           "mode": "bus",
           "agency": {
            "id": "3",
            "name": "אגד"
           },
           "makat": "10480",
           "direction": "1",
           "alternative": "#",
           "long_name": "ת.רכבת תל אביב - סבידור/רציפים B-תל אביב יפו<->ת. מרכזית ירושלים/הורדה-ירושלים-1#",
           "runs_on_date": true,
           "trips_on_date": 39,
           "shape_id_on_date": "163609",
           "shape_id": "163609",
           "trips": 39,
           "other_shapes_on_date": [],
           "headsign": {
            "he": "ירושלים_תחנה מרכזית"
           },
           "origin": {
            "stop_id": "48920",
            "code": "20740",
            "name": "ת.רכבת תל אביב - סבידור/רציפים B",
            "names": {
             "he": "ת.רכבת תל אביב - סבידור",
             "en": "Tel Aviv-Savidor Train Stations",
             "ar": "محطة قطار تل أبيب سفيدور"
            },
            "city": {
             "he": "תל אביב יפו",
             "en": "Tel Aviv Yafo",
             "ar": "تل ابيب - يافا"
            },
            "lat": 32.082918,
            "lon": 34.795635
           },
           "destination": {
            "stop_id": "11734",
            "code": "6109",
            "name": "ת. מרכזית ירושלים/הורדה",
            "names": {
             "he": "ת. מרכזית ירושלים",
             "en": "Jerusalem Central Bus Station",
             "ar": "محطة مركزية يروشلايم"
            },
            "city": {
             "he": "ירושלים",
             "en": "Jerusalem",
             "ar": "القدس"
            },
            "lat": 31.789082,
            "lon": 35.202487
           },
           "gtfs_direction_id": "0",
           "stop_count": 5,
           "pattern_basis": "service_date",
           "first_departure": "00:10",
           "last_departure": "23:50",
           "first_dep": "00:10",
           "last_dep": "23:50",
           "first_departure_utc": "2026-10-20T21:10:00Z",
           "last_departure_utc": "2026-10-21T20:50:00Z",
           "requested": true
          }
         ]
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=600"
   }
  },
  "/api/transport/gw/line/variants": {
   "get": {
    "operationId": "findLineVariantsByNumber",
    "tags": [
     "Lines"
    ],
    "summary": "Variants of a public line number",
    "description": "Groups (per operator) of all routes with this public number on a date.",
    "parameters": [
     {
      "name": "number",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string",
       "maxLength": 8
      },
      "example": "480"
     },
     {
      "name": "agency",
      "in": "query",
      "required": false,
      "description": "agency_id (1–4 digits)",
      "schema": {
       "type": "string",
       "pattern": "^[0-9]{1,4}$"
      }
     },
     {
      "$ref": "#/components/parameters/Date"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/LineVariants"
        },
        "example": {
         "number": "480",
         "agency": "3",
         "date": "20261021",
         "detail": "full",
         "groups": [
          {
           "agency": {
            "id": "3",
            "name": "אגד"
           },
           "agency_id": "3",
           "agency_name": "אגד",
           "number": "480",
           "numbers": [
            "480"
           ],
           "makat": "10480",
           "group_basis": "agency+makat",
           "variants": [
            {
             "route_id": "7020",
             "line": "480",
             "mode": "bus",
             "agency": {
              "id": "3",
              "name": "אגד"
             },
             "makat": "10480",
             "direction": "1",
             "alternative": "#",
             "long_name": "ת.רכבת תל אביב - סבידור/רציפים B-תל אביב יפו<->ת. מרכזית ירושלים/הורדה-ירושלים-1#",
             "runs_on_date": true,
             "trips_on_date": 39,
             "shape_id_on_date": "163609",
             "shape_id": "163609",
             "trips": 39,
             "other_shapes_on_date": [],
             "headsign": {
              "he": "ירושלים_תחנה מרכזית"
             },
             "origin": {
              "stop_id": "48920",
              "code": "20740",
              "name": "ת.רכבת תל אביב - סבידור/רציפים B",
              "names": {
               "he": "ת.רכבת תל אביב - סבידור",
               "en": "Tel Aviv-Savidor Train Stations",
               "ar": "محطة قطار تل أبيب سفيدور"
              },
              "city": {
               "he": "תל אביב יפו",
               "en": "Tel Aviv Yafo",
               "ar": "تل ابيب - يافا"
              },
              "lat": 32.082918,
              "lon": 34.795635
             },
             "destination": {
              "stop_id": "11734",
              "code": "6109",
              "name": "ת. מרכזית ירושלים/הורדה",
              "names": {
               "he": "ת. מרכזית ירושלים",
               "en": "Jerusalem Central Bus Station",
               "ar": "محطة مركزية يروشلايم"
              },
              "city": {
               "he": "ירושלים",
               "en": "Jerusalem",
               "ar": "القدس"
              },
              "lat": 31.789082,
              "lon": 35.202487
             },
             "gtfs_direction_id": "0",
             "stop_count": 5,
             "pattern_basis": "service_date",
             "first_departure": "00:10",
             "last_departure": "23:50",
             "first_dep": "00:10",
             "last_dep": "23:50",
             "first_departure_utc": "2026-10-20T21:10:00Z",
             "last_departure_utc": "2026-10-21T20:50:00Z"
            }
           ],
           "runs_on_date": true,
           "trips_on_date": 92,
           "cities": [
            "ירושלים",
            "תל אביב יפו"
           ]
          }
         ]
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=600"
   }
  },
  "/api/transport/line/{routeId}/day_schedule": {
   "get": {
    "operationId": "getLineDaySchedule",
    "tags": [
     "Timetable"
    ],
    "summary": "Departures of a route for a service date",
    "description": "Departure times from the route's first stop on a service date. Same time rules as the stop timetable.",
    "parameters": [
     {
      "$ref": "#/components/parameters/RouteId"
     },
     {
      "$ref": "#/components/parameters/Date"
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/LineDaySchedule"
        },
        "example": {
         "route_id": "7020",
         "date": "20261021",
         "count": 4,
         "departures": [
          {
           "time": "00:10:00",
           "headsign": "ירושלים_תחנה מרכזית"
          },
          {
           "time": "05:20:00",
           "headsign": "ירושלים_תחנה מרכזית"
          },
          {
           "time": "05:50:00",
           "headsign": "ירושלים_תחנה מרכזית"
          },
          {
           "time": "23:50:00",
           "headsign": "ירושלים_תחנה מרכזית"
          }
         ],
         "server_now_utc": "2026-10-21T14:16:38Z"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "schedule",
    "x-ibus-cache": "no-store"
   }
  },
  "/api/transport/alerts": {
   "get": {
    "operationId": "listAlerts",
    "tags": [
     "Alerts"
    ],
    "summary": "Service alerts",
    "description": "Official service alerts of the Ministry of Transport (detours, moved or cancelled stops, works …), refreshed about every 5 minutes.",
    "parameters": [
     {
      "name": "status",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "enum": [
        "active",
        "today",
        "upcoming",
        "all"
       ]
      }
     },
     {
      "name": "type",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string",
       "enum": [
        "detour",
        "delay",
        "stop_moved",
        "stop_cancelled",
        "works",
        "route_change",
        "other"
       ]
      }
     },
     {
      "name": "line",
      "in": "query",
      "required": false,
      "description": "Public line number",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "operator",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "city",
      "in": "query",
      "required": false,
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "stop",
      "in": "query",
      "required": false,
      "description": "Stop code",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "q",
      "in": "query",
      "required": false,
      "description": "Free text",
      "schema": {
       "type": "string"
      }
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/AlertList"
        },
        "example": {
         "configured": true,
         "updated_ts": 1792591800,
         "updated_at": "2026-10-21T14:10:00Z",
         "stale": false,
         "error": null,
         "source": "MOT",
         "count": 1,
         "alerts": [
          {
           "id": "14455262371",
           "sourceId": "14455262371",
           "source": "MOT",
           "type": "detour",
           "cause": "CONSTRUCTION",
           "effect": "DETOUR",
           "title": "אילת - חימה רציפה בקטע מדרך הרים. החל מיום ראשון 6/9/2026 ועד יום חמישי 29/10/2026.",
           "description": "החל מתחילת השירות ביום ראשון 6/9/2026 ועד גמר השירות ביום חמישי 29/10/2026 תיחסם לתנועה דרך הרים, בקטע: עין יהב – שרה אמנו, בשני הכיוונים, עקב עבודות.\n\nקו 3 משחמון: ייצא כרגיל וימשיך בכיכר שדרות ששת הימים/ שרה אמנו ישר בשדרות ששת הימים, יפנ…",
           "rawText": "החל מתחילת השירות ביום ראשון 6/9/2026 ועד גמר השירות ביום חמישי 29/10/2026 תיחסם לתנועה דרך הרים, בקטע: עין יהב – שרה אמנו, בשני הכיוונים, עקב עבודות.\n\nקו 3 משחמון: ייצא כרגיל וימשיך בכיכר שדרות ששת הימים/ שרה אמנו ישר בשדרות ששת הימים, יפנ…",
           "url": null,
           "status": "active",
           "activeNow": true,
           "relevantToday": true,
           "upcoming": false,
           "startTime": "2026-09-06T02:00:00Z",
           "endTime": "2026-10-29T20:00:00Z",
           "dateRanges": [
            {
             "start": 1788660000,
             "end": 1791316800,
             "start_utc": "2026-09-06T02:00:00Z",
             "end_utc": "2026-10-06T20:00:00Z"
            },
            {
             "start": 1791316800,
             "end": 1793304000,
             "start_utc": "2026-10-06T20:00:00Z",
             "end_utc": "2026-10-29T20:00:00Z"
            }
           ],
           "cities": [
            "אילת"
           ],
           "operators": [
            "אגד"
           ],
           "affectedLines": [
            {
             "line": "80",
             "agency": "אגד",
             "route_id": "19745"
            },
            {
             "line": "32",
             "agency": "אגד",
             "route_id": "25348"
            }
           ],
           "affectedRouteIds": [
            "19745",
            "25348"
           ],
           "affectedStops": [
            {
             "stop_id": "28961",
             "code": "19475",
             "name": "דרך הרים/עין יהב",
             "lat": 29.545905,
             "lon": 34.926003,
             "city": "אילת"
            }
           ],
           "hasGeo": true,
           "sourceUpdatedAt": "2026-10-21T14:10:00Z",
           "permalink": "/alerts/14455262371"
          }
         ]
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "alerts",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/alerts/{alertId}": {
   "get": {
    "operationId": "getAlert",
    "tags": [
     "Alerts"
    ],
    "summary": "One service alert",
    "description": "An alert while it is in the current feed; afterwards 404.",
    "parameters": [
     {
      "name": "alertId",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[0-9A-Za-z_.:-]{1,80}$"
      }
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/AlertEnvelope"
        },
        "example": {
         "alert": {
          "id": "14455262371",
          "sourceId": "14455262371",
          "source": "MOT",
          "type": "detour",
          "cause": "CONSTRUCTION",
          "effect": "DETOUR",
          "title": "אילת - חימה רציפה בקטע מדרך הרים. החל מיום ראשון 6/9/2026 ועד יום חמישי 29/10/2026.",
          "description": "החל מתחילת השירות ביום ראשון 6/9/2026 ועד גמר השירות ביום חמישי 29/10/2026 תיחסם לתנועה דרך הרים, בקטע: עין יהב – שרה אמנו, בשני הכיוונים, עקב עבודות.\n\nקו 3 משחמון: ייצא כרגיל וימשיך בכיכר שדרות ששת הימים/ שרה אמנו ישר בשדרות ששת הימים, יפנ…",
          "rawText": "החל מתחילת השירות ביום ראשון 6/9/2026 ועד גמר השירות ביום חמישי 29/10/2026 תיחסם לתנועה דרך הרים, בקטע: עין יהב – שרה אמנו, בשני הכיוונים, עקב עבודות.\n\nקו 3 משחמון: ייצא כרגיל וימשיך בכיכר שדרות ששת הימים/ שרה אמנו ישר בשדרות ששת הימים, יפנ…",
          "url": null,
          "status": "active",
          "activeNow": true,
          "relevantToday": true,
          "upcoming": false,
          "startTime": "2026-09-06T02:00:00Z",
          "endTime": "2026-10-29T20:00:00Z",
          "dateRanges": [
           {
            "start": 1788660000,
            "end": 1791316800,
            "start_utc": "2026-09-06T02:00:00Z",
            "end_utc": "2026-10-06T20:00:00Z"
           },
           {
            "start": 1791316800,
            "end": 1793304000,
            "start_utc": "2026-10-06T20:00:00Z",
            "end_utc": "2026-10-29T20:00:00Z"
           }
          ],
          "cities": [
           "אילת"
          ],
          "operators": [
           "אגד"
          ],
          "affectedLines": [
           {
            "line": "80",
            "agency": "אגד",
            "route_id": "19745"
           },
           {
            "line": "32",
            "agency": "אגד",
            "route_id": "25348"
           }
          ],
          "affectedRouteIds": [
           "19745",
           "25348"
          ],
          "affectedStops": [
           {
            "stop_id": "28961",
            "code": "19475",
            "name": "דרך הרים/עין יהב",
            "lat": 29.545905,
            "lon": 34.926003,
            "city": "אילת"
           }
          ],
          "hasGeo": true,
          "sourceUpdatedAt": "2026-10-21T14:10:00Z",
          "permalink": "/alerts/14455262371"
         },
         "updated_at": "2026-10-21T14:10:00Z",
         "stale": false,
         "source": "MOT"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "alerts",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/alerts/by-stop/{stopCode}": {
   "get": {
    "operationId": "listAlertsByStop",
    "tags": [
     "Alerts"
    ],
    "summary": "Alerts affecting a stop",
    "description": "Current alerts that name this stop.",
    "parameters": [
     {
      "$ref": "#/components/parameters/StopCode"
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/AlertList"
        },
        "example": {
         "configured": true,
         "updated_ts": 1792591800,
         "updated_at": "2026-10-21T14:10:00Z",
         "stale": false,
         "error": null,
         "source": "MOT",
         "count": 0,
         "alerts": []
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "alerts",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/alerts/by-line/{agencyId}/{routeId}": {
   "get": {
    "operationId": "listAlertsByLine",
    "tags": [
     "Alerts"
    ],
    "summary": "Alerts affecting a route",
    "description": "Current alerts for a route of an operator (numeric agency_id matched against each affected line).",
    "parameters": [
     {
      "name": "agencyId",
      "in": "path",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[0-9A-Za-z_.:-]{1,80}$"
      },
      "example": "3"
     },
     {
      "$ref": "#/components/parameters/RouteId"
     },
     {
      "$ref": "#/components/parameters/Lang"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/AlertList"
        },
        "example": {
         "configured": true,
         "updated_ts": 1792591800,
         "updated_at": "2026-10-21T14:10:00Z",
         "stale": false,
         "error": null,
         "source": "MOT",
         "count": 0,
         "alerts": [],
         "gateway_filter": {
          "agency_id": "3",
          "by": "route_id",
          "note": "numeric agency id matched by the GTFS agency_id of each affected route_id"
         }
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "404": {
      "$ref": "#/components/responses/NotFound"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "alerts",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/agencies": {
   "get": {
    "operationId": "listAgencies",
    "tags": [
     "Reference"
    ],
    "summary": "Operators",
    "description": "Transport operators of the timetable (GTFS agency.txt).",
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/Agency"
         }
        },
        "example": [
         {
          "agency_id": "3",
          "agency_name": "אגד",
          "agency_url": "http://www.egged.co.il",
          "agency_phone": "2800",
          "agency_timezone": "Asia/Jerusalem"
         },
         {
          "agency_id": "97",
          "agency_name": "אודליה מוניות בעמ",
          "agency_url": "http://www.bus.gov.il",
          "agency_phone": "8787",
          "agency_timezone": "Asia/Jerusalem"
         },
         {
          "agency_id": "25",
          "agency_name": "אלקטרה אפיקים",
          "agency_url": "https://www.electra-afikim.co.il/",
          "agency_phone": "6686",
          "agency_timezone": "Asia/Jerusalem"
         }
        ]
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=300"
   }
  },
  "/api/transport/stops/version": {
   "get": {
    "operationId": "getStopsVersion",
    "tags": [
     "Reference"
    ],
    "summary": "Version of the stop list",
    "description": "Changes when a new timetable is published (nightly). Use it to know when your cached stops are outdated.",
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/StopsVersion"
        },
        "example": {
         "version": "1792546520"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=60"
   }
  },
  "/api/transport/gw/service-day": {
   "get": {
    "operationId": "getServiceDay",
    "tags": [
     "Reference"
    ],
    "summary": "Is a date in the timetable — and is it a usual day",
    "description": "Whether a date is inside the published timetable (`feed.from` … `feed.to`) and whether it differs from the usual same weekday (holidays, special days).",
    "parameters": [
     {
      "name": "date",
      "in": "query",
      "required": true,
      "schema": {
       "type": "string",
       "pattern": "^[0-9]{8}$"
      },
      "example": "20261021"
     }
    ],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "Caching policy of this answer",
        "schema": {
         "type": "string"
        }
       },
       "X-Request-ID": {
        "description": "Echo of your X-Request-ID (8–40 of A–Z a–z 0–9 -), when you sent one",
        "schema": {
         "type": "string"
        }
       },
       "X-RateLimit-Limit": {
        "description": "Keyed requests: your project's requests per minute",
        "schema": {
         "type": "integer"
        }
       },
       "X-RateLimit-Remaining": {
        "description": "Keyed requests: what is left of the current minute",
        "schema": {
         "type": "integer"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/ServiceDay"
        },
        "example": {
         "date": "20261021",
         "weekday": 3,
         "in_feed": true,
         "feed": {
          "from": "20261021",
          "to": "20261120"
         },
         "services": 13173,
         "usual": 13584,
         "compared": [
          "20261028",
          "20261104"
         ],
         "added": 9768,
         "removed": 0,
         "differs": false,
         "fewer": false,
         "source": "GTFS calendar + calendar_dates (MOT)"
        }
       }
      }
     },
     "400": {
      "$ref": "#/components/responses/KeyInQuery"
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "502": {
      "$ref": "#/components/responses/Unavailable"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     },
     "504": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "reference",
    "x-ibus-cache": "public, max-age=600"
   }
  },
  "/api/access/whoami": {
   "get": {
    "operationId": "whoami",
    "tags": [
     "Access"
    ],
    "summary": "What the server sees about your request",
    "description": "The client address the server saw (`ip_seen`) and — with a key — `checks` in the order of the data path: the secret, the key, the project, the address. A refusal stops at the first failing check and returns only its code, the key's public prefix and `ip_seen` (a revoked or expired key, a paused or blocked project and a foreign address never see the project's name, groups, limits or usage). Costs no data quota but is limited to 30 calls per minute per network. Never put a key in the URL.",
    "security": [
     {},
     {
      "ibusKey": []
     }
    ],
    "parameters": [],
    "responses": {
     "200": {
      "description": "OK",
      "headers": {
       "Cache-Control": {
        "description": "no-store",
        "schema": {
         "type": "string"
        }
       }
      },
      "content": {
       "application/json": {
        "schema": {
         "$ref": "#/components/schemas/Whoami"
        },
        "examples": {
         "anonymous": {
          "value": {
           "authenticated": false,
           "ip_seen": "203.0.113.24",
           "request_id": "r-5f2c9f",
           "time_utc": "2026-10-22T09:15:04Z",
           "anonymous_modes": {
            "transport": "compat",
            "legacy": "compat"
           }
          }
         },
         "key": {
          "value": {
           "authenticated": true,
           "ip_seen": "203.0.113.24",
           "request_id": "r-5f2ca0",
           "time_utc": "2026-10-22T09:15:05Z",
           "key": {
            "prefix": "ibk_live_k_7mq2xw4hzt",
            "env": "live",
            "status": "active",
            "expires_at": null
           },
           "project": {
            "id": "prj_3f9a1c0d2e",
            "name": "Lobby board",
            "status": "active",
            "access_until": null
           },
           "checks": {
            "secret": "recognized",
            "key": "valid",
            "project": "active",
            "ip": "allowed"
           },
           "groups": [
            "realtime",
            "stops"
           ],
           "limits": {
            "rpm": 30,
            "burst": 10,
            "daily": 1000,
            "monthly": 20000,
            "concurrency": 2,
            "heavy_rpm": 0,
            "heavy_daily": 0
           },
           "usage": {
            "day_used": 112,
            "month_used": 2390,
            "minute_remaining": 28
           }
          }
         }
        }
       }
      }
     },
     "401": {
      "$ref": "#/components/responses/Unauthorized"
     },
     "403": {
      "$ref": "#/components/responses/Forbidden"
     },
     "429": {
      "$ref": "#/components/responses/RateLimited"
     },
     "503": {
      "$ref": "#/components/responses/Unavailable"
     }
    },
    "x-ibus-data-kind": "access"
   }
  }
 },
 "components": {
  "schemas": {
   "Error": {
    "type": "object",
    "properties": {
     "code": {
      "type": "string",
      "description": "Machine-readable code. Access: KEY_REQUIRED, KEY_INVALID, KEY_REVOKED, KEY_EXPIRED, KEY_IN_QUERY, GROUP_NOT_ALLOWED, OPERATION_NOT_AVAILABLE, IP_NOT_ALLOWED, PROJECT_SUSPENDED, PROJECT_BLOCKED, ACCESS_EXPIRED, PLATE_LOOKUP_NOT_ALLOWED, RATE_LIMITED, QUOTA_EXCEEDED, CONCURRENCY_LIMIT, TEMPORARILY_RESTRICTED, CAPACITY_RESERVED, POLICY_UNAVAILABLE, EXTERNAL_PAUSED. Data: BAD_REQUEST, NOT_FOUND, METHOD_NOT_ALLOWED, GATEWAY_BUSY, UPSTREAM_TIMEOUT, UPSTREAM_UNAVAILABLE, UPSTREAM_BAD_ANSWER, SOURCE_UNAVAILABLE, TIMETABLE_UNAVAILABLE, ROUTE_NOT_FOUND, or UPSTREAM_<status> (the status of the internal transport service, e.g. UPSTREAM_404, UPSTREAM_422 for an invalid query parameter)."
     },
     "docs": {
      "type": "string",
      "description": "Access errors: a link to the explanation of this code"
     },
     "request_id": {
      "type": "string",
      "description": "Access errors: the id of this request — quote it when you ask iBus about a refusal"
     },
     "ip_seen": {
      "type": "string",
      "description": "IP_NOT_ALLOWED / KEY_INVALID: the client address the server saw"
     },
     "scope": {
      "type": "string",
      "description": "QUOTA_EXCEEDED: which budget is used up (`day`, `month`, `heavy_day`)"
     },
     "detail": {
      "type": "string",
      "description": "Short technical hint (may be empty). Never shown to passengers as is."
     },
     "source_state": {
      "type": [
       "string",
       "null"
      ],
      "enum": [
       "unavailable",
       null
      ],
      "description": "`unavailable` when a data source failed (5xx)"
     }
    },
    "additionalProperties": false,
    "required": [
     "code",
     "detail"
    ],
    "description": "Error envelope of every /api/transport answer that is not 2xx"
   },
   "LocalizedNames": {
    "type": "object",
    "properties": {
     "he": {
      "type": "string"
     },
     "en": {
      "type": "string"
     },
     "ar": {
      "type": "string"
     }
    },
    "additionalProperties": true,
    "description": "The same name in Hebrew (source), English and Arabic (GTFS translations of the Ministry of Transport). A language may be missing."
   },
   "Freshness": {
    "type": "object",
    "properties": {
     "state": {
      "type": "string",
      "enum": [
       "live",
       "stale_observation",
       "scheduled_confirmed",
       "unknown_age"
      ],
      "description": "live: observation ≤ 120 s old; stale_observation: older, the ETA is not live; scheduled_confirmed: the observation is old but the GTFS timetable confirms this trip at this stop today (time from GTFS); unknown_age: no usable observation time"
     },
     "age_sec": {
      "type": [
       "integer",
       "null"
      ],
      "minimum": 0,
      "description": "Age of the vehicle's own observation (server clock)"
     },
     "observed_at_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "basis": {
      "type": "string",
      "description": "How a scheduled_confirmed row was confirmed (e.g. gtfs_confirmed_stale_observation)"
     },
     "scheduled_arrival_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "eta_hidden": {
      "type": "boolean",
      "description": "true when the observation is older than 30 min: do not show its ETA as a time"
     }
    },
    "additionalProperties": true,
    "required": [
     "state",
     "age_sec",
     "observed_at_utc"
    ],
    "description": "Freshness of one realtime row (contract v1, see getFreshnessContract)"
   },
   "Trust": {
    "type": "object",
    "properties": {
     "v": {
      "type": "integer"
     },
     "verdict": {
      "type": "string",
      "description": "Summary used by the iBus app (live, schedule, suspect, unknown …)"
     },
     "freshness": {
      "type": "string"
     },
     "identity": {
      "type": "string",
      "description": "exact: the GTFS trip is resolved uniquely; unconfirmed otherwise"
     },
     "position": {
      "type": "string"
     },
     "forecast": {
      "type": "string",
      "description": "source | timetable | none"
     },
     "age_sec": {
      "type": [
       "integer",
       "null"
      ]
     },
     "observed_at_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "received_at_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "checks": {
      "type": "object",
      "properties": {
       "motion": {
        "type": "string"
       },
       "time": {
        "type": "string"
       },
       "geometry": {
        "type": "string"
       },
       "direction": {
        "type": "string"
       }
      },
      "additionalProperties": true
     },
     "issues": {
      "type": "array",
      "items": {
       "type": "string"
      }
     }
    },
    "additionalProperties": true,
    "description": "Plausibility checks of a realtime row made by iBus. Informational; the structure may grow."
   },
   "StopSearchHit": {
    "type": "object",
    "properties": {
     "stop_code": {
      "type": "string",
      "description": "Public stop code (the number on the stop sign)"
     },
     "stop_name": {
      "type": "string"
     },
     "stop_lat": {
      "type": "number",
      "description": "Latitude, WGS 84, decimal degrees",
      "minimum": -90,
      "maximum": 90
     },
     "stop_lon": {
      "type": "number",
      "description": "Longitude, WGS 84, decimal degrees",
      "minimum": -180,
      "maximum": 180
     }
    },
    "additionalProperties": true,
    "required": [
     "stop_code",
     "stop_name",
     "stop_lat",
     "stop_lon"
    ]
   },
   "Stop": {
    "type": "object",
    "properties": {
     "stop_id": {
      "type": "string",
      "description": "Internal GTFS stop_id (not the public code)"
     },
     "stop_code": {
      "type": "string"
     },
     "stop_name": {
      "type": "string"
     },
     "stop_lat": {
      "type": "number",
      "description": "Latitude, WGS 84, decimal degrees",
      "minimum": -90,
      "maximum": 90
     },
     "stop_lon": {
      "type": "number",
      "description": "Longitude, WGS 84, decimal degrees",
      "minimum": -180,
      "maximum": 180
     },
     "zone_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "address": {
      "type": "object",
      "properties": {
       "street": {
        "type": [
         "string",
         "null"
        ]
       },
       "city": {
        "type": [
         "string",
         "null"
        ]
       },
       "platform": {
        "type": [
         "string",
         "null"
        ]
       },
       "floor": {
        "type": [
         "string",
         "null"
        ]
       }
      },
      "additionalProperties": true
     },
     "tariff": {
      "type": [
       "object",
       "null"
      ],
      "description": "Rav-Kav tariff zone and fares (ILS) when known: zone_code, zone_name, single, daily, weekly, monthly, currency"
     }
    },
    "additionalProperties": true,
    "required": [
     "stop_code",
     "stop_name",
     "stop_lat",
     "stop_lon"
    ]
   },
   "NearbyStop": {
    "type": "object",
    "properties": {
     "stop_code": {
      "type": "string"
     },
     "stop_name": {
      "type": "string",
      "description": "Source (Hebrew) name"
     },
     "stop_lat": {
      "type": "number",
      "description": "Latitude, WGS 84, decimal degrees",
      "minimum": -90,
      "maximum": 90
     },
     "stop_lon": {
      "type": "number",
      "description": "Longitude, WGS 84, decimal degrees",
      "minimum": -180,
      "maximum": 180
     },
     "dist_m": {
      "type": "integer",
      "description": "Straight-line distance from the given point, metres",
      "minimum": 0
     },
     "lines": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "description": "Public line numbers serving the stop"
     }
    },
    "additionalProperties": true,
    "required": [
     "stop_code",
     "stop_name",
     "stop_lat",
     "stop_lon",
     "dist_m"
    ]
   },
   "StopBrief": {
    "type": "object",
    "properties": {
     "code": {
      "type": "string"
     },
     "names": {
      "$ref": "#/components/schemas/LocalizedNames"
     },
     "city": {
      "type": [
       "object",
       "null"
      ],
      "description": "LocalizedNames of the city"
     },
     "lat": {
      "type": "number",
      "description": "Latitude, WGS 84, decimal degrees",
      "minimum": -90,
      "maximum": 90
     },
     "lon": {
      "type": "number",
      "description": "Longitude, WGS 84, decimal degrees",
      "minimum": -180,
      "maximum": 180
     },
     "kind": {
      "type": "string",
      "description": "bus | rail | light_rail …"
     },
     "platform": {
      "type": [
       "string",
       "null"
      ]
     }
    },
    "additionalProperties": true,
    "required": [
     "code",
     "lat",
     "lon"
    ]
   },
   "StopsBrief": {
    "type": "object",
    "properties": {
     "stops": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/StopBrief"
      }
     },
     "missing": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "description": "Codes the current timetable does not have"
     },
     "gtfs": {
      "type": [
       "string",
       "null"
      ],
      "description": "Version of the timetable used"
     }
    },
    "additionalProperties": true,
    "required": [
     "stops",
     "missing"
    ]
   },
   "Arrival": {
    "type": "object",
    "properties": {
     "vehicle_ref": {
      "type": "string",
      "description": "Opaque vehicle id: a daily pseudonym (changes every UTC day), never the licence plate"
     },
     "line_ref": {
      "type": "string",
      "description": "GTFS route_id of the trip (one direction/variant of a line)"
     },
     "route_short_name": {
      "type": "string",
      "description": "Public line number"
     },
     "agency_id": {
      "type": "string"
     },
     "agency_name": {
      "type": "string"
     },
     "stop_point_ref": {
      "type": "string"
     },
     "direction_ref": {
      "type": "string",
      "description": "SIRI direction (1/2) — not the GTFS direction_id"
     },
     "dated_vehicle_journey_ref": {
      "type": "string",
      "description": "SIRI journey id of the Ministry (not a GTFS trip_id)"
     },
     "data_frame_ref": {
      "type": "string",
      "description": "Service date of the journey, YYYY-MM-DD"
     },
     "expected_arrival_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "aimed_arrival_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "recorded_at_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "origin_aimed_departure_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "expected_in_min": {
      "type": [
       "integer",
       "null"
      ],
      "description": "Whole minutes until expected arrival (server clock)"
     },
     "latitude": {
      "type": [
       "number",
       "null"
      ]
     },
     "longitude": {
      "type": [
       "number",
       "null"
      ]
     },
     "bearing": {
      "type": [
       "number",
       "null"
      ],
      "description": "Degrees, 0 = north"
     },
     "velocity": {
      "type": [
       "number",
       "null"
      ],
      "description": "km/h"
     },
     "distance_from_stop_m": {
      "type": [
       "integer",
       "null"
      ]
     },
     "stops_remaining": {
      "type": [
       "integer",
       "null"
      ]
     },
     "wheelchair_accessible": {
      "type": [
       "integer",
       "null"
      ],
      "description": "As reported by the source (1 = yes, 2 = no, 0/null = unknown)"
     },
     "destination_ref": {
      "type": [
       "string",
       "null"
      ]
     },
     "destination_name": {
      "type": [
       "string",
       "null"
      ]
     },
     "dest_code": {
      "type": "string",
      "description": "Stop code of the trip's last stop"
     },
     "dest_names": {
      "$ref": "#/components/schemas/LocalizedNames"
     },
     "is_scheduled": {
      "type": "boolean",
      "description": "true: a timetable row (no live vehicle)"
     },
     "stale_observation": {
      "type": "boolean"
     },
     "schedule_confirmed": {
      "type": "boolean"
     },
     "gtfs_trip_id": {
      "type": "string"
     },
     "gtfs_stop_sequence": {
      "type": "integer"
     },
     "gtfs_scheduled_arrival_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "gtfs_scheduled_departure_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "observation_age_sec": {
      "type": [
       "integer",
       "null"
      ]
     },
     "freshness": {
      "$ref": "#/components/schemas/Freshness"
     },
     "trust": {
      "$ref": "#/components/schemas/Trust"
     },
     "vtok": {
      "type": "string",
      "description": "Internal short-lived pass of the iBus app. Not part of the public contract."
     }
    },
    "additionalProperties": true,
    "required": [
     "line_ref",
     "route_short_name",
     "freshness"
    ],
    "description": "One expected arrival at the stop"
   },
   "Arrivals": {
    "type": "object",
    "properties": {
     "stopId": {
      "type": "string"
     },
     "updatedAt": {
      "type": [
       "string",
       "null"
      ],
      "description": "When the source answer was received (Israel local time with offset)"
     },
     "stale": {
      "type": "boolean"
     },
     "source": {
      "type": "string",
      "description": "siri, or unknown_stop when the code is not in the timetable"
     },
     "source_state": {
      "type": "string",
      "enum": [
       "ok",
       "no_data",
       "unavailable"
      ],
      "description": "ok | no_data (the source answered: nothing) | unavailable"
     },
     "server_now_utc": {
      "type": "string",
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z"
     },
     "freshness_contract": {
      "type": "integer",
      "description": "Version of the freshness contract (1)"
     },
     "arrivals": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/Arrival"
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "stopId",
     "arrivals",
     "source_state",
     "server_now_utc"
    ]
   },
   "StopDeparture": {
    "type": "object",
    "properties": {
     "time": {
      "type": "string",
      "pattern": "^[0-9]{2}:[0-5][0-9]:[0-5][0-9]$",
      "description": "GTFS time of the service day, HH:MM:SS, may be 24:00:00 or later (= after midnight, same service day)"
     },
     "line": {
      "type": "string"
     },
     "route_id": {
      "type": "string"
     },
     "headsign": {
      "type": "string"
     },
     "direction_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "agency_id": {
      "type": "string"
     },
     "trip_id": {
      "type": "string",
      "description": "GTFS trip_id when exactly one trip matches"
     },
     "dest_code": {
      "type": "string"
     },
     "dest_names": {
      "$ref": "#/components/schemas/LocalizedNames"
     }
    },
    "additionalProperties": true,
    "required": [
     "time",
     "route_id"
    ]
   },
   "StopDaySchedule": {
    "type": "object",
    "properties": {
     "stop_code": {
      "type": "string"
     },
     "date": {
      "type": "string",
      "description": "The service date as given (YYYYMMDD)"
     },
     "count": {
      "type": "integer"
     },
     "departures": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/StopDeparture"
      }
     },
     "server_now_utc": {
      "type": "string",
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z"
     }
    },
    "additionalProperties": true,
    "required": [
     "stop_code",
     "date",
     "count",
     "departures"
    ]
   },
   "LineSearchHit": {
    "type": "object",
    "properties": {
     "route_id": {
      "type": "string"
     },
     "route_short_name": {
      "type": "string"
     },
     "route_long_name": {
      "type": "string",
      "description": "Origin<->destination as in GTFS (Hebrew)"
     },
     "agency_id": {
      "type": "string"
     },
     "agency_name": {
      "type": "string"
     },
     "dest_code": {
      "type": "string"
     },
     "dest_names": {
      "$ref": "#/components/schemas/LocalizedNames"
     }
    },
    "additionalProperties": true,
    "required": [
     "route_id",
     "route_short_name",
     "agency_id"
    ]
   },
   "Line": {
    "type": "object",
    "properties": {
     "line_ref": {
      "type": "string"
     },
     "routes": {
      "type": "array",
      "items": {
       "type": "object"
      }
     },
     "agencies": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/Agency"
      }
     },
     "directions": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "route_id": {
         "type": "string"
        },
        "direction_id": {
         "type": "string"
        },
        "headsign": {
         "type": "string"
        },
        "trip_id": {
         "type": "string"
        },
        "shape_id": {
         "type": "string"
        },
        "service_id": {
         "type": "string"
        },
        "service_days": {
         "type": "object",
         "description": "GTFS calendar of the sample trip"
        },
        "exceptions": {
         "type": "object",
         "description": "calendar_dates counts (added/removed)"
        },
        "schedule_window": {
         "type": "object",
         "properties": {
          "first_departure": {
           "type": "string"
          },
          "last_departure": {
           "type": "string"
          }
         },
         "additionalProperties": true
        },
        "stops": {
         "type": "array",
         "items": {
          "type": "object",
          "properties": {
           "stop_sequence": {
            "type": "integer"
           },
           "stop_code": {
            "type": "string"
           },
           "stop_name": {
            "type": "string"
           },
           "stop_lat": {
            "type": "number",
            "description": "Latitude, WGS 84, decimal degrees",
            "minimum": -90,
            "maximum": 90
           },
           "stop_lon": {
            "type": "number",
            "description": "Longitude, WGS 84, decimal degrees",
            "minimum": -180,
            "maximum": 180
           }
          },
          "additionalProperties": true
         }
        },
        "dest_code": {
         "type": "string"
        },
        "dest_names": {
         "$ref": "#/components/schemas/LocalizedNames"
        }
       },
       "additionalProperties": true
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "line_ref",
     "directions"
    ]
   },
   "LineShape": {
    "type": "object",
    "properties": {
     "route_id": {
      "type": "string"
     },
     "date": {
      "type": "string"
     },
     "runs_on_date": {
      "type": "boolean"
     },
     "trips_on_date": {
      "type": "integer"
     },
     "shape_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "coords": {
      "type": "array",
      "items": {
       "type": "array",
       "items": {
        "type": "number"
       },
       "minItems": 2,
       "maxItems": 2
      },
      "description": "[lon, lat] pairs (GeoJSON order)"
     },
     "shape": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "lat": {
         "type": "number",
         "description": "Latitude, WGS 84, decimal degrees",
         "minimum": -90,
         "maximum": 90
        },
        "lon": {
         "type": "number",
         "description": "Longitude, WGS 84, decimal degrees",
         "minimum": -180,
         "maximum": 180
        }
       },
       "additionalProperties": true
      },
      "description": "The same points as {lat, lon}"
     },
     "other_shapes_on_date": {
      "type": "array",
      "items": {}
     },
     "shapes_in_calendar": {
      "type": "integer"
     },
     "meta": {
      "type": "object"
     }
    },
    "additionalProperties": true,
    "required": [
     "route_id",
     "date",
     "coords"
    ]
   },
   "LineVariant": {
    "type": "object",
    "properties": {
     "route_id": {
      "type": "string"
     },
     "line": {
      "type": "string",
      "description": "Public line number"
     },
     "mode": {
      "type": "string",
      "description": "bus | rail | light_rail …"
     },
     "agency": {
      "type": "object",
      "properties": {
       "id": {
        "type": "string"
       },
       "name": {
        "type": "string"
       }
      },
      "additionalProperties": true
     },
     "makat": {
      "type": "string",
      "description": "Line id of the Ministry of Transport (shared by the line's directions)"
     },
     "direction": {
      "type": "string"
     },
     "alternative": {
      "type": "string",
      "description": "Ministry variant mark (#, א, ב, ק …)"
     },
     "long_name": {
      "type": "string"
     },
     "runs_on_date": {
      "type": "boolean"
     },
     "trips_on_date": {
      "type": "integer"
     },
     "shape_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "headsign": {
      "type": "object"
     },
     "origin": {
      "type": "object",
      "description": "First stop: stop_id, code, name, names, city, lat, lon"
     },
     "destination": {
      "type": "object",
      "description": "Last stop: stop_id, code, name, names, city, lat, lon"
     },
     "gtfs_direction_id": {
      "type": [
       "string",
       "null"
      ]
     },
     "stop_count": {
      "type": "integer"
     },
     "first_departure": {
      "type": "string",
      "description": "HH:MM, GTFS time of the service date (may exceed 24:00)"
     },
     "last_departure": {
      "type": "string"
     },
     "first_departure_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "last_departure_utc": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     }
    },
    "additionalProperties": true,
    "required": [
     "route_id",
     "line"
    ]
   },
   "LineVariants": {
    "type": "object",
    "properties": {
     "number": {
      "type": "string"
     },
     "agency": {
      "type": [
       "string",
       "null"
      ]
     },
     "date": {
      "type": "string"
     },
     "groups": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "agency_id": {
         "type": "string"
        },
        "agency_name": {
         "type": "string"
        },
        "number": {
         "type": "string"
        },
        "makat": {
         "type": "string"
        },
        "runs_on_date": {
         "type": "boolean"
        },
        "trips_on_date": {
         "type": "integer"
        },
        "variants": {
         "type": "array",
         "items": {
          "$ref": "#/components/schemas/LineVariant"
         }
        }
       },
       "additionalProperties": true
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "groups"
    ],
    "description": "Variants (directions / alternatives) of a public line number on a date, per operator"
   },
   "RouteVariants": {
    "type": "object",
    "properties": {
     "line": {
      "type": "object",
      "description": "agency, number, makat of the line the route belongs to"
     },
     "date": {
      "type": "string"
     },
     "variants": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/LineVariant"
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "variants"
    ],
    "description": "All variants of the line the given route belongs to"
   },
   "LineDaySchedule": {
    "type": "object",
    "properties": {
     "route_id": {
      "type": "string"
     },
     "date": {
      "type": "string"
     },
     "count": {
      "type": "integer"
     },
     "departures": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "time": {
         "type": "string"
        },
        "headsign": {
         "type": "string"
        }
       },
       "additionalProperties": true,
       "required": [
        "time"
       ]
      }
     },
     "server_now_utc": {
      "type": "string",
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z"
     }
    },
    "additionalProperties": true,
    "required": [
     "route_id",
     "date",
     "count",
     "departures"
    ],
    "description": "Departures from the FIRST stop of the route on a service date"
   },
   "Alert": {
    "type": "object",
    "properties": {
     "id": {
      "type": "string"
     },
     "sourceId": {
      "type": "string"
     },
     "source": {
      "type": "string",
      "description": "MOT"
     },
     "type": {
      "type": "string",
      "description": "detour | delay | stop_moved | stop_cancelled | works | route_change | other"
     },
     "cause": {
      "type": "string"
     },
     "effect": {
      "type": "string"
     },
     "title": {
      "type": "string",
      "description": "As published by the source (usually Hebrew)"
     },
     "description": {
      "type": [
       "string",
       "null"
      ]
     },
     "rawText": {
      "type": [
       "string",
       "null"
      ]
     },
     "url": {
      "type": [
       "string",
       "null"
      ]
     },
     "status": {
      "type": "string"
     },
     "activeNow": {
      "type": "boolean"
     },
     "relevantToday": {
      "type": "boolean"
     },
     "upcoming": {
      "type": "boolean"
     },
     "startTime": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "endTime": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "dateRanges": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "start": {
         "type": "integer",
         "description": "Unix seconds"
        },
        "end": {
         "type": "integer",
         "description": "Unix seconds"
        },
        "start_utc": {
         "type": [
          "string",
          "null"
         ],
         "format": "date-time",
         "description": "UTC, ISO 8601 with Z, or null"
        },
        "end_utc": {
         "type": [
          "string",
          "null"
         ],
         "format": "date-time",
         "description": "UTC, ISO 8601 with Z, or null"
        }
       },
       "additionalProperties": true
      }
     },
     "cities": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "operators": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "affectedLines": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "line": {
         "type": "string"
        },
        "agency": {
         "type": "string"
        },
        "route_id": {
         "type": "string"
        }
       },
       "additionalProperties": true
      }
     },
     "affectedRouteIds": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "affectedStops": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "stop_id": {
         "type": "string"
        },
        "code": {
         "type": "string"
        },
        "name": {
         "type": "string"
        },
        "lat": {
         "type": "number",
         "description": "Latitude, WGS 84, decimal degrees",
         "minimum": -90,
         "maximum": 90
        },
        "lon": {
         "type": "number",
         "description": "Longitude, WGS 84, decimal degrees",
         "minimum": -180,
         "maximum": 180
        },
        "city": {
         "type": "string"
        }
       },
       "additionalProperties": true
      }
     },
     "hasGeo": {
      "type": "boolean"
     },
     "sourceUpdatedAt": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "permalink": {
      "type": "string",
      "description": "Path of the alert page in the iBus app"
     }
    },
    "additionalProperties": true,
    "required": [
     "id",
     "type",
     "title"
    ]
   },
   "AlertEnvelope": {
    "type": "object",
    "properties": {
     "alert": {
      "$ref": "#/components/schemas/Alert"
     },
     "updated_at": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "stale": {
      "type": "boolean",
      "description": "true when the alert feed was not refreshed in time"
     },
     "source": {
      "type": "string"
     }
    },
    "additionalProperties": true,
    "required": [
     "alert"
    ],
    "description": "One alert while it is in the current feed"
   },
   "AlertList": {
    "type": "object",
    "properties": {
     "configured": {
      "type": "boolean"
     },
     "updated_ts": {
      "type": [
       "integer",
       "null"
      ]
     },
     "updated_at": {
      "type": [
       "string",
       "null"
      ],
      "format": "date-time",
      "description": "UTC, ISO 8601 with Z, or null"
     },
     "stale": {
      "type": "boolean",
      "description": "true when the alert feed was not refreshed in time"
     },
     "error": {
      "type": [
       "string",
       "null"
      ]
     },
     "source": {
      "type": "string"
     },
     "count": {
      "type": "integer"
     },
     "alerts": {
      "type": "array",
      "items": {
       "$ref": "#/components/schemas/Alert"
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "alerts",
     "count",
     "stale"
    ]
   },
   "Agency": {
    "type": "object",
    "properties": {
     "agency_id": {
      "type": "string"
     },
     "agency_name": {
      "type": "string"
     },
     "agency_url": {
      "type": [
       "string",
       "null"
      ]
     },
     "agency_phone": {
      "type": [
       "string",
       "null"
      ]
     },
     "agency_timezone": {
      "type": "string"
     }
    },
    "additionalProperties": true,
    "required": [
     "agency_id",
     "agency_name"
    ]
   },
   "RailStations": {
    "type": "object",
    "properties": {
     "stations": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "code": {
         "type": "string"
        },
        "names": {
         "$ref": "#/components/schemas/LocalizedNames"
        },
        "city": {
         "type": [
          "object",
          "null"
         ]
        },
        "lat": {
         "type": "number",
         "description": "Latitude, WGS 84, decimal degrees",
         "minimum": -90,
         "maximum": 90
        },
        "lon": {
         "type": "number",
         "description": "Longitude, WGS 84, decimal degrees",
         "minimum": -180,
         "maximum": 180
        }
       },
       "additionalProperties": true
      }
     },
     "source": {
      "type": "string"
     },
     "count": {
      "type": "integer"
     }
    },
    "additionalProperties": true,
    "required": [
     "stations",
     "count"
    ]
   },
   "ServiceDay": {
    "type": "object",
    "properties": {
     "date": {
      "type": "string"
     },
     "weekday": {
      "type": "integer",
      "description": "0 = Monday … 6 = Sunday"
     },
     "in_feed": {
      "type": "boolean",
      "description": "The date is inside the published timetable"
     },
     "feed": {
      "type": "object",
      "properties": {
       "from": {
        "type": "string"
       },
       "to": {
        "type": "string"
       }
      },
      "additionalProperties": true
     },
     "services": {
      "type": "integer"
     },
     "usual": {
      "type": "integer"
     },
     "compared": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "added": {
      "type": "integer"
     },
     "removed": {
      "type": "integer"
     },
     "differs": {
      "type": "boolean",
      "description": "The day differs from the usual same weekday"
     },
     "fewer": {
      "type": "boolean"
     },
     "source": {
      "type": "string"
     }
    },
    "additionalProperties": true,
    "required": [
     "date",
     "in_feed",
     "feed"
    ]
   },
   "FreshnessContract": {
    "type": "object",
    "properties": {
     "version": {
      "type": "integer"
     },
     "realtime_live_sec": {
      "type": "integer"
     },
     "realtime_hide_eta_sec": {
      "type": "integer"
     },
     "alerts_fresh_sec": {
      "type": "integer"
     },
     "future_skew_sec": {
      "type": "integer"
     },
     "states": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "source_states": {
      "type": "array",
      "items": {
       "type": "string"
      }
     }
    },
    "additionalProperties": true,
    "required": [
     "version",
     "realtime_live_sec"
    ]
   },
   "Health": {
    "type": "object",
    "properties": {
     "status": {
      "type": "string",
      "description": "ok"
     },
     "env": {
      "type": "string"
     },
     "service": {
      "type": "string"
     }
    },
    "additionalProperties": true,
    "required": [
     "status"
    ]
   },
   "StopsVersion": {
    "type": "object",
    "properties": {
     "version": {
      "type": "string",
      "description": "Changes when a new timetable is published"
     }
    },
    "additionalProperties": true,
    "required": [
     "version"
    ]
   },
   "Whoami": {
    "type": "object",
    "properties": {
     "authenticated": {
      "type": "boolean",
      "description": "true when a valid key was sent"
     },
     "ip_seen": {
      "type": [
       "string",
       "null"
      ],
      "description": "The client address the server saw"
     },
     "request_id": {
      "type": "string"
     },
     "time_utc": {
      "type": "string",
      "description": "Server time, UTC"
     },
     "anonymous_modes": {
      "type": "object",
      "description": "Without a key: how anonymous requests are treated (`allow`, `compat` with network limits, `deny`)"
     },
     "key": {
      "type": "object",
      "description": "With a key: prefix, env (`live` / `test`), status (`active`, `grace`, `revoked`, `expired`), expires_at"
     },
     "project": {
      "type": "object",
      "description": "With a key: id, name, status (`active`, `suspended`, `blocked`), access_until"
     },
     "checks": {
      "type": "object",
      "description": "With a key: `secret` (recognized / not_recognized), `key` (valid / revoked / expired), `project` (active / suspended / blocked / access_expired), `ip` (allowed / not_configured / denied) — up to the first failing one"
     },
     "groups": {
      "type": "array",
      "items": {
       "type": "string"
      },
      "description": "With a key: the project's groups of operations"
     },
     "limits": {
      "type": "object",
      "description": "With a key: the project's limits"
     },
     "usage": {
      "type": [
       "object",
       "null"
      ],
      "description": "With a key: what is used now"
     }
    },
    "additionalProperties": true,
    "required": [
     "authenticated",
     "ip_seen",
     "request_id",
     "time_utc"
    ]
   }
  },
  "parameters": {
   "StopCode": {
    "name": "stopCode",
    "in": "path",
    "required": true,
    "description": "Public stop code (1–7 digits, the number on the stop sign)",
    "schema": {
     "type": "string",
     "pattern": "^[0-9]{1,7}$"
    },
    "example": "21472"
   },
   "RouteId": {
    "name": "routeId",
    "in": "path",
    "required": true,
    "description": "GTFS route_id — one direction/variant of a line (find it with searchLines)",
    "schema": {
     "type": "string",
     "pattern": "^[0-9A-Za-z_.:-]{1,80}$"
    },
    "example": "7020"
   },
   "Lang": {
    "name": "lang",
    "in": "query",
    "required": false,
    "description": "Language of stop names / headsigns: `en` (and `ru`) → English GTFS names, `ar` → Arabic, anything else → the source Hebrew. Russian names do not exist in the source.",
    "schema": {
     "type": "string",
     "enum": [
      "he",
      "en",
      "ar",
      "ru"
     ]
    }
   },
   "Date": {
    "name": "date",
    "in": "query",
    "required": false,
    "description": "Service date YYYYMMDD (Israel). Default: today. Another format returns an empty list, not an error.",
    "schema": {
     "type": "string",
     "pattern": "^[0-9]{8}$"
    },
    "example": "20261021"
   }
  },
  "responses": {
   "BadRequest": {
    "description": "Invalid parameter (gateway check)",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "BAD_REQUEST",
       "detail": "",
       "source_state": null
      }
     }
    }
   },
   "Unprocessable": {
    "description": "Invalid query parameter (checked by the transport service)",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "UPSTREAM_422",
       "detail": "",
       "source_state": null
      }
     }
    }
   },
   "NotFound": {
    "description": "Unknown address, or an object the source does not have",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "NOT_FOUND",
       "detail": "",
       "source_state": null
      }
     }
    }
   },
   "RateLimited": {
    "description": "A limit of your project (with a key) or of your network (without a key during the transition): RATE_LIMITED per minute, QUOTA_EXCEEDED for the day / month / heavy budget (`scope`), CONCURRENCY_LIMIT, TEMPORARILY_RESTRICTED after repeated violations. Wait `Retry-After` seconds.",
    "headers": {
     "Retry-After": {
      "description": "Seconds to wait",
      "schema": {
       "type": "integer"
      }
     }
    },
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "minute": {
        "value": {
         "code": "RATE_LIMITED",
         "detail": "too many requests per minute",
         "docs": "https://api.ibusisrael.online/docs/access/#rate-limited",
         "request_id": "r-5f2c9a"
        }
       },
       "day": {
        "value": {
         "code": "QUOTA_EXCEEDED",
         "detail": "quota exhausted",
         "scope": "day",
         "docs": "https://api.ibusisrael.online/docs/access/#quota-exceeded",
         "request_id": "r-5f2c9b"
        }
       }
      }
     }
    }
   },
   "Unavailable": {
    "description": "A data source or the internal service failed or timed out (502 / 504), or — 503 — the service keeps capacity for passengers (CAPACITY_RESERVED) or cannot check access rules right now (POLICY_UNAVAILABLE: keyed requests are refused, never let through). Retry later with backoff; honour `Retry-After` when present.",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "UPSTREAM_TIMEOUT",
       "detail": "",
       "source_state": "unavailable"
      }
     }
    }
   },
   "Unauthorized": {
    "description": "No key where one is required (KEY_REQUIRED), or the key is unknown, revoked or expired (KEY_INVALID, KEY_REVOKED, KEY_EXPIRED). Send `Authorization: Bearer <key>`.",
    "headers": {
     "WWW-Authenticate": {
      "description": "`Bearer realm=\"iBus API\"`",
      "schema": {
       "type": "string"
      }
     }
    },
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "KEY_REVOKED",
       "detail": "key revoked",
       "docs": "https://api.ibusisrael.online/docs/access/#key-revoked",
       "request_id": "r-5f2c9c"
      }
     }
    }
   },
   "Forbidden": {
    "description": "The key is valid but this request is not allowed: GROUP_NOT_ALLOWED, IP_NOT_ALLOWED (with `ip_seen`), PROJECT_SUSPENDED, PROJECT_BLOCKED, ACCESS_EXPIRED, OPERATION_NOT_AVAILABLE, PLATE_LOOKUP_NOT_ALLOWED.",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "example": {
       "code": "IP_NOT_ALLOWED",
       "detail": "ip not allowed",
       "ip_seen": "203.0.113.24",
       "docs": "https://api.ibusisrael.online/docs/access/#ip-not-allowed",
       "request_id": "r-5f2c9d"
      }
     }
    }
   },
   "KeyInQuery": {
    "description": "BAD_REQUEST: an invalid parameter (gateway check), or KEY_IN_QUERY: a key or token in the URL — keys go only in the `Authorization` header (replace a key that appeared in a URL).",
    "content": {
     "application/json": {
      "schema": {
       "$ref": "#/components/schemas/Error"
      },
      "examples": {
       "parameter": {
        "value": {
         "code": "BAD_REQUEST",
         "detail": "",
         "source_state": null
        }
       },
       "key": {
        "value": {
         "code": "KEY_IN_QUERY",
         "detail": "send the key in the Authorization header, never in the URL",
         "docs": "https://api.ibusisrael.online/docs/access/#key-in-query",
         "request_id": "r-5f2c9e"
        }
       }
      }
     }
    }
   }
  },
  "securitySchemes": {
   "ibusKey": {
    "type": "http",
    "scheme": "bearer",
    "bearerFormat": "ibk_live_k_<10 characters>_<43 characters>",
    "description": "The key of your project from the developer cabinet (https://app.ibusisrael.online/developers). Shown once when it is created; iBus stores only a hash. Header only: `Authorization: Bearer <key>`. Keep it on your server."
   }
  }
 },
 "externalDocs": {
  "description": "Guides (HE / RU / EN / AR)",
  "url": "https://api.ibusisrael.online/docs/"
 }
}
