# 2s.io Historical Weather API (ERA5)

> 2s.io Historical Weather API (ERA5) is a paid API for AI agents from 2s.io, paid per call via x402, $0.00144/call, status unknown (last checked 2026-09-15).

Returns per-day max/min/mean temperature, precipitation totals and hours, and max wind speed for any lat/lon coordinate over a historical date range using ERA5 reanalysis data (1940 to ~5 days ago).

## Facts

- Endpoint: GET https://2s.io/api/weather/history
- Price: $0.00144/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/2s-io-historical-weather-api-era5-d7b16fb8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_E8EByNk7jHIEvyA7S4NVi

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability 2s-io-historical-weather-api-era5-d7b16fb8
```

Example prompt: What was the daily high and low temperature, total rainfall, and max wind speed at coordinates 48.8566° N, 2.3522° E from June 1 to June 30 2022?

## When to prefer this

Use this endpoint when you need historical daily weather summaries (temperature, precipitation, wind) for any global coordinate going back to 1940. It is keyless and pay-per-call, making it ideal for one-off or agent-driven lookups without API key management. Prefer it over forecast APIs when you need past data, and over bulk climate datasets when you need a lightweight per-day summary for a specific point location within a 366-day window.

## Known failure modes

- Date range exceeds 366 days — API rejects the request
- Start or end date is in the future or within the last ~5 days — data not yet available
- Invalid lat/lon values — out-of-range coordinates cause errors
- Missing required query parameters (lat, lon, start, end) — returns 400 error
- Malformed date format (not YYYY-MM-DD) — parse error

## How this service works

Historical daily weather for any coordinate (ERA5 reanalysis, 1940→~5 days ago). Pass lat + lon + start + end (YYYY-MM-DD, range ≤366 days). Returns per-day max/min/mean temperature (°C), precipitation total (mm) + hours, and max wind (km/h). Source: Open-Meteo archive / ECMWF ERA5 (keyless).

## Output

A JSON array of daily records for each date in the requested range, each containing: max temperature (°C), min temperature (°C), mean temperature (°C), total precipitation (mm), precipitation hours, and max wind speed (km/h). Data is sourced from ECMWF ERA5 reanalysis, covering 1940 to approximately 5 days before the current date.

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "end": "2022-06-30",
   "lat": 48.8566,
   "lon": 2.3522,
   "start": "2022-06-01"
  }
 }
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "queryParams"
   ],
   "properties": {
    "type": {
     "const": "http"
    },
    "method": {
     "const": "GET"
    },
    "queryParams": {
     "required": [
      "lat",
      "lon",
      "start",
      "end"
     ],
     "properties": {
      "end": {
       "type": "string",
       "description": "End date YYYY-MM-DD (≤366 days after start)."
      },
      "lat": {
       "type": "number"
      },
      "lon": {
       "type": "number"
      },
      "start": {
       "type": "string",
       "description": "Start date YYYY-MM-DD."
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/2s-io-historical-weather-api-era5-d7b16fb8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 2s.io](https://www.zero.xyz/host/2s.io/llms.txt)
