# AirNow API

> AirNow returns current air quality, pollutant readings, and forecasts, available as a workflow and API.

AirNow returns current air quality, pollutant readings, and today’s and tomorrow’s forecasts. Get air quality needs a US city and state or five-digit ZIP code, or a covered Canadian or Mexican city.

- Page: https://fous.com/tools/airnow
- Handle: `@airnow`
- Category: [Weather](https://fous.com/tools/category/weather)
- Source website: https://airnow.gov
- Last verified: Sep 29, 2026

## Methods

### Get air quality

Operation `get_air_quality`, version 1. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.

Get AirNow current air quality, reported pollutant readings, and today’s and tomorrow’s forecasts for a US city or ZIP code, or a covered Canadian or Mexican city. A forecast AQI or an entire forecast may be unavailable even when a category or current reading is shown.

**Input**

| Field | Type | Required | Example | Description |
|---|---|---|---|---|
| `location` | string | yes | `"Denver, CO"` | City and state, a five-digit US ZIP code, or a covered Canadian or Mexican city, for example Denver, CO or 94103. |

**Input schema**

```json
{
  "type": "object",
  "required": [
    "location"
  ],
  "properties": {
    "location": {
      "type": "string",
      "description": "City and state, a five-digit US ZIP code, or a covered Canadian or Mexican city, for example Denver, CO or 94103.",
      "examples": [
        "Denver, CO",
        "94103"
      ]
    }
  },
  "additionalProperties": false,
  "examples": [
    {
      "location": "Denver, CO"
    },
    {
      "location": "94103"
    }
  ]
}
```

**Output**

| Field | Type | Example | Description |
|---|---|---|---|
| `aqi` | integer or null | `42` |  |
| `category` | string or null | `"Good"` |  |
| `airnow_url` | string | `"https://www.airnow.gov/?reportingArea=Denver-Boulder&stateCode=CO"` |  |
| `pollutants` | array |  |  |
| `pollutants[].aqi` | integer or null | `26` |  |
| `pollutants[].category` | string or null | `"Good"` |  |
| `pollutants[].pollutant` | string | `"Ozone"` |  |
| `health_advice` | string or null | `"Air quality is good. Enjoy outdoor activities."` |  |
| `main_pollutant` | string or null | `"PM10"` |  |
| `reporting_area` | string | `"Denver-Boulder, CO"` |  |
| `observation_time` | string or null | `"2026-09-29T05:00:00-06:00"` |  |
| `today_forecast_aqi` | integer or null | `53` |  |
| `forecast_discussion` | string or null |  |  |
| `today_forecast_date` | string or null | `"2026-09-29"` |  |
| `tomorrow_forecast_aqi` | integer or null |  |  |
| `tomorrow_forecast_date` | string or null | `"2026-09-30"` |  |
| `today_forecast_category` | string or null | `"Good"` |  |
| `tomorrow_forecast_category` | string or null | `"Moderate"` |  |

**Example input**

```json
{
  "location": "Denver, CO"
}
```

**Example output**

```json
{
  "aqi": 42,
  "category": "Good",
  "airnow_url": "https://www.airnow.gov/?reportingArea=Denver-Boulder&stateCode=CO",
  "pollutants": [
    {
      "aqi": 26,
      "category": "Good",
      "pollutant": "Ozone"
    },
    {
      "aqi": 16,
      "category": "Good",
      "pollutant": "PM2.5"
    },
    {
      "aqi": 42,
      "category": "Good",
      "pollutant": "PM10"
    }
  ],
  "health_advice": "Air quality is good. Enjoy outdoor activities.",
  "main_pollutant": "PM10",
  "reporting_area": "Denver-Boulder, CO",
  "observation_time": "2026-09-29T05:00:00-06:00",
  "today_forecast_aqi": null,
  "forecast_discussion": null,
  "today_forecast_date": "2026-09-29",
  "tomorrow_forecast_aqi": null,
  "tomorrow_forecast_date": "2026-09-30",
  "today_forecast_category": "Good",
  "tomorrow_forecast_category": null
}
```

## Quick start

Replace `YOUR_API_KEY` with a Fous API key. To create one, open Developers at the bottom of Fous Studio, turn on Developer mode, then go to API keys (https://app.fous.com/keys). Change the values in `input` to run the same tool on new data.

```bash
curl 'https://api.fous.com/v1/query' \
  --fail-with-body --silent --show-error --max-time 180 \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "api": "@airnow",
  "visibility": "public",
  "operation": "get_air_quality",
  "version": 1,
  "input": {
    "location": "Denver, CO"
  },
  "response": {
    "format": "json"
  }
}'
```

```python
# Save as fous.py and run with python3 fous.py. No packages needed.
import json
import urllib.error
import urllib.request

api_key = "YOUR_API_KEY"

body = json.loads("{\n  \"api\": \"@airnow\",\n  \"visibility\": \"public\",\n  \"operation\": \"get_air_quality\",\n  \"version\": 1,\n  \"input\": {\n    \"location\": \"Denver, CO\"\n  },\n  \"response\": {\n    \"format\": \"json\"\n  }\n}")
request = urllib.request.Request(
    "https://api.fous.com/v1/query",
    data=json.dumps(body).encode("utf-8"),
    headers={
        "Authorization": f"Bearer {api_key}",
        "Content-Type": "application/json",
    },
    method="POST",
)
try:
    with urllib.request.urlopen(request, timeout=180) as response:
        result = json.load(response)
except urllib.error.HTTPError as error:
    raise RuntimeError(f"HTTP {error.code}: {error.read().decode('utf-8', errors='replace')}") from error
if result.get("success") is False:
    raise RuntimeError(result.get("error", {}).get("message", "Request failed"))
print(json.dumps(result["data"]["output"], indent=2))
```

```typescript
// Save as fous.mts and run with npx tsx fous.mts.
const apiKey = "YOUR_API_KEY";

const response = await fetch("https://api.fous.com/v1/query", {
  method: "POST",
  headers: {
    "Authorization": `Bearer ${apiKey}`,
    "Content-Type": "application/json",
  },
  signal: AbortSignal.timeout(180_000),
  body: JSON.stringify({
  "api": "@airnow",
  "visibility": "public",
  "operation": "get_air_quality",
  "version": 1,
  "input": {
    "location": "Denver, CO"
  },
  "response": {
    "format": "json"
  }
}),
});
type ApiResult = { success: boolean; data?: { output: unknown }; error?: { message: string } };
const result: ApiResult = await response.json();
if (!response.ok || result.success === false) {
  throw new Error(result.error?.message ?? `HTTP ${response.status}`);
}
if (!result.data) throw new Error("Missing API response data");
console.log(result.data.output);
```

## Use from an AI assistant

Connect this tool to Claude Code, Claude Desktop, Cursor, VS Code, Codex and any MCP client as its own MCP server. Each method is a typed tool whose arguments are the method’s input.

- Server URL: `https://api.fous.com/mcp/tools/airnow`
- Authorization: `Authorization: Bearer <Fous API key>`

**Tools**

- `get_air_quality`: Get air quality. 1 credit per completed call. Failed calls without a completed billing receipt are free; completed work can remain charged if delivery is interrupted.
- `fous_get_run`: the result of a run that was still going, by its `request_id`. Free.

Claude Code:

```bash
claude mcp add --scope user --transport http fous-airnow https://api.fous.com/mcp/tools/airnow --header "Authorization: Bearer ${FOUS_API_KEY:?Set FOUS_API_KEY to your Fous API key}"
```

To give the assistant every tool, connect `https://api.fous.com/mcp`: it finds one with `fous_search_tools` and runs it with `fous_run_tool`. Setup for other clients: https://fous.com/llms-full.txt.

## Use cases

- Check reported air quality for a location
- Compare pollutant readings across locations
- Review today’s and tomorrow’s air quality forecasts
- Share health advice with local teams

## FAQ

### Can I run it with my own inputs?

Yes. Change the inputs in Studio and press Run, or send new inputs from your code, or ask a connected AI assistant.

### Can I call this AirNow tool as an API?

Yes. Send a POST request to /v1/query with your Fous API key and the inputs, and get JSON back.

### How much does it cost?

Each completed run costs 1 credit. Failed runs without a completed receipt are free; completed work can remain charged if delivery is interrupted. With pay as you go, a credit costs 1¢. Monthly plans cost less per credit.

### Do I need a AirNow account?

No. You only need a Fous account.

### How current is the data?

Fous gets the data from airnow.gov when you run it. Some results are reused for up to 24 hours, and results that use your account or key are never reused. It was last verified on Sep 29, 2026.

### What air quality is reported for a location?

Get air quality returns current air quality, its category, and observation time for the supplied location.

### Which pollutants and pollutant categories are reported?

Get air quality returns reported pollutants, their readings, and categories.

### What are today’s and tomorrow’s air quality forecasts?

Get air quality returns available forecasts and forecast categories. An AQI or an entire forecast may be unavailable.

## Related

- [IQAir API](https://fous.com/tools/iqair.md): City air quality readings and forecasts from IQAir.
- [AccuWeather API](https://fous.com/tools/accuweather.md): AccuWeather provides current conditions and RealFeel, plus up to 15 available daily forecasts; shorter public forecasts may return fewer days.
- [MSN Weather API](https://fous.com/tools/msn-weather.md): MSN Weather provides current conditions and forecasts for places worldwide, including up to 10 days ahead and optional hourly forecasts for the next 24 hours.
- [National Weather Service API](https://fous.com/tools/national-weather-service.md): National Weather Service provides U.S. day-and-night forecasts for seven days, hourly forecasts for up to 156 hours where available, active alerts, and latest nearby station observations.
- [Pollen.com API](https://fous.com/tools/pollen-com.md): Pollen levels and allergy forecasts for locations in the United States.
- [The Weather Channel API](https://fous.com/tools/the-weather-channel.md): The Weather Channel returns current conditions, today’s high/low, up to 15 daily forecasts (sometimes fewer), 1–48 local hourly forecasts, and active severe weather alerts.
- [NOAA Space Weather API](https://fous.com/tools/noaa-space-weather.md): NOAA Space Weather provides near-term aurora chances, current geomagnetic activity, a three-day Kp outlook, and NOAA alerts from the past 1–7 days.
- [Weather Underground API](https://fous.com/tools/weather-underground.md): Historical and current weather conditions from stations worldwide.
- [All Weather tools](https://fous.com/tools/category/weather)
