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

query BVG/VBB APIs directly #5

Open
derhuerst opened this issue Jan 14, 2020 · 3 comments
Open

query BVG/VBB APIs directly #5

derhuerst opened this issue Jan 14, 2020 · 3 comments

Comments

@derhuerst
Copy link

While I intend to keep *.transport.rest up, it would be better if this integration would query the upstream BVG/VBB APIs behind *.transport.rest directly.

I elaborated at kennell/schiene#1 (comment), how you could use hafas-client from Python.

Let me know if this is an option.

@derhuerst
Copy link
Author

Advantages:

  • Your integration will behave almost exactly like a BVG/VBB app on a phone.
  • You depend on one less service on the internet run by random people. 😁 Even though I want to keep *.transport.rest running as a low-barrier way to access public transport data, it makes sense to access the information as directly as reasonably possible.

Disadvantages:

  • When the upstream BVG/VBB APIs change, hafas-client needs to be adapted. With *.transport.rest, this happens "behind the scenes". By using hafas-client directly, your users would probably have to upgrade every now and then.
  • While a Python <-- JSON-RPC --> Node with hafas-client should work reliably, it isn't the most elegant setup.

@derhuerst
Copy link
Author

The situation has changed a bit, I recommend to keep using my wrapper APIs for now.

But: 1.bvg.transport.rest is shut off, the latest version of the API is v5.bvg.transport.rest.

@tobias-richter
Copy link

tobias-richter commented Dec 5, 2020

@derhuerst I think the bvg_sensor is not actively maintained at the moment. I had opened a PR with a fix for 2.bvg.transport.rest in April 2020 and it got no attention (#6).
I have just created a PR with a "hotfix" for v5.bvg.transport.rest (#7).
Sadly I have not the time to implement the usage of your wrapper at the moment.

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

2 participants