From 79dd8daee89643485a48bcc5bb310ed110c4e164 Mon Sep 17 00:00:00 2001 From: Home Assistant Version Control Date: Mon, 24 Aug 2026 17:27:08 +0000 Subject: [PATCH] .ha_mcp/logs/mcp_usage.jsonl, .storage/lovelace.printer_stats --- .ha_mcp/logs/mcp_usage.jsonl | 1 + .storage/lovelace.printer_stats | 72 +++++++++++++++++++++++++++++++++ 2 files changed, 73 insertions(+) diff --git a/.ha_mcp/logs/mcp_usage.jsonl b/.ha_mcp/logs/mcp_usage.jsonl index dcc326ed..159d2158 100644 --- a/.ha_mcp/logs/mcp_usage.jsonl +++ b/.ha_mcp/logs/mcp_usage.jsonl @@ -1910,3 +1910,4 @@ {"timestamp": "2026-08-24T17:25:54.232529+00:00", "tool_name": "ha_config_set_helper", "parameters": {"helper_type": "utility_meter", "name": "OctoPrint Filament Weight Monthly", "helper_id": null, "entry_id": null, "subentry_type": null, "subentry_id": null, "show_advanced_options": false, "icon": null, "area_id": null, "labels": null, "min_value": null, "max_value": null, "step": null, "unit_of_measurement": null, "options": null, "initial": null, "mode": null, "has_date": null, "has_time": null, "restore": null, "duration": null, "monday": null, "tuesday": null, "wednesday": null, "thursday": null, "friday": null, "saturday": null, "sunday": null, "latitude": null, "longitude": null, "radius": null, "passive": null, "user_id": null, "device_trackers": null, "picture": null, "tag_id": null, "description": null, "category": null, "config": {"source": "sensor.octoprint_filament_used_weight_total", "cycle": "monthly", "periodically_resetting": true, "always_available": false}, "wait": true, "action": null, "MandatoryBPS": false, "BestPracticeKey": null}, "execution_time_ms": 294.264554977417, "success": true, "error_message": null, "response_size_bytes": 396, "user_context": null} {"timestamp": "2026-08-24T17:26:25.738591+00:00", "tool_name": "ha_get_state", "parameters": {"entity_id": ["sensor.octoprint_filament_weight_daily", "sensor.octoprint_filament_weight_weekly", "sensor.octoprint_filament_weight_monthly"], "fields": ["state", "attributes"], "attribute_keys": ["unit_of_measurement", "source", "friendly_name"]}, "execution_time_ms": 10.35308837890625, "success": true, "error_message": null, "response_size_bytes": 794, "user_context": null} {"timestamp": "2026-08-24T17:26:26.126938+00:00", "tool_name": "ha_config_get_dashboard", "parameters": {"url_path": "printer-stats", "list_only": false, "force_reload": false, "entity_id": null, "card_type": null, "heading": null, "include_config": false, "include_screenshot": false, "view_path": "history", "mode": null, "query": null}, "execution_time_ms": 5.804300308227539, "success": true, "error_message": null, "response_size_bytes": 6349, "user_context": null} +{"timestamp": "2026-08-24T17:27:00.869813+00:00", "tool_name": "ha_config_set_dashboard", "parameters": {"url_path": "printer-stats", "config": null, "python_transform": "card = {'type': 'custom:apexcharts-card', 'header': {'show': True, 'title': 'Filament Usage - Grams (30 days)', 'show_states': True, 'colorize_states': True}, 'graph_span': '30d', 'apex_config': {'chart': {'type': 'bar', 'height': 300}, 'plotOptions': {'bar': {'columnWidth': '50%'}}, 'dataLabels': {'enabled': False}, 'yaxis': {'tickAmount': 4, 'labels': {'minWidth': 40}}}, 'series': [{'entity': 'sensor.octoprint_filament_weight_daily', 'name': 'Used (g)', 'color': '#26c6da', 'type': 'column', 'group_by': {'func': 'last', 'duration': '1d', 'start_with_last': True}}, {'entity': 'sensor.octoprint_filament_used_weight_total', 'name': 'Total (g)', 'color': '#ab47bc', 'type': 'line', 'curve': 'straight', 'group_by': {'func': 'last', 'duration': '1d', 'start_with_last': True}}, {'entity': 'sensor.octoprint_filament_weight_weekly', 'name': 'Weekly (g)', 'color': '#ffca28', 'type': 'column', 'group_by': {'func': 'last', 'duration': '1d', 'start_with_last': True}}], 'grid_options': {'columns': 'full'}, 'span': {'end': 'day'}}; config['views'][1]['sections'][3]['cards'].append(card)", "config_hash": "857460438a54ac57", "title": null, "icon": null, "require_admin": null, "show_in_sidebar": null, "MandatoryBPS": false, "BestPracticeKey": null, "return_screenshot": false, "view_path": null}, "execution_time_ms": 53.37238311767578, "success": true, "error_message": null, "response_size_bytes": 1673, "user_context": null} diff --git a/.storage/lovelace.printer_stats b/.storage/lovelace.printer_stats index d8663d05..75e9cbe6 100644 --- a/.storage/lovelace.printer_stats +++ b/.storage/lovelace.printer_stats @@ -845,6 +845,78 @@ "span": { "end": "day" } + }, + { + "type": "custom:apexcharts-card", + "header": { + "show": true, + "title": "Filament Usage - Grams (30 days)", + "show_states": true, + "colorize_states": true + }, + "graph_span": "30d", + "apex_config": { + "chart": { + "type": "bar", + "height": 300 + }, + "plotOptions": { + "bar": { + "columnWidth": "50%" + } + }, + "dataLabels": { + "enabled": false + }, + "yaxis": { + "tickAmount": 4, + "labels": { + "minWidth": 40 + } + } + }, + "series": [ + { + "entity": "sensor.octoprint_filament_weight_daily", + "name": "Used (g)", + "color": "#26c6da", + "type": "column", + "group_by": { + "func": "last", + "duration": "1d", + "start_with_last": true + } + }, + { + "entity": "sensor.octoprint_filament_used_weight_total", + "name": "Total (g)", + "color": "#ab47bc", + "type": "line", + "curve": "straight", + "group_by": { + "func": "last", + "duration": "1d", + "start_with_last": true + } + }, + { + "entity": "sensor.octoprint_filament_weight_weekly", + "name": "Weekly (g)", + "color": "#ffca28", + "type": "column", + "group_by": { + "func": "last", + "duration": "1d", + "start_with_last": true + } + } + ], + "grid_options": { + "columns": "full" + }, + "span": { + "end": "day" + } } ] },