Skip to content

FAQ

APIs


Are there differences in the quality of the values supplied by the APIs? Are the data origin, type of calculation and latencies the same everywhere?

All request types have the same data source. Therefore, none of the request types should be favoured. Please simply select the request that is best suited to your application.

I get an illogical or incorrect result from an API. What can I do?

Please send us the following information using the contact form:
Requested API / Request time / Expected result / Actual result

How do I get an account so that I can request an API key?

API keys can be created (and deleted) after registration in the Developer Dashboard. The key/token must be sent in the HTTP header as “Authorisation” for each request.

Why is the system not responding? Why are no more data being supplied? Has the system failed?

Any system failures can be checked at http://status.opentransportdata.swiss/

What limits apply to data access for the various interfaces?

Information on this can be found on the Limits and costs page. Special terms of use apply to road traffic data from FEDRO.


What message do I get when the quota of my API key is exceeded?

An HTTP status 429 is returned and the response from the service is:

{
   "error":"Rate Limit exceeded"
}

Other Topics


Why does the platform not deliver the shapes.txt file?

At the moment we do not have any lines in high enough quality for publication. As we use OpenStreetMap for our GIS, it is important – if the data should one day be available – to take the corresponding terms of use into account. In particular, the copyright must be indicated if the data is published in applications.

How is cross-border traffic covered in the data?


The HRDF file only includes public transport in Switzerland. International trains are (in most cases) terminated at the first commercial stop abroad. The reality is, of course, that they continue their journey. In some cases, the international journey ends at the last stop in Switzerland (e.g. Geneva) or includes 1-2 stops/operating points abroad.
The file for public transport in Switzerland also includes the network map for SBB GmbH in Germany. There are historical reasons for this.

What is the difference between real-time, forecast and actual data?

The terms are often used synonymously in different combinations.

  • Real-time data is data that is created and transmitted on an ad-hoc basis. It may comprise planning, forecast and/or actual data.
  • Forecast data refers to the data that is calculated based on the current situation, e.g. arrival and departure times at the next stop.
  • Actual data refers to data on when and where services actually ran. This information is rarely available in real time and can usually only be generated retrospectively.


Why are there problems with the character set when importing CSV files into Excel?

The CSV files are encoded as UTF-8. This can cause problems when “regularly” opening CSV files in Excel because Excel assumes a different character set.
The following procedure helps here: Create an empty table in Excel and then select Data / Retrieve external data / From text in the menu. After selecting the file, “Unicode (UTF-8)” can be entered in the next dialogue step under File origin.

GA and Halb-Tax travelcard data: Are there plans to publish this data on the basis of the municipalities?

The short answer is: No.
The long answer is:

We cannot publish this data at municipal level as we do not know the allocation to the municipality. We have made this list based on the customer's address and he does not specify his municipality there.<br>You can, however, do this in the same way as SRF:<br>The information on the interactive map and the values in the article come from the data set of Direct Transport Switzerland (opentransportdata.swiss) on the distribution of GA and Half-Fare travelcards between 2012-2016. This analysis focuses on the data from 2016 (data extract week 51, 2016). The first step was to allocate the data to the permanent resident population valid at that time based on the postcode (31 December 2015). The GWR correspondence table published by the FSO (as at 1 January 2017) was used for the subsequent comparison between postcode and municipality. This made it possible to establish a direct link to the generalised municipal boundaries published by the FSO as at 1 January 2017 and the spatial structure of Switzerland. Due to averaging of the data for postcodes with less than 20 subscriptions, the map may be slightly distorted, especially for small municipalities.<br>Details https://srfdata.github.io/2017-09-sbb-ga-halbtax/#sbb__bfs_raumgliederungen<br>lante track is 4, but the current track is now 3 due to changes. We recommend that you only map at the level of the stops.


Where can I find formation data?

Unfortunately, the formation is currently not “openly” available. The release of certain formation data is currently being clarified.