RapidAPI logo

Sign Up

Log In

YahooWeatherAPI

FREE
By dimashirokov
Updated 4 months ago
Weather
8.7/10
Popularity Score
310ms
Latency
100%
Success Rate

YahooWeatherAPI API Documentation

Get up-to-date weather information for a location.

View API Details
POSTgetWeatherForecast
POSTgetWeatherForecast

This endpoint allows to receive weather information.

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
Optional Parameters
filterLIST
OPTIONALThe array of data to be received. For example: wind, item.condition.text, astronomy.sunset. See README for more details and examples.
locationSTRING
OPTIONALThe location for the weather forecast as Text, example "chicago, il". Required if woeid not provided.
woeidSTRING
OPTIONALThe location for the weather forecast as a WOEID, example is 2487889 (San Diego, CA). Required if location not provided.
yqlSTRING
OPTIONALYour custom yql expression. Example: "select item.condition from weather.forecast where woeid = 2487889". NOTE: If provided yql parameter, other parameters will be ignored.
Request Snippet
unirest.post("https://YahooWeatherAPIdimashirokovV1.p.rapidapi.com/getWeatherForecast")
.header("X-RapidAPI-Host", "YahooWeatherAPIdimashirokovV1.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Content-Type", "application/x-www-form-urlencoded")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
Sample Response
Log inSign up

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.post("https://YahooWeatherAPIdimashirokovV1.p.rapidapi.com/getWeatherForecast")
.header("X-RapidAPI-Host", "YahooWeatherAPIdimashirokovV1.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Content-Type", "application/x-www-form-urlencoded")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication