hkbus

0.6.1 • Public • Published

hkbus

KMB changed the UI of the webpage for querying ETA, which is very slow even on a decent computer.
I reverse-engineered the API and created a thin wrapper for the HTTP API to get the routes, stops and ETAs.
The first version targets KMB, API may change when other operators are added in the future.

See test/ for notes on retrieving info from operators.

This is the repo for the wrapper library.
hkbus-cli is a CLI frontend, hkbus-web is a web frontend.
hkbus-web's build is pushed to gh-pages branch of this repo and available here.

Usage

https://runkit.com/leesei/hkbus-demo

References

https://db.kmbeta.ml/
https://github.com/mob41/KmbETA-API
https://github.com/mob41/KmbETA-DB
https://github.com/alvinhkh/buseta

/hkbus/

    Package Sidebar

    Install

    npm i hkbus

    Weekly Downloads

    3

    Version

    0.6.1

    License

    MIT

    Last publish

    Collaborators

    • leesei