Skip to content

Latest commit

 

History

History
35 lines (22 loc) · 1.46 KB

README.md

File metadata and controls

35 lines (22 loc) · 1.46 KB

VATSIM Data Handler Build Status Coverage Status

=========

A data handler for the VATSIM status system coded in JavaScript

Installation

npm install vatsim-data-handler

Usage

const DataHandler = require('vatsim-data-handler');
const handler = new DataHandler();

console.log(handler.getClientCount());

This would log the number of clients connected to the VATSIM network

Available methods

  • getClientCount() - Returns the number of clients connected to the VATSIM network
  • getPilotCount() - Returns the number of pilots connected to the VATSIM network
  • getControllerCount() - Returns the number of controllers connected to the VATSIM network
  • getAirportInfo(airport) - Returns the details of pilots into or out of a certain airport along with the controllers controlling that airport, the airport argument is a 4 letter ICAO code
  • getPopularAirports() - Returns a list of the top 10 airports for arriving and departing aircraft

Tests

npm test

Contributing

In lieu of a formal style guide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code.