API reference

https://weatherapi.projecteol.ru/api/v1/

← Quick start

Authentication

Activate a plan in your account. Create a key with weather.read and send it with every request. The secret is shown once.

HTTP
Authorization: ApiKey eol_your_secret_key

Available endpoints

GET/api/v1/metadata/

Your plan’s fields, coverage, source and forecast bounds in period.start and period.end.

GET/api/v1/point/

Values and units for one location at an exact forecast timestamp.

GET/api/v1/series/

A paginated time series for one location. Available with a Free API key.

Query parameters

latitude, longitude · point, series
Latitude from −90 to 90 and longitude from −180 to 180 within the dataset coverage.
time · point
An exact ISO 8601 timestamp with Z or a UTC offset. Start with period.start from metadata.
start, end · series
Both bounds are inclusive and must exactly match dataset timestamps. Maximum span is 31 days. Metadata shows the outer bounds only. Intermediate hours may be unavailable.
parameters · point, series
Comma-separated codes from metadata. If omitted, the API returns all available fields.
interpolation · point, series
nearest uses the closest grid cell and is the default. linear interpolates values from the four surrounding grid cells.
page, page_size · series
Defaults to page 1 and 100 results per page. Page size is 1–500. Follow next_page until it is null. Each page counts as a separate request.

Time series for Astana

This example uses exact metadata bounds and follows next_page. If a dataset spans more than 31 days, the example requests its first timestamp.

Python
import json
from datetime import datetime, timedelta
from urllib.parse import urlencode
from urllib.request import Request, urlopen

BASE = "https://weatherapi.projecteol.ru/api/v1/"
HEADERS = {"Authorization": "ApiKey eol_your_key"}

def get(path, **params):
    url = BASE + path + ("?" + urlencode(params) if params else "")
    with urlopen(Request(url, headers=HEADERS), timeout=15) as response:
        return json.load(response)

def utc_time(timestamp):
    return datetime.fromisoformat(timestamp.replace("Z", "+00:00"))

period = get("metadata/")["period"]
start, end = period["start"], period["end"]
if utc_time(end) - utc_time(start) > timedelta(days=31):
    end = start

page = 1
while page is not None:
    result = get("series/", latitude=51.1694, longitude=71.4491,
                 start=start, end=end, page=page,
                 parameters="surface.air_temperature_2m,wind_speed_10m")
    for row in result["results"]:
        print(json.dumps(row))
    page = result["next_page"]

Errors and limits

400

Check the request format, coordinates, field codes and timestamp availability.

401

Send the Authorization header with a valid key. Replace a revoked key.

403

Check weather.read, the active plan, and whether the plan allows the field, operation or key.

429

The per-minute rate or monthly quota was reached. Retry-After gives the wait in seconds.

503

The published forecast is temporarily unavailable. Retry after a delay.

Both Free API limits are per account. The monthly quota resets at the start of the calendar month in UTC.

Open Swagger ↗