API
The service exposes its own endpoints, the ones its app uses. They are public and available without a key, but they are not a product: they may change along with the app.
Available addresses
/api/delay-leaders/api/departures/api/map-tile/api/okolica/api/pojazd/api/push-alarm/api/push-klucz/api/push-subskrypcja/api/push-wypisz/api/ruch/api/statystyki/api/statystyki-linii/api/stops/api/topology/api/trasa/api/vehicles
They all return JSON and support ETag — a repeat request carrying If-None-Match gets a 304 with no body.
What is in the analytics database
Historical data, the basis for the statistics. The list below is generated straight from the database schema, so it cannot drift away from it.
| table | columns |
|---|---|
gps_snapshot | id, last_update, fetched_at, vehicles |
gps_course | id, route_id, trip_id, scheduled_start, route_short, headsign |
gps_vehicle | vehicle_id, vehicle_code, first_seen, last_seen |
gps_position | snapshot_id, vehicle_id, course_id, service, generated, lat, lon, speed, direction, delay, gps_quality |
dep_sighting | id, stop_key, dep_key, source, line, headsign, scheduled, trip_start, vehicle_code, vehicle_id, channel, first_seen, last_seen, samples, first_eta, last_eta, last_delay, last_status, gone_at, gone_reason |
dep_delay_sample | sighting_id, at, delay, eta, status |
agg_godzina | godzina_utc, source, klasa, wersja_regul, probek, mediana, p90, srednia, ponad5min, ponad15min, przed1min, przed2min |
agg_linia | godzina_utc, source, line, wersja_regul, probek, srednia, mediana, ponad5min, przed1min, przed2min, slupkow |
ruch_godzina | godzina_utc, kategoria, zadan |
ruch_wizyty | godzina_utc, wizyt |
ruch_sciezka | godzina_utc, sciezka, zadan |
ruch_klient | godzina_utc, klasa, zadan, wizyt |
push_subskrypcja | endpoint, p256dh, auth, utworzono, ostatnio_ok, bledy |
push_alarm | endpoint, alarm_id, o_ms, dodano, wyslano |
ruch_dzien | dzien, wizyt, zadan |
agg_przystanek | godzina_utc, stop_key, wersja_regul, probek, srednia, ponad5min, przed1min, linii |
agg_gps_godzina | godzina_utc, pozycji, pojazdow, predkosc_sr, predkosc_med, stojacych, jakosc_zla, bez_kursu |
agg_dryf | godzina_utc, horyzont_min, wersja_regul, kursow, mediana_abs, p90_abs, mediana_znak, srednia_znak, odrzuconych, stabilnych, wczesniej60, pozniej60 |
agg_widma | godzina_utc, klasa, literowa, wersja_regul, znikniec |
None of these tables holds information about the people using the service — they describe only vehicles, services and stops. Details: Privacy.
Where to get the source data
If you are building something of your own, go straight to the cities' APIs rather than to this service: that is where the data originates, and your requests will not depend on somebody else's layer staying available.