Closed rosvik closed 4 years ago
https://api.entur.io/realtime/v1/rest/sx?requestorId=757c9284-0f12-4a46-a557-33a19e801192
Generating typescript Protobuf schema:
See PR 107 in https://github.com/mapbox/pbf : https://github.com/junghans-schneider/pbf
git clone junghans-schneider/pbf
cd pbf
npm install
npm run build-dev
./bin/pbf
curl -O https://developers.google.com/transit/gtfs-realtime/gtfs-realtime.proto
./bin/pbf gtfs-realtime.proto --typescript > gtfs-realtime.ts
#!/bin/bash
protoc -I=. gtfs-rt/gtfs-realtime.proto --grpc-web_out=import_style=typescript,mode=grpcwebtext:.
protoc -I=. sx-gtfs-rt-proxy/sx-gtfs-rt-proxy.proto --grpc-web_out=import_style=typescript,mode=grpcwebtext:.
Disruption messages from Siri-SX or GTFS-RX should be displayed on Tavla.
Messages would refer to a stop, route or agency (AtB globaly).
Siri-SX
AtB uses Siri-SX and Siri-VM (Situation Exchange and Vehicle Monitoring). SX gives data on disruptions.
From https://enturas.atlassian.net/wiki/spaces/PUBLIC/pages/637370605/SIRI-SX
Badly formatted example: atb-data.txt
See examples at https://github.com/entur/profile-examples/tree/master/siri/situation-exchange
GTFS-RX
Formatted like Service Alerts here: http://wiki.itsfactory.fi/index.php/GTFS-RT
See
EntitySelector
. References would be tostop_id
agency_id
route_id
Available as JSON and Protobuf (.pbf). Protobuf can be loaded in the browser https://gavinr.com/protocol-buffers-protobuf-browser/
API endpoint: https://api.entur.io/realtime/v1/gtfs-rt/trip-updates?datasource=RUT