Push metrics to iPhone widget
push_metricsCreate or update a WidgetDash data source and set its title, icon, category, and full metrics list for iPhone widgets and Live Activities.
Instructions
Create or update a WidgetDash data source shown on the user's iPhone Home Screen / Lock Screen widgets and Live Activities. Sets the source's title, SF Symbol icon, category and its full list of metrics (label + value + type + color). The metrics list REPLACES the source's current metrics; use push_number to change a single value. Omitted display_name/icon/category/sort_order keep their current values. Requires WIDGETDASH_WRITE_KEY.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| icon | No | SF Symbol name shown next to the title, e.g. 'dollarsign.circle.fill', 'chart.bar.fill', 'server.rack', 'heart.fill', 'cart.fill'. If omitted, keeps the existing icon (default 'circle.fill'). | |
| metrics | Yes | Metrics to show, in display order. Small widgets show the first few, so put the most important first. | |
| category | No | Free-form grouping, e.g. 'finance', 'monitoring', 'fitness'. If omitted, keeps the existing category (default 'general'). | |
| raw_data | No | Optional arbitrary JSON object stored alongside the metrics (not shown on the widget). If omitted, existing raw_data is kept. | |
| sort_order | No | Position among sources on the widget (lower first). If omitted, keeps the existing order (default 0). | |
| source_key | Yes | Stable identifier for this data source, e.g. 'stripe_mrr' or 'server_health'. Lowercase letters, digits, '_' or '-'. Pushing to an existing key updates it; a new key creates a new widget source. | |
| display_name | No | Title shown on the widget, e.g. 'Stripe'. If omitted, keeps the existing name (or derives one from source_key for new sources). |