Content-Length: 321849 | pFad | http://github.com/ZackaryH8/tfl-api-wrapper

24 GitHub - ZackaryH8/tfl-api-wrapper: A Node JS wrapper for the Transport for London Unified API and TrackerNet
Skip to content

ZackaryH8/tfl-api-wrapper

Repository files navigation

TfL Logo

TfL API Wrapper

A NodeJS wrapper for the TfL Unified API, made with TypeScript.

Read the Documentation

CI NPM Version Issues Gitpod ready-to-code

Installation

npm install tfl-api-wrapper
yarn add tfl-api-wrapper

Contribute

There are many ways to contribute to this repo.

Example Usage

Async... await

import { StopPoint } from 'tfl-api-wrapper';

const app_key = 'API KEY HERE'; // Use an environment file
const stopPoint = new StopPoint(app_key)

const arrivals = await stopPoint.getStationArrivals('940GZZLUKSX');
console.log(arrivals);

Callback

import { StopPoint } from 'tfl-api-wrapper';

const app_key = 'API KEY HERE'; // Use an environment file
const stopPoint = new StopPoint(app_key)

stopPoint.getStationArrivals('940GZZLUKSX').then((arrivals) => {
    console.log(arrivals)
});

Disclaimer

This repository is not affiliated, associated, authorized, endorsed by, or in any way officially connected with Transport for London (TfL) or its parent organisation Greater London Authority (GLA)









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/ZackaryH8/tfl-api-wrapper

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy