meteo-portugal

0.2.15 • Public • Published

Weather forecast in Portugal

Retrieves weather forecasts from multiple (plus 1 specific for Portugal)

npm version Build Status codecov

Install

$ npm install meteo-portugal

Usage

You neet get a darksky API key from darksky.net for this data source

const {DarkSky, MeteoIST} = require('meteo-portugal');

const ist = new MeteoIST();
const ds = new DarkSky('key-from-darksky');

ds.forecastWeek(-9.2156, 38.4201) // (longitude, latitutde)
  .then(response => console.log(response))
  .catch(error => console.log(error));

ist.forecastWeek(-9.2156, 38.4201) // (longitude, latitutde)
  .then(response => console.log(response))
  .catch(error => console.log(error));

Test

$ OPENWEATHER_KEY='key-from-openweather' DARKSKY_KEY='key-from-darksky' npm test

Or see the full response by

$ OPENWEATHER_KEY='key-from-openweather' DARKSKY_KEY='key-from-darksky' npm visual-test

Dependencies (6)

Dev Dependencies (6)

Package Sidebar

Install

npm i meteo-portugal

Weekly Downloads

2

Version

0.2.15

License

GPL-3.0-or-later

Unpacked Size

26.9 kB

Total Files

12

Last publish

Collaborators

  • averissimo