npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

onboard-api-discovery

v0.0.3

Published

Attempt to discover the spread of onboard apis, which provide information in the vehicle-local WiFi.

Downloads

3

Readme

onboard-api-discovery

Attempt to discover the spread of onboard apis, which provide information in the local WiFi of many public transport vehicles. The tool currently checks your wifi connection for any known onboard information apis.

Installation

npm install -g onboard-api-discovery

Motivation

The following introduction and this project are mainly focused on the situation in Germany and Europe. If you come from another region and have knowledge to share about described onboard information systems there, feel free about creating an issue to get in touch and contribute your research.

If you've ever showed interest in using public transport apis for multiple regions at once, you will very likely have noticed the chaos that exists on one hand in the systems used by different public transport companies and on the other hand in the output returned by them (see public-transport/friendly-public-transport-format for a great approach on unifying the format).

The foundation of the Hafas system e. g. was created way back in the 90s for MS-DOS! Since then, a mess of different competing companies emerged their digital systems: Hafas, EFA, TRIAS and a bunch of provider specific apis. Not all of their implementations provide the same interface and feature-set.

Same can be said about recently upcoming onboard wifi systems. The aim of this project is to document the relatively young (and at the moment evolving) spread of onboard apis which are integrated into the onboard wifi of many public transport vehicles and are only available when connected to the wifis on the vehicles equipped with these systems. The apis provide connection, journey and vehicle related information which can be used in many different ways.

Information gained by this tool and guides to reverse engineering apis in general should help documenting as many apis as possible.

All the information you submit will help to eventually create a nice documentation. It'll furthermore help creating an overview of onboard systems under public-transport/transport-apis.

So whenever you find yourself on a train or other public transport vehicle with inbuilt wifi, please consider searching for onboard data with this tool.

Usage

After you've followed the installation using npm, you can start a discovery by entering onboard-api-discovery in your terminal. This will start a search for known api endpoints and return a json object which looks similiar to the following: (altough hopefully with data in the payload fields)

{
  "info": { "package": "onboard-api-discovery", "version": "0.0.2" },
  "gateway": "192.168.1.1",
  "wifi": [
    {
      "signal_level": -69,
      "quality": 62,
      "security": "wpa2-psk",
      "security_flags": [],
      "ssid": "xxx",
      "channel": "48,80",
      "frequency": 5240
    }
  ],
  "discoveries": [
    {
      "available": false,
      "info": { "system": "Icomera", "client": "live-icomera-position" },
      "payload": null
    },
    {
      "available": false,
      "info": { "system": "WIFIonICE", "client": "wifi-on-ice-portal-client" },
      "payload": null
    },
    {
      "available": false,
      "info": { "system": "SNCF WiFi (TGV)", "client": "sncf-wifi-portal-client" },
      "payload": null
    },
    {
      "available": false,
      "info": { "system": "Digital im Regio", "client": "digital-im-regio-portal-client" },
      "payload": null
    },
    {
      "available": false,
      "info": { "system": "Czech Railways", "client": "cd-wifi-client" },
      "payload": null
    }
  ]
}

Submitting this output as an issue amongst details about the train, bus or wifi you were connected to would help documenting the spread of the already known apis a lot!

Going further

If you want to reverse engineer onboard-apis yourself, this repo will soon contain some helpful guides on how to do just that. Contributions with guides about api reverse engineering are very much appreciated 🎭

Related

Some already available onboard clients are listed below:

Contributing

Discovered onboard endpoints that are currently not checked by the tool? Consider creating a pull request containing code to query the endpoints you discovered. That'd be really awesome! 🙌