Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

location.name service doesn't find "Rösrath" #26

Open
marians opened this issue Jun 14, 2016 · 3 comments
Open

location.name service doesn't find "Rösrath" #26

marians opened this issue Jun 14, 2016 · 3 comments

Comments

@marians
Copy link

marians commented Jun 14, 2016

When searching my home station using this request

https://open-api.bahn.de/bin/rest.exe/location.name?authKey=xxx&lang=de&input=R%C3%B6srath&format=json

I was surprised to not find it in the results, despite the fact that there exists one station with the exact name Rösrath (ID 008005134) and several with Rösrath as part of the name.

The response returned was

{
"LocationList":{
  "noNamespaceSchemaLocation":"http://open-api.bahn.de/bin/rest.exe/v1.0/xsd?name=hafasRestLocation.xsd",
  "StopLocation":[{
    "name":"Herzogenrath",
    "lon":"6.094488",
    "lat":"50.870917",
    "id":"008002806"
    },{
    "name":"Roedekro st",
    "lon":"9.332753",
    "lat":"55.069689",
    "id":"008601996"
    },{
    "name":"Rödby BF",
    "lon":"11.357466",
    "lat":"54.655718",
    "id":"008601988"
    },{
    "name":"Roedby Faerge",
    "lon":"11.354841",
    "lat":"54.655232",
    "id":"008601989"
    },{
    "name":"Ratisbona",
    "lon":"12.099615",
    "lat":"49.011669",
    "id":"008000309"
    },{
    "name":"Soest",
    "lon":"8.104593",
    "lat":"51.578422",
    "id":"008000076"
    },{
    "name":"Jena-Göschwitz",
    "lon":"11.593540",
    "lat":"50.883943",
    "id":"008010133"
    },{
    "name":"Soroe st",
    "lon":"11.568793",
    "lat":"55.419019",
    "id":"008602350"
    },{
    "name":"Oesterport st",
    "lon":"12.587612",
    "lat":"55.692704",
    "id":"008601878"
    },{
    "name":"BRATISLAVA",
    "lon":"17.097851",
    "lat":"48.154135",
    "id":"005696001"
    },{
    "name":"Bratislava hl.st.",
    "lon":"17.106463",
    "lat":"48.158908",
    "id":"005600207"
    }]
  }
}
@marians
Copy link
Author

marians commented Jun 14, 2016

Got it!

Die Deutsche Bahn stellt [erstmals] über eine offene Schnittstelle für den Zugriff auf ihre Fahrplandaten[bank] zur Verfügung - [zunächst] eingeschränkt auf den SOLL-Fahrplan des Fernverkehrs.

So no regional stations, and no departure boards for now?

@highsource
Copy link
Collaborator

Correct. This interface is limited to long-distance trains and stations at the moment.

Check this (non open data) interface:

https://iris.noncd.db.de/wbt/js/index.html?bhf=KROE

@J0ANMM
Copy link

J0ANMM commented Oct 31, 2016

Found a similar issue with Berlin, but I don't think this time has to do with regional trains.

https://open-api.bahn.de/bin/rest.exe/location.name?authKey=<KEY>&lang=de&input=Berlin&format=json

Finds:

{
    "name":"Berlin Hbf",
    "lon":"13.369548",
    "lat":"52.525589",
    "id":"008011160"
    }

But not:
Berlin Hbf (tief) - id: 8098160

However many routes are actually going through Berlin Hbf (tief). Or am I doing something wrong?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants