Sand AISand AI MAGI-2MAGI-2 kini tersedia di SandBase: video 1080p dengan audio nativeCoba sekarang

Open-Meteo Air Quality

Dokumentasi API
https://api.sandbase.ai/v1/api/open-meteo/air-quality

Hourly air quality forecast for any coordinates: PM2.5, PM10, ozone, NO2, CO, dust, pollen and European/US AQI.

Harga
$0.0001USD / panggilan
Metode
POST
Respons
JSON
Parameter
2 wajib · 12 opsional

Playground

Input
WGS84 latitude of the location. Multiple coordinates can be comma-separated.
WGS84 longitude of the location (negative for the Americas). Multiple coordinates can be comma-separated.
Grid-cell preference for the coordinate. Default `nearest`.
Comma-separated list of current-condition variables to return. Same variable set as `hourly`.
Model domain. Default `auto`.
End of the interval, `yyyy-mm-dd` (ISO 8601).
Number of forecast days to return (0-7). Default 5.
Limit forecast to a given number of hours.
Comma-separated list of hourly variables to return. Common values: `pm10`, `pm2_5`, `carbon_monoxide`, `nitrogen_dioxide`, `sulphur_dioxide`, `ozone`, `aerosol_optical_depth`, `dust`, `uv_index`, `ammonia`, `european_aqi`, `us_aqi`, and pollen (`alder_pollen`, `birch_pollen`, `grass_pollen`, `mugwor
Number of past days to include (0-92). Default 0.
Include a given number of past hours.
Start of the interval, `yyyy-mm-dd` (ISO 8601).
Time output format. Default `iso8601`.
IANA time zone name (e.g. `Europe/Berlin`) or `auto` to resolve from coordinates. Defaults to `GMT`.
OutputSiap

Output Anda akan muncul di sini

Lengkapi input, lalu klik Run.

README API

Open-Meteo Air Quality API

Returns an hourly air quality forecast for a latitude and longitude. You choose the variables with hourly, such as pm10 and pm2_5, and the response gives one value per hour with its unit.

Use cases

  • Show a PM2.5 and PM10 forecast for a city in a health or weather app.
  • Warn users when the forecast for ozone or NO2 rises above a limit you set.
  • Compare particulate levels across several sites by sending comma-separated coordinates.
  • Add pollen or AQI values to a daily outlook for allergy sufferers.

Request

curl -X POST "https://api.sandbase.ai/v1/api/open-meteo/air-quality" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"latitude": "52.52", "longitude": "13.41", "hourly": "pm10,pm2_5", "forecast_days": 1}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
latitudestringYesWGS84 latitude of the location. Multiple coordinates can be comma-separated.
longitudestringYesWGS84 longitude of the location (negative for the Americas). Multiple coordinates can be comma-separated.
cell_selectionstringNoGrid-cell preference for the coordinate. Default nearest.
currentstringNoComma-separated list of current-condition variables to return. Same variable set as hourly.
domainsstringNoModel domain. Default auto.
end_datestringNoEnd of the interval, yyyy-mm-dd (ISO 8601).
forecast_daysintegerNoNumber of forecast days to return (0-7). Default 5.
forecast_hoursintegerNoLimit forecast to a given number of hours.
hourlystringNoComma-separated list of hourly variables to return. Common values: pm10, pm2_5, carbon_monoxide, nitrogen_dioxide, sulphur_dioxide, ozone, aerosol_optical_depth, dust, uv_index, ammonia, `european_aqi
past_daysintegerNoNumber of past days to include (0-92). Default 0.
past_hoursintegerNoInclude a given number of past hours.
start_datestringNoStart of the interval, yyyy-mm-dd (ISO 8601).
timeformatstringNoTime output format. Default iso8601.
timezonestringNoIANA time zone name (e.g. Europe/Berlin) or auto to resolve from coordinates. Defaults to GMT.

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "elevation": 38.0,
  "generationtime_ms": 0.3840923309326172,
  "hourly": {
    "pm10": [
      15.9
    ],
    "pm2_5": [
      13.0
    ],
    "time": [
      "2026-11-03T00:00"
    ]
  },
  "hourly_units": {
    "pm10": "μg/m³",
    "pm2_5": "μg/m³",
    "time": "iso8601"
  },
  "latitude": 52.5,
  "longitude": 13.400002,
  "timezone": "GMT",
  "timezone_abbreviation": "GMT",
  "utc_offset_seconds": 0
}

