Skip to content

Latest commit

 

History

History
38 lines (35 loc) · 1.25 KB

README.md

File metadata and controls

38 lines (35 loc) · 1.25 KB

weather-cli-tool

A Command Line Interface (CLI) tool for:

  1. Accessing weather data of a location
  2. Accessing AQI of a location
  3. Getting coordinates of a location and vice-versa.

Tech Stack:

  1. Node.js
  2. NPM packages: (i) axios (ii) chalk (iii) commander

APIs used:

  1. Geocoding API
  2. Air Pollution API
  3. Weather API

Setup:

  1. Install Node.js on your computer
  2. Create a account on OpenWeather and go to the API keys section
  3. Copy the API KEY
  4. In your terminal, run:
npm i @trinetra116/weather-cli-tool
  1. In the file "node_modules/weather-cli-tool/api.js", and paste your API KEY like this:
const API_KEY="your API KEY";
  1. Now you can run your cli-tool using the command:
weather <sub-command..> <arguements...>
  1. For guidelines on how to use the tool, run:
weather --help