statistics_get_statistics
Need to analyze sensor readings over time? Retrieve aggregated statistics such as sum, mean, min, max for any Home Assistant entity within a specified date range.
Instructions
Get aggregated statistics for one or more entities over a time range.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| statistic_ids | Yes | list of entity IDs or statistic IDs, e.g. ["sensor.energy_consumption"] | |
| start | Yes | start date/time, e.g. "2024-01-01" or "2024-01-01T00:00:00" | |
| end | No | end date/time (defaults to now) | |
| period | No | aggregation period — "hour", "day", "week", "month", "5minute" | day |
| types | No | which aggregates to return — any of ["sum", "mean", "min", "max", "state", "change"] defaults to ["sum", "mean", "min", "max"] |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||