Overpass API/Public transport examples

From OpenStreetMap Wiki
Jump to navigation Jump to search
Overpass API logo.svg
edit
Overpass API · Language reference · Language guide · Technical terms · Areas · Query examples · Sparse Editing · Permanent ID · FAQ · more · Web site
Servers status · Versions · Development · Technical design · Installation · XAPI compatibility layer · Public transport sketch lines · Applications · Source code and issues
Overpass turbo · Wizard · Overpass turbo shortcuts · MapCSS stylesheets · Export to GeoJSON · more · Development · Source code and issues · Web site
Overpass Ultra · Overpass Ultra extensions · MapLibre stylesheets ·more · Source code and issues · Web site

Overpass API includes a feature to render public transport maps (a kind of linear maps). All the following example links on this wiki page are using the documented {{Sketch Line}} utility template.

Usage

On this page you can choose the network, the line and the operator.

In order to get a specific rendering you can add the style:

  • wuppertal, simple style with German abbreviations (default)
  • padua, simple style with German abbreviations
  • paris, style displaying also connections, with French abbreviations
  • any style you provide.

Other options are summarily documented online on this webform, or better detailed with examples in the documentation of the {{Sketch Line}} template usable on this wiki.

The page display twice the stop of a route-relations using PTv2 as mentionned in this Overpass API issue. There is no plan to fix this problem soon.

Technical limitations

The linear maps system cannot recognise lines with an ampersand in ref=*. This issue affects the Hammersmith/Waterloo & City lines on the London Underground, where trying to do so will return the “No relation found” error.

Examples

Australia

City/Region Network Lines Issues
Brisbane Translink (rail) BeenleighFerny Grove
AirportGold Coast
CabooltureSunshine Coast
Redcliffe PeninsulaSpringfield
ClevelandShorncliffe
Doomben
Queensland QR Travel Inlander
Spirit of the Outback
Spirit of Queensland
Tilt Train
Westlander

France

City/Region Network Lines Issues
Île-de-France RER ABE Boissy-Saint-Léger branch of RER A is disconnected.
All branches of RER B are broken.
Transilien KNPRU Provins branch of Train P faces the wrong way, while the intermediate stations of the Crécy-la-Chapelle shuttle are missing.

Germany

Example preview of line 630 (VRR).

Greece

City/Region Network Lines Issues
Athens Metro Μ1Μ2Μ3 No faults
Tram Τ6Τ7 No faults
Suburban Rail Π1Π2Π3Π4Π5 No faults
Patras Suburban Rail Π1Π2 No faults

Ireland

Japan

Malaysia

912

Switzerland

  • Bernmobil: 10

United Kingdom

United States

Semi-working examples

United Kingdom

Bad examples