# OpenAQ on Onekey > 2 endpoints for OpenAQ (0 stable, 2 beta), 5 credits each. Category: Maps, weather & space. One key, one JSON shape. Base URL: https://api.onekey.dev Auth: header `x-api-key: `. Call shape: `GET /v1/{platform}/{endpoint}?{params}`. Every response is `{success, data, metadata, error}`; check `success` first. Cost is in `metadata.credits_charged`. Free when served from cache (0.2 credit for a cached response over 100 KB). Failed and not-found calls are refunded. Status: stable = verified against the live source; beta = not yet verified, fields may be missing. Page: https://onekey.dev/platforms/openaq Reference (Markdown): https://onekey.dev/docs/api/openaq.md All docs: https://onekey.dev/llms.txt ## Canonical fields returned Unified-schema fields (same names on every platform), with how many of the 2 mapped OpenAQ endpoints return each: - `entity.date` (ISO 8601 date): 2 - `entity.id` (string): 2 - `place.lat` (number): 2 - `place.lon` (number): 2 - `entity.description` (string): 1 - `entity.name` (string): 1 - plus 2 platform-specific fields under `ext.` ## Endpoints ### openaq.latest Latest measurements at an OpenAQ location. - Price: 5 credits per fresh call. Status: beta. Returns: a list. - Request: `GET https://api.onekey.dev/v1/openaq/latest?id=2178` with header `x-api-key: YOUR_API_KEY` - Parameters: - `id` (string, required): OpenAQ location id - Fields returned: `entity.id`, `entity.date`, `place.lat`, `place.lon`, `ext.value` - Reference: https://onekey.dev/docs/api/openaq/latest.md ### openaq.locations Air-quality monitoring locations (OpenAQ v3). - Price: 5 credits per fresh call. Status: beta. Returns: a list. - Request: `GET https://api.onekey.dev/v1/openaq/locations?limit=5` with header `x-api-key: YOUR_API_KEY` - Parameters: - `limit` (string, optional, default 20): Rows (1-100) - `country_id` (string, optional, default 79): OpenAQ country id (e.g. 79 = Germany) - Fields returned: `entity.id`, `entity.name`, `entity.description`, `place.lat`, `place.lon`, `entity.date`, `ext.symbol` - Reference: https://onekey.dev/docs/api/openaq/locations.md ## Sample request ```bash curl "https://api.onekey.dev/v1/openaq/latest?id=2178" \ -H "x-api-key: YOUR_API_KEY" ```