derhuerst / hafas-gtfs-rt-feed

Format HAFAS data as GTFS Realtime.
https://github.com/derhuerst/hafas-gtfs-rt-feed#hafas-gtfs-rt-feed
Other
18 stars 1 forks source link

VehiclePosition -> VehicleDescriptor -> id is missing #5

Open derhuerst opened 3 years ago

derhuerst commented 3 years ago

See the discussion in https://github.com/public-transport/transport.rest/issues/5.

derhuerst commented 2 years ago

AFAICT it's not a true vehicle ID, but we could use prodCtx.num. For example U-Bahn line U8:

{
    "pid": "L::1::U::B3041857784::U_3041857784_U8::*",
    "name": "U8",
    "nameS": "U8",
    "number": "U8",
    "icoX": 2,
    "cls": 2,
    "oprX": 1,
    "prodCtx": {
        "name": "      U8",
        "num": "15803",
        "line": "U8",
        "matchId": "U8",
        "catOut": "U       ",
        "catOutS": "U",
        "catOutL": "U       ",
        "catIn": "U",
        "catCode": "1",
        "admin": "BVU---"
    }
}