📑 I have found these related issues/pull requests
Custom notification message templates with variable substitution
🔖 Feature description
Add support for custom notification message templates using a {{variable}} syntax, allowing users to customize notification titles and messages with dynamic values from their monitors (e.g., {{name}}, {{status}}, {{hostname}}).
This would give users more control over notification content and make messages more compact and personalized. For example, instead of the default verbose messages, users could create concise templates like "{{statusEmoji}} {{name}}" for the title.
✔️ Solution
I've created a POC for the ntfy notification provider that includes:
- Custom title and message template fields at the notification level
- A collapsible UI section that expands when templates are configured
- Variable substitution that works with any monitor field
Screenshots showing the implementation:
- Collapsed by default when empty
- Expanded view with template fields
- Sample notifications with custom templates
I'd like guidance on extending this to:
- Make it available for other notification providers (Discord, Gotify, etc.)
- Add per-monitor template overrides (allowing each monitor to customize its messages beyond the notification-level templates)
❓ Alternatives
For per-monitor templates, I explored adding fields to the monitor table and handling them in core files, but I'm uncertain if this is the right approach. There might be a cleaner way to implement provider-specific per-monitor settings that I'm not aware of.
Another alternative would be to keep it notification-level only, but that seems limiting for users with diverse monitoring needs.
📝 Additional Context
The button collapsed by default when empty:
The button expanded when configured:
Sample notifications with custom templates:
I'm new to contributing to Uptime Kuma, so any direction on the best architectural approach would be appreciated. This feature was requested 3-4 years ago on Reddit, so there seems to be community interest.
https://www.reddit.com/r/UptimeKuma/comments/x2p7v1/compact_notification_messages_or_modify/
https://www.reddit.com/r/UptimeKuma/comments/r9oeq0/modify_email_template/
📑 I have found these related issues/pull requests
Custom notification message templates with variable substitution
🔖 Feature description
Add support for custom notification message templates using a {{variable}} syntax, allowing users to customize notification titles and messages with dynamic values from their monitors (e.g., {{name}}, {{status}}, {{hostname}}).
This would give users more control over notification content and make messages more compact and personalized. For example, instead of the default verbose messages, users could create concise templates like "{{statusEmoji}} {{name}}" for the title.
✔️ Solution
I've created a POC for the ntfy notification provider that includes:
Screenshots showing the implementation:
I'd like guidance on extending this to:
❓ Alternatives
For per-monitor templates, I explored adding fields to the monitor table and handling them in core files, but I'm uncertain if this is the right approach. There might be a cleaner way to implement provider-specific per-monitor settings that I'm not aware of.
Another alternative would be to keep it notification-level only, but that seems limiting for users with diverse monitoring needs.
📝 Additional Context
The button collapsed by default when empty:
The button expanded when configured:
Sample notifications with custom templates:
I'm new to contributing to Uptime Kuma, so any direction on the best architectural approach would be appreciated. This feature was requested 3-4 years ago on Reddit, so there seems to be community interest.
https://www.reddit.com/r/UptimeKuma/comments/x2p7v1/compact_notification_messages_or_modify/
https://www.reddit.com/r/UptimeKuma/comments/r9oeq0/modify_email_template/