Public Transport Information Technologies

Doing funky stuff with open APIs

HSL/HRT - Helsinki Region Transport

Helsinki, Finland

Reittiopas

Map based route planner - for smart phones with large screens, sensible JavaScript support and enough processing power. Read more... Examples...

WAP opas

Simple and light-weight route planner - for less advanced devices. Also useful for users who want fast results or like to minimize data traffic. Read more...

Public transport to public services

Find nearest public services in various categories. Get public transport route instructions on how to get there! Read more...

Nearest stops and departures

Find nearest stops and get the timetables easily. You can choose the stops from which the timetables are shown and save a bookmark for your personalized view. Read more...

Nearest stops and departures

Another way of finding nearest stops and get the timetables easily. Choose a stop and the next departures from that stop are shown. Click on any row and see the route of the line on the map. Also the vehicles of that line currently on route are shown on map. Uses Stops GeoJSON API and Routes GeoJSON API (documented below)

Nearest stops and departures

Yet another way of finding nearest stops and get the timetables easily. Uses the HSL reittiopas API directly (via a small proxy script). Implemented in JavaScript for better performance (concurrent requests).

Inline skating and public transport

Find your way using the public transport and inline skates - often the fastest way to go! Read more...

Routes GeoJSON

HSL line routes (paths) in GeoJSON format.

Parameters
NameDescriptionDefault value
linesJore codes of lines, separated with | (pipe)-
cidclient id, should be set (to reduce unnecessary load with dup); your client must support cookies -
dupreturn duplicates (you must set dup=1 if you want routes already sent to client cid to be sent again)false (0)
clrclear session (forget which routes are sent during this session)-

Examples

Stops GeoJSON

HSL stops, passing lines and next departures in GeoJSON format.

Parameters
NameDescriptionDefault value
BBOXbounding box in KML format; preferred; overrides lat, lon and rad-
latlatitude of the center point of the search area60.2
lonlongitude of the center point of the search area24.8
radradius of the search area1000
maxmaximum number of stops returned1000 (maximum)
tabshow next departures (as an HTML formatted timetable)false (0)
cidclient id, should be set (to reduce unnecessary load with dup); your client must support cookies -
dupreturn duplicates (you must set dup=1 if you want stops already sent to client cid to be sent again)false (0)
clrclear session (forget which stops are sent during this session)-

Examples

Departures JSON

JavaScript API for Omat lähdöt XML API (HSL stop departure times)

Parameters
NameDescriptionDefault value
stopsarray of stop identifiers-
timedate and time of query, e.g. 2006-12-28T13:32:52-
maxmaximum number of departures to return10

Examples

Source code on GitHub

Vehicles GeoJSON

HSL vehicles real time position information in GeoJSON format. Results are sorted by transport type and route.

Parameters
NameDescriptionDefault value
BBOXbounding box in KML format-
busesmaximum number of buses1000
trainsmaximum number of local trains1000
longdistancetrainsmaximum number of long distance trains1000
tramsmaximum number of trams1000
linelineid (Jore code) of a single line-
delayignore results older than delay seconds300 (5 minutes)

Examples

Vehicles GTFS

General Transport Feed Specification (GTFS) Realtime feed for HSL vehicle positions.

Source code on GitHub

Service Alerts GTFS

General Transport Feed Specification (GTFS) Realtime feed for HSL service alerts.

Source code on GitHub

Service Alerts JSON

JavaScript API for Poikkeustiedot XML API (HSL service alerts)

Parameters
NameDescriptionDefault value
lineLine number (e.g. 550)-
typeLine type as specified in the XML API (e.g. 2 for trams)-
langLanguage (fi, sv, en); incorrect language code se is accepted for swedish (sv)fi
dtDatetime, preferably in the format 2013-09-25T13:14:15 but you can also try other formats like tomorrow.-

Examples

Service Alert history JSON

Disruption info (service alert) history for HSL lines, in JSON format. Collected by polling Poikkeustiedot XML API in frequent intervals since February 2011. The data is incomplete. The polling hasn't been functioning at all times.

Parameters
NameDescriptionDefault value
line (URL path parameter)Line ID1-
now (query parameter)Add ?now=1 to only show currently valid disruptions-

1Line ID should be Jore code, but due to a bug in Poikkeustiedot XML API, this is actually a human readable line identifier

Examples