v1

latestSwagger 2.02026-07-132137180.4 KB
16 day / daily Forecast

Returns a daily forecast - Given Lat/Lon.

Returns a daily forecast, where each point represents one day (24hr) period. Every point has a valid_date string in the format "YYYY-MM-DD". One day begins at 00:00 UTC, and ends at 23:59 UTC.

get/forecast/daily

Query parameters

latnumber double

Latitude component of location.

lonnumber double

Longitude component of location.

citystring string

City search.. Example - &city=Raleigh,NC or &city=Berlin,DE or city=Paris&country=FR

postal_codestring string

Postal Code. Example: 28546

countrystring string

Country Code (2 letter) - to be used with postal_code.

stationstring string

Station Call ID.

daysnumber

Number of days to return. Default 16.

units'S' | 'I' | 'M' string

Convert to units. Default Metric. Options (I = Imperial, M = Metric, S = Scientific)

lang'ar' | 'az' | 'be' | 'bg' | 'bs' | 'ca' | 'cs' | 'de' | 'fi' | 'fr' | 'el' | 'es' | 'et' | 'hr' | 'hu' | 'id' | 'it' | 'is' | 'kw' | 'nb' | 'nl' | 'pl' | 'pt' | 'ro' | 'ru' | 'sk' | 'sl' | 'sr' | 'sv' | 'tr' | 'uk' | 'zh' | 'zh-tw' string

Language (Default: English) See <a target='blank' href='/api/requests'>language field description</a>

keystring string required

Your registered API key.

Response

A forecast object.

city_namestring

Nearest city name

state_codestring

State Abbreviation

country_codestring

Country Abbreviation

latnumber

Latitude

lonnumber

Longitude

timezonestring

Local IANA time zone

Example response

{
  "city_name": "Raleigh",
  "state_code": "NC",
  "country_code": "US",
  "lat": 38.25,
  "lon": -78,
  "timezone": "America/New_York",
  "data": [
    {
      "valid_date": "2019-03-04",
      "datetime": "2019-03-04:17",
      "snow": 10.45,
      "snow_depth": 45,
      "precip": 1.1,
      "temp": 1,
      "dewpt": 1,
      "max_temp": 1.5,
      "min_temp": -1.23,
      "high_temp": 1.5,
      "low_temp": -1.23,
      "app_max_temp": 4,
      "app_min_temp": -2,
      "rh": 95,
      "clouds": 100,
      "clouds_low": 65,
      "clouds_mid": 100,
      "clouds_hi": 100,
      "weather": {
        "icon": "s02n",
        "code": 601,
        "description": "Snow"
      },
      "slp": 1012.89,
      "pres": 1005,
      "uv": 6.5,
      "ozone": 340,
      "vis": 3,
      "pop": 75,
      "moon_phase": 0.91,
      "moon_phase_lunation": 0.59,
      "sunrise_ts": 1530331260,
      "sunset_ts": 1530331260,
      "moonrise_ts": 1530331260,
      "moonset_ts": 1530331260,
      "pod": "n",
      "wind_spd": 13.85,
      "wind_dir": 105,
      "wind_cdir": "ENE",
      "wind_cdir_full": "East-North-East",
      "wind_gust_spd": 16
    }
  ]
}