Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

weathers-watch

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

weathers-watch

A free and asynchronous weather API wrapper made in javascript.

  • 1.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
847
increased by134.63%
Maintainers
1
Weekly downloads
 
Created
Source

weathers-watch

npm building workflow license alt text

A stable and free API to get weather forecast worldwide.

Features

  • unlimited request
  • don't require any API key
  • service available more than 10 years
  • fetch fresh data

Installation

Install via NPM:

npm install weathers-watch

Usage

first parameter is city: string second parameter is country: string fetch weather data by following:

javascript

var { getWeather } = require("weathers-watch");

var weatherResult = await getWeather('london', 'united kingdom');
console.log(weatherResult);
TypeScript

import { getWeather } from 'weathers-watch';

var weatherResult = await getWeather('london', 'united kingdom');
console.log(weatherResult);
Result
{
  location: 'London',
  locationDetail: 'England, United Kingdom',
  currentWeather: {
    temperature: '4°C',
    dewPoint: '2°C',
    barometer: '99.6 kPa',
    wind: 'SSW 15 km/h',
    humidity: '86.8 %',
    visibility: 'n/a',
    time: 'Updated Jan 15, 2023 8:20 PM'
  },
  forecastSummary: [
    {
      day: 'Today',
      date: 'Jan 15th',
      result: 'Mostly Sunny',
      min: '6°C',
      max: undefined
    },
    {
      day: 'Monday',
      date: 'Jan 16th',
      result: 'Mostly Cloudy',
      min: '3°C',
      max: '1°C'
    },
    {
      day: 'Tuesday',
      date: 'Jan 17th',
      result: 'Mostly Sunny',
      min: '1°C',
      max: '-2°C'
    },
    {
      day: 'Wednesday',
      date: 'Jan 18th',
      result: 'Mostly Cloudy',
      min: '3°C',
      max: '-2°C'
    },
    {
      day: 'Thursday',
      date: 'Jan 19th',
      result: 'Mix of Cloud and Sun',
      min: '2°C',
      max: '1°C'
    }
  ],
  forecastDetails: [
    {
      date: 'Sunday, January 15th, 2023',
      results: [
        {
          time: 'Sunday Evening',
          forecast: 'Clear with cloudy periods. Windy at times.',
          temperature: 'Temperature: 3°C'
        }
      ]
    },
    {
      date: 'Monday, January 16th, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Cloudy with showers likely. Showers possibly mixed with wet flurries. 3 to 6 mm of rain.',
          temperature: undefined
        },
        {
          time: 'Monday Morning',
          forecast: 'Cloudy with a few showers or wet flurries. 4 to 9 mm of rain. Windy at times.',
          temperature: 'Temperature: 2°C'
        },
        {
          time: 'Monday Afternoon',
          forecast: 'Cloudy with a slight chance of showers. Showers possibly mixed with wet flurries. Windy at times.',
          temperature: 'Temperature: 3°C'
        },
        {
          time: 'Monday Evening',
          forecast: 'Cloudy with clear periods. Windy at times.',
          temperature: 'Temperature: 1°C'
        }
      ]
    },
    {
      date: 'Tuesday, January 17th, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Clear with cloudy periods.',
          temperature: undefined
        },
        {
          time: 'Tuesday Morning',
          forecast: 'Cloudy.',
          temperature: 'Temperature: -1°C'
        },
        {
          time: 'Tuesday Afternoon',
          forecast: 'A mix of cloud and sun.',
          temperature: 'Temperature: 1°C'
        },
        {
          time: 'Tuesday Evening',
          forecast: 'Clear with cloudy periods.',
          temperature: 'Temperature: -2°C'
        }
      ]
    },
    {
      date: 'Wednesday, January 18th, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Mostly clear.',
          temperature: undefined
        },
        {
          time: 'Wednesday Morning',
          forecast: 'Cloudy with sunny periods with a slight chance of flurries. Windy at times.',
          temperature: 'Temperature: 0°C'
        },
        {
          time: 'Wednesday Afternoon',
          forecast: 'Cloudy with sunny periods with a slight chance of showers. Showers possibly mixed with wet flurries. Windy at times.',
          temperature: 'Temperature: 3°C'
        },
        {
          time: 'Wednesday Evening',
          forecast: 'Cloudy with clear periods with a slight chance of flurries or showers. Windy.',
          temperature: 'Temperature: 1°C'
        }
      ]
    },
    {
      date: 'Thursday, January 19th, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Cloudy with clear periods. Windy.',
          temperature: undefined
        },
        {
          time: 'Thursday Morning',
          forecast: 'Sunny with cloudy periods. Windy.',
          temperature: 'Temperature: 1°C'
        },
        {
          time: 'Thursday Afternoon',
          forecast: 'A mix of cloud and sun. Windy at times.',
          temperature: 'Temperature: 2°C'
        },
        {
          time: 'Thursday Evening',
          forecast: 'A mix of cloudy and clear skies. Windy at times.',
          temperature: 'Temperature: 1°C'
        }
      ]
    },
    {
      date: 'Friday, January 20th, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Clear.',
          temperature: undefined
        },
        {
          time: 'Friday Morning',
          forecast: 'Sunny.',
          temperature: 'Temperature: 1°C'
        },
        {
          time: 'Friday Afternoon',
          forecast: 'Sunny.',
          temperature: 'Temperature: 3°C'
        },
        {
          time: 'Friday Evening',
          forecast: 'A mix of cloudy and clear skies.',
          temperature: 'Temperature: -0°C'
        }
      ]
    },
    {
      date: 'Saturday, January 21st, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Cloudy.',
          temperature: undefined
        },
        {
          time: 'Saturday Morning',
          forecast: 'Cloudy with a slight chance of showers. Windy at times.',
          temperature: 'Temperature: 3°C'
        },
        {
          time: 'Saturday Afternoon',
          forecast: 'Cloudy with a chance of showers. Showers possibly mixed with wet flurries. 1 to 3 mm of rain. Windy at times.',
          temperature: 'Temperature: 4°C'
        },
        {
          time: 'Saturday Evening',
          forecast: 'Cloudy with a chance of showers. 1 to 3 mm of rain. Windy at times.',
          temperature: 'Temperature: 3°C'
        }
      ]
    },
    {
      date: 'Sunday, January 22nd, 2023',
      results: [
        {
          time: 'Overnight',
          forecast: 'Cloudy with a slight chance of showers. Windy at times.',
          temperature: undefined
        },
        {
          time: 'Sunday Morning',
          forecast: 'Cloudy with sunny periods.',
          temperature: 'Temperature: 4°C'
        }
      ]
    }
  ]
}

Support

Contributors

Pull requests are always welcome! Please base pull requests against the main branch and follow the contributing guide.

if your pull requests makes documentation changes, please update readme file.

License

This project is licensed under the terms of the MIT license

Keywords

FAQs

Package last updated on 15 Jan 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc