metro-realtime-client
Los Angeles Metro provides a RESTful API to retrieve realtime positions of their bus fleet. This is a low level client that does very little transformation on the responses from the API.
Installation
yarn install metro-realtime-client
Usage
All functions export a Promise that can be used then .then
or async/await
.
var client = ; // All functions return a Promise...client ; // ...so async/await works as wellconst agencies = await client;
// Multiple entity gettersclient;client;client;client; // All vehicles for the entire agencyclient; // All vehicles for a specific route // Single entity gettersclient;client;client;