Search by

omnilab / open-meteo

GlitchArt

Omnilab Open-Meteo: weather series at a point - hourly, every 15 minutes or daily, any variable Open-Meteo names, with the units it answers in - from the forecast API (92 days back, 16 ahead) and the historical archive (ERA5, from 1940), joined when a period spans both; free for non-commercial use,

1.x-dev 2026-10-14 23:29 UTC

This package is not auto-updated.

Last update: 2026-10-15 00:29:07 UTC


README

Open-Meteo for glitchr/omnilab: weather series at a point - hourly, every 15 minutes or daily, any variable Open-Meteo names - with the unit it answers in, from the forecast API (92 days back to 16 days ahead) or the historical archive (ERA5 and its successors, from 1940), joined when a period spans both. No key for non-commercial use.

$meteo = (new OpenMeteoSourceFactory($http))->create();
$tomorrow = new \DateTimeImmutable('tomorrow', new \DateTimeZone('Europe/Paris'));
[$temperature] = $meteo->series(new SeriesQuery(['temperature_2m'], new Point(48.5734, 7.7521), $tomorrow, $tomorrow));
$temperature->unit;                             // °C
$temperature->max();                            // the day's maximum
foreach ($temperature as [$time, $value]) {}    // 24 points, in the point's own time zone

[$max, $rain] = $meteo->series(new SeriesQuery(['temperature_2m', 'precipitation_sum'], $strasbourg,
    new \DateTimeImmutable('2025-07-01'), new \DateTimeImmutable('2025-07-31'), SeriesQuery::DAILY, Series::MAX));
omnilab:
    sources:
        meteo:
            factory: open-meteo
            options:
                api_key: ~                 # a commercial key: the calls go to customer-api.open-meteo.com
                timezone: auto             # the times' and days' zone when a query does not say
                models: ~                  # best_match; icon_seamless, ecmwf_ifs025, meteofrance_seamless...
                base_uri: ~                # a self-hosted instance (open-meteo/open-meteo on Docker)

Terms of use

Open-Meteo's terms: the free API is for non-commercial use, fewer than 10 000 calls a day, 5 000 an hour and 600 a minute; a commercial use needs a subscription and its key (api_key, which sends the calls to the customer hosts), or a self-hosted instance (base_uri). The data is licensed under CC BY 4.0: show "Weather data by Open-Meteo.com" with a link wherever its series are shown. A day's budget spent is a RateLimitedException.

See docs/.

License: MIT.