Hourly History

openweathermap.history_hourly
ActionBusiness appsconnection required

Calls the OpenWeather API with the connection's credentials.

Read hour-by-hour history for a window of past time from the Historical Weather API, bounded by an end timestamp or a count of hours.

Connection

Required
Yes — the node will not save without one
Auth type
API key
Providers
OpenWeather
Secret shape
the API key, or {"api_key": "…"}
Config it needs
units, lang, base_url
Resolved by
config.connection_id, else node.connection_id

Configuration

8 fields, 1 required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.

FieldTypeRequiredDefaultConstraintsExample
start
The first moment of the window, as a Unix timestamp in seconds UTC.
numberYes—≥ 01369728000
end
The last moment of the window, as a Unix timestamp in seconds UTC. Give this or 'cnt', never both.
numberNo—≥ 01369789200
cnt
How many hourly readings to return after 'start', instead of naming an 'end'.
numberNo—≥ 1—
place
A place name to resolve through the Geocoding API, as 'city', 'city,country code' or 'city,state code,country code' for the US — for example 'London,GB'.
stringNo——London,GB
lat
Latitude of the place to look up, from -90 to 90. Give it together with 'lon', or name a 'place' or a 'postcode' instead.
numberNo—-90–9051.5074
lon
Longitude of the place to look up, from -180 to 180. Give it together with 'lat', or name a 'place' or a 'postcode' instead.
numberConditional—-180–180; only with lat-0.1278
postcode
A post code and its two-letter country code, divided by a comma, resolved through the Geocoding API — for example '94040,US'.
stringNo——94040,US
units
The unit system for this call: 'standard' is Kelvin and metres per second, 'metric' is Celsius, 'imperial' is Fahrenheit. Defaults to the connection's setting.
stringNo—one of "standard", "metric", "imperial"—
  • At least one of place, lat, postcode must be set.
  • At least one of end, cnt must be set.

Example configuration

Every value below is the contract’s own example or default — nothing invented.

{
  "end": 1369789200,
  "lat": 51.5074,
  "lon": -0.1278,
  "place": "London,GB",
  "postcode": "94040,US",
  "start": 1369728000
}

Output

One shape.

result

FieldTypeExample
message
OpenWeather's internal message field.
string—
cod
OpenWeather's internal response code.
string—
city_id
The numeric city id these readings belong to.
number—
calctime
How long OpenWeather took to build the answer.
number—
cnt
How many hourly readings this answer carries.
number—
list
The hourly readings, each with 'dt', 'main', 'wind', 'clouds' and 'weather', plus 'rain' or 'snow' when there was precipitation.
array—
location.lat
The latitude this call actually used.
number—
location.lon
The longitude this call actually used.
number—
location.name
The place name the Geocoding API matched; empty when coordinates were given.
string—
location.country
The two-letter country code of the matched place, when one was geocoded.
string—
location.source
How the coordinates were reached: 'coordinates', 'geocode' or 'postcode'.
string—
{
  "calctime": 0,
  "city_id": 0,
  "cnt": 0,
  "cod": "",
  "list": [],
  "location": {
    "country": "",
    "lat": 0,
    "lon": 0,
    "name": "",
    "source": ""
  },
  "message": ""
}

Notes

  • The Historical Weather API is a paid OpenWeather add-on served from history.openweathermap.org; without it OpenWeather answers 401.
  • A 'place' or 'postcode' costs one extra Geocoding API call before the weather call; passing 'lat' and 'lon' skips it.

See Hourly History run in a workflow.

In a technical demo we add the OpenWeather connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.