Every source carries a MetaData record describing its coverage, resolution, variables, and access requirements:
MetaData(NASAPower())
MetaData("", "No published rate limit", :weather, Dict(:WD2M => "Wind direction at 2m (°)", :PRECTOTCORR => "Precipitation corrected (mm/day)", :CLOUD_AMT => "Cloud amount (%)", :CLRSKY_SFC_SW_DWN => "Clear-sky surface shortwave downward irradiance (MJ/m²/day)", :ALLSKY_SFC_SW_DWN => "All-sky surface shortwave downward irradiance (MJ/m²/day)", :RH2M => "Relative humidity at 2m (%)", :WS10M => "Wind speed at 10m (m/s)", :ALLSKY_SFC_LW_DWN => "All-sky surface longwave downward irradiance (W/m²)", :WD10M => "Wind direction at 10m (°)", :WS2M => "Wind speed at 2m (m/s)"…), :raster, "55 km", "Global", :timeseries, Day(1), "1981-present", "Open Data (NASA)", "https://power.larc.nasa.gov/docs/services/api/", Dict("DataFrames" => "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"))
MetaData(OpenMeteoArchive())
MetaData("", "10,000 calls/day (non-commercial)", :weather, Dict(:temperature_2m_mean => "Daily mean temperature at 2m (°C)", :wind_direction_10m_dominant => "Daily dominant wind direction (°)", :apparent_temperature_max => "Daily maximum apparent temperature (°C)", :surface_pressure => "Surface pressure (hPa)", :precipitation_sum => "Daily total precipitation (mm)", :wind_gusts_10m_max => "Daily maximum wind gusts at 10m (km/h)", :precipitation_hours => "Daily hours with precipitation", :temperature_2m => "Air temperature at 2m (°C)", :rain_sum => "Daily total rain (mm)", :wind_direction_10m => "Wind direction at 10m (°)"…), :raster, "25 km", "Global", :timeseries, Hour(1), "1940-present", "CC BY 4.0", "https://open-meteo.com/en/docs/historical-weather-api", Dict("DataFrames" => "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"))
Plan / Fetch Workflow
Every data request follows two steps:
Plan — DataAccessPlan(source, extent, start_date, stop_date; kw...) builds a plan describing the API calls that will be made, without executing them.
Fetch — fetch(plan) executes the plan, downloads data, and returns file paths to cached JSON files.
The interface is the same regardless of which source you choose.
Step 1: Create a Plan
Pass a data source, a location (longitude, latitude), a date range, and the variables you want. Each source has its own variable names — check its MetaData or documentation page for the list.
# NASA POWER — daily temperature and precipitationplan =DataAccessPlan(NASAPower(), (-74.0, 40.7),Date(2024, 7, 1), Date(2024, 7, 14); variables = [:T2M, :PRECTOTCORR])
DataAccessPlan for nasapower
Extent: Point(40.7, -74.0)
Time: 2024-07-01 to 2024-07-14 (14 days)
Variables: T2M, PRECTOTCORR
community: AG
query_type: point
API calls: 1
Est. size: 224 bytes
Request 1: GET Point(40.7, -74.0), 14 days → nasapower/f4aeeed25010a44.json
The plan shows you exactly what will be fetched — number of API calls, estimated size, time range, and variables — before any network requests are made.
DataAccessPlan accepts any GeoInterface.jl-compatible geometry as the spatial extent. The geometry type determines how coordinates are sent to the API:
DataAccessPlan for nasapower
Extent: 2 points
Time: 2024-01-01 to 2024-01-07 (7 days)
Variables: T2M
community: AG
query_type: multi_point
API calls: 2
Est. size: 112 bytes
Request 1: GET Point(40.7, -74.0), 7 days → nasapower/c378f65586265649.json
Request 2: GET Point(41.9, -87.6), 7 days → nasapower/ce8f13f38b3cb8e.json