data
Open-Meteo Lua API for KosmoKrator Agents
Agent-facing Lua documentation and function reference for the Open-Meteo KosmoKrator integration.Lua Namespace
Agents call this integration through app.integrations.open_meteo.*.
Use lua_read_doc("integrations.open-meteo") inside KosmoKrator to discover the same reference at runtime.
Call Lua from the Headless CLI
Use kosmo integrations:lua when a shell script, CI job, cron job, or another coding CLI should run a deterministic
Open-Meteo workflow without starting an interactive agent session.
kosmo integrations:lua --eval 'dump(app.integrations.open_meteo.weather_forecast({}))' --json kosmo integrations:lua --eval 'print(docs.read("open-meteo"))' --json
kosmo integrations:lua --eval 'print(docs.read("open-meteo.weather_forecast"))' --json Workflow file
Put repeatable logic in a Lua file, then execute it with JSON output for the calling process.
local open_meteo = app.integrations.open_meteo
local result = open_meteo.weather_forecast({})
dump(result) kosmo integrations:lua workflow.lua --json
kosmo integrations:lua workflow.lua --force --json integrations:lua exposes app.integrations.open_meteo, app.mcp.*, docs.*, json.*, and regex.*. Use app.integrations.open_meteo.default.* or app.integrations.open_meteo.work.* when you configured named credential accounts.
MCP-only Lua
If the script only needs configured MCP servers and does not need Open-Meteo, use the narrower mcp:lua command.
# Use mcp:lua for MCP-only scripts; use integrations:lua for this integration namespace.
kosmo mcp:lua --eval 'dump(mcp.servers())' --json Agent-Facing Lua Docs
This is the rendered version of the full Lua documentation exposed to agents when they inspect the integration namespace.
Open-Meteo
Open-Meteo tools are exposed under app.integrations.open_meteo. The integration uses public Open-Meteo APIs and requires no credentials for standard non-commercial use.
Coverage
open_meteo_forecast-https://api.open-meteo.com/v1/forecastopen_meteo_model_forecast-https://api.open-meteo.com/v1/{model_endpoint}open_meteo_historical_weather-https://archive-api.open-meteo.com/v1/archiveopen_meteo_historical_forecast-https://historical-forecast-api.open-meteo.com/v1/forecastopen_meteo_ensemble-https://ensemble-api.open-meteo.com/v1/ensembleopen_meteo_seasonal_forecast-https://seasonal-api.open-meteo.com/v1/seasonalopen_meteo_climate-https://climate-api.open-meteo.com/v1/climateopen_meteo_marine-https://marine-api.open-meteo.com/v1/marineopen_meteo_air_quality-https://air-quality-api.open-meteo.com/v1/air-qualityopen_meteo_satellite_radiation-https://satellite-api.open-meteo.com/v1/satellite-radiationopen_meteo_flood-https://flood-api.open-meteo.com/v1/floodopen_meteo_elevation-https://api.open-meteo.com/v1/elevationopen_meteo_geocoding_search-https://geocoding-api.open-meteo.com/v1/searchopen_meteo_geocoding_get-https://geocoding-api.open-meteo.com/v1/get
Usage Notes
Pass official Open-Meteo query parameters as top-level tool arguments. For less common or newly added parameters, pass them inside query; top-level arguments override matching keys in query. Array values are encoded as comma-separated lists, matching Open-Meteo’s documented variable selection style.
Most weather endpoints require latitude and longitude. Historical and climate endpoints also require start_date and end_date. Climate calls require models and daily. Geocoding search uses name, while geocoding get uses id.
open_meteo_model_forecast accepts model_endpoint, for example gfs, ecmwf, icon, meteofrance, ukmo, jma, kma, metno, gem, bom, cma, knmi, dmi, or meteoitalia.
Examples
local forecast = app.integrations.open_meteo.open_meteo_forecast({
latitude = 52.52,
longitude = 13.41,
hourly = { "temperature_2m", "precipitation" },
daily = { "temperature_2m_max", "temperature_2m_min" },
timezone = "Europe/Berlin"
})
local berlin = app.integrations.open_meteo.open_meteo_geocoding_search({
name = "Berlin",
count = 5,
language = "en"
})
local air = app.integrations.open_meteo.open_meteo_air_quality({
latitude = 52.52,
longitude = 13.41,
hourly = { "pm10", "pm2_5", "us_aqi" }
})
Responses are decoded Open-Meteo JSON responses. Open-Meteo may return a JSON object with error = true and reason; the integration converts that into a tool error.
Raw agent markdown
# Open-Meteo
Open-Meteo tools are exposed under `app.integrations.open_meteo`. The integration uses public Open-Meteo APIs and requires no credentials for standard non-commercial use.
## Coverage
- `open_meteo_forecast` - `https://api.open-meteo.com/v1/forecast`
- `open_meteo_model_forecast` - `https://api.open-meteo.com/v1/{model_endpoint}`
- `open_meteo_historical_weather` - `https://archive-api.open-meteo.com/v1/archive`
- `open_meteo_historical_forecast` - `https://historical-forecast-api.open-meteo.com/v1/forecast`
- `open_meteo_ensemble` - `https://ensemble-api.open-meteo.com/v1/ensemble`
- `open_meteo_seasonal_forecast` - `https://seasonal-api.open-meteo.com/v1/seasonal`
- `open_meteo_climate` - `https://climate-api.open-meteo.com/v1/climate`
- `open_meteo_marine` - `https://marine-api.open-meteo.com/v1/marine`
- `open_meteo_air_quality` - `https://air-quality-api.open-meteo.com/v1/air-quality`
- `open_meteo_satellite_radiation` - `https://satellite-api.open-meteo.com/v1/satellite-radiation`
- `open_meteo_flood` - `https://flood-api.open-meteo.com/v1/flood`
- `open_meteo_elevation` - `https://api.open-meteo.com/v1/elevation`
- `open_meteo_geocoding_search` - `https://geocoding-api.open-meteo.com/v1/search`
- `open_meteo_geocoding_get` - `https://geocoding-api.open-meteo.com/v1/get`
## Usage Notes
Pass official Open-Meteo query parameters as top-level tool arguments. For less common or newly added parameters, pass them inside `query`; top-level arguments override matching keys in `query`. Array values are encoded as comma-separated lists, matching Open-Meteo's documented variable selection style.
Most weather endpoints require `latitude` and `longitude`. Historical and climate endpoints also require `start_date` and `end_date`. Climate calls require `models` and `daily`. Geocoding search uses `name`, while geocoding get uses `id`.
`open_meteo_model_forecast` accepts `model_endpoint`, for example `gfs`, `ecmwf`, `icon`, `meteofrance`, `ukmo`, `jma`, `kma`, `metno`, `gem`, `bom`, `cma`, `knmi`, `dmi`, or `meteoitalia`.
## Examples
```lua
local forecast = app.integrations.open_meteo.open_meteo_forecast({
latitude = 52.52,
longitude = 13.41,
hourly = { "temperature_2m", "precipitation" },
daily = { "temperature_2m_max", "temperature_2m_min" },
timezone = "Europe/Berlin"
})
local berlin = app.integrations.open_meteo.open_meteo_geocoding_search({
name = "Berlin",
count = 5,
language = "en"
})
local air = app.integrations.open_meteo.open_meteo_air_quality({
latitude = 52.52,
longitude = 13.41,
hourly = { "pm10", "pm2_5", "us_aqi" }
})
```
Responses are decoded Open-Meteo JSON responses. Open-Meteo may return a JSON object with `error = true` and `reason`; the integration converts that into a tool error. local result = app.integrations.open_meteo.weather_forecast({})
print(result) Functions
weather_forecast Read
Get standard Open-Meteo forecast data.
- Lua path
app.integrations.open_meteo.weather_forecast- Full name
open-meteo.open_meteo_forecast
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
model_forecast Read
Get forecast data from a specific Open-Meteo model endpoint.
- Lua path
app.integrations.open_meteo.model_forecast- Full name
open-meteo.open_meteo_model_forecast
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
historical_weather Read
Get historical weather archive data.
- Lua path
app.integrations.open_meteo.historical_weather- Full name
open-meteo.open_meteo_historical_weather
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
historical_forecast Read
Get past forecast model runs.
- Lua path
app.integrations.open_meteo.historical_forecast- Full name
open-meteo.open_meteo_historical_forecast
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
ensemble_forecast Read
Get ensemble forecast data.
- Lua path
app.integrations.open_meteo.ensemble_forecast- Full name
open-meteo.open_meteo_ensemble
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
seasonal_forecast Read
Get seasonal and sub-seasonal forecast data.
- Lua path
app.integrations.open_meteo.seasonal_forecast- Full name
open-meteo.open_meteo_seasonal_forecast
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
climate_projections Read
Get climate projection data.
- Lua path
app.integrations.open_meteo.climate_projections- Full name
open-meteo.open_meteo_climate
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
marine_forecast Read
Get marine weather and wave forecasts.
- Lua path
app.integrations.open_meteo.marine_forecast- Full name
open-meteo.open_meteo_marine
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
air_quality Read
Get air quality forecasts.
- Lua path
app.integrations.open_meteo.air_quality- Full name
open-meteo.open_meteo_air_quality
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
satellite_radiation Read
Get satellite radiation data.
- Lua path
app.integrations.open_meteo.satellite_radiation- Full name
open-meteo.open_meteo_satellite_radiation
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
flood_forecast Read
Get flood and river discharge forecasts.
- Lua path
app.integrations.open_meteo.flood_forecast- Full name
open-meteo.open_meteo_flood
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
elevation Read
Get elevation for coordinates.
- Lua path
app.integrations.open_meteo.elevation- Full name
open-meteo.open_meteo_elevation
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
geocoding_search Read
Search locations by name or postal code.
- Lua path
app.integrations.open_meteo.geocoding_search- Full name
open-meteo.open_meteo_geocoding_search
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
geocoding_get Read
Resolve a geocoding location ID.
- Lua path
app.integrations.open_meteo.geocoding_get- Full name
open-meteo.open_meteo_geocoding_get
| Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||