Response fields

FieldMeaning
hourly.time[]Timestamp of each hourly step, in ISO 8601 local time for the chosen timezone. Each position lines up with the same position in the other hourly lists.
hourly.pm10[]Forecast concentration of particles up to 10 µm for each hour. The unit is given in hourly_units.pm10.
hourly.pm2_5[]Forecast concentration of fine particles up to 2.5 µm for each hour. The unit is given in hourly_units.pm2_5.
hourly_units.pm10 / hourly_units.pm2_5Unit for each requested variable. In this response both are μg/m³.
hourly_units.timeFormat of the values in hourly.time[]. It is iso8601 here.
latitude / longitudeCoordinates of the grid cell the data comes from. They can differ slightly from the coordinates you sent.
elevationElevation of the grid cell, in the same response as the coordinates. The value here is 38.0.
timezone / timezone_abbreviation / utc_offset_secondsTime zone applied to the timestamps and its offset from UTC in seconds. The default is GMT with an offset of 0.
generationtime_msTime taken to generate the response, in milliseconds.

Notes

  • Each variable you list in hourly adds a matching list under hourly and an entry under hourly_units.
  • Use forecast_days (0-7) for the forecast length and past_days (0-92) to include earlier days. Or set start_date and end_date as yyyy-mm-dd.
  • Set timezone to an IANA name or auto to get local times. Without it, times are in GMT.
  • For weather variables at the same coordinates, call Open-Meteo Weather Forecast. To turn a place name into coordinates, use Open-Meteo Geocoding.

Pricing

$0.0001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

Jelajahi lebih lanjut

API Terkait

Semua APIs
APIHargaRespons
Open-Meteo$0.0001 per panggilanJSON
Open-Meteo$0.0001 per panggilanJSON
Open-Meteo$0.0001 per panggilanJSON
Open-Meteo$0.0001 per panggilanJSON
Open-Meteo$0.0001 per panggilanJSON
Open-Meteo$0.0001 per panggilanJSON

Pertanyaan

FAQ

Bagaimana cara menggunakan API Open-Meteo Air Quality?

Kirim permintaan POST ke https://api.sandbase.ai/v1/api/open-meteo/air-quality dengan kunci API SandBase Anda di header Authorization (Bearer) dan parameter sebagai body JSON. Anda juga dapat mencobanya di Playground di halaman ini tanpa menulis kode.

Berapa biaya API Open-Meteo Air Quality?

$0.0001 per panggilan, ditagihkan dari saldo SandBase Anda. Anda hanya dikenai biaya untuk panggilan yang Anda lakukan; tidak ada langganan.

Parameter apa yang diterima API Open-Meteo Air Quality?

Wajib: latitude (string) dan longitude (string). Opsional: cell_selection (salah satu dari land, sea, nearest), current (string), domains (salah satu dari auto, cams_europe, cams_global), end_date (string), forecast_days (integer) dan forecast_hours (integer) dan 6 lainnya. Tabel Parameters dan Playground di halaman ini mencantumkan setiap field.

Apa yang dikembalikan API Open-Meteo Air Quality?

Respons JSON yang dikembalikan dalam permintaan HTTP yang sama (sinkron). README di halaman ini menyertakan contoh respons.

Apakah saya memerlukan akun developer atau kunci API Open-Meteo?

Tidak. Open-Meteo Air Quality berjalan melalui SandBase, jadi satu kunci API SandBase mencakup endpoint ini dan setiap API serta model lain di katalog. Anda tidak perlu mendaftar akses API Open-Meteo secara terpisah.