Tagging each device with a location and a group means "how is the air in the living room" resolves across every sensor in that room, and a chart gets one series per device automatically — the part that usually takes a script. Note the two write tools at the end of the list: `restart_device` costs about 30 seconds of downtime and `shutdown_device` needs a manual restart, so they are worth being deliberate about.
A Python server for air-Q air quality devices, built on aioairq, the official async library. It talks to the devices on your local network rather than to a cloud service, and covers both reading — live values, history off the device's SD card, charts, exports — and configuration, including LED themes, brightness, night mode and network settings. The same executable also works as a plain CLI when you pass a tool name as a subcommand.
- Reading: `list_devices`, `get_air_quality`, `get_air_quality_history` as column-oriented JSON, `get_device_info`, `get_config`, `get_logs`
- Charts and exports: `plot_air_quality_history` renders one chart per sensor as `png`, `webp`, `svg` or interactive `html`; `export_air_quality_history` writes one `csv` or `xlsx` per request
- Multi-device queries: `get_air_quality` accepts exactly one of `device`, `location` or `group`, so "the living room" or "home" fans out across matching devices and charts get one series each
- Configuration: `set_device_name`, `set_led_theme`, `set_night_mode`, `set_brightness`, `configure_network` for static IP or DHCP
- LED state: `get_led_theme`, `get_possible_led_themes`, `get_night_mode`, `get_brightness_config`, and `identify_device` to make one blink
- Control: `restart_device` and `shutdown_device`
- History defaults you can override: 1 hour for raw history, 24 for plots, downsampled to at most 300 points, timestamps in UTC unless you name a timezone
One or more air-Q devices reachable on your network, and a JSON file listing them — address, password, and optionally name, location and group. Point the server at it with `AIRQ_CONFIG_FILE`, or pass the list inline through `AIRQ_DEVICES`. The file holds device passwords, so `chmod 600` it. Install from PyPI as `mcp-airq`, version 1.6.5, or run it with `uvx mcp-airq`; transport is stdio. If your client cannot find `uvx`, give it the absolute path — MCP subprocesses do not inherit your shell's PATH.
One command — pip install mcp-airq
