Skip to content

Message templates

The Message field of a rule, and the Subject and Message body fields of email destinations, can include text and templates. Before Zenoss Cloud sends a message, it replaces templates with values from the context of the rule that initiates an action.

A template must be delimited by three left curly bracket and three right curly bracket characters. For example, {{{event.id}}}.

Event templates

{{{event.acknowledged}}}
Whether the event has been acknowledged (true) or has not been acknowledged (false).
{{{event.body}}}
The text of the event.
{{{event.id}}}
The event identifier.
{{{event.name}}}
The event name.
{{{event.severity}}}

The event severity, one of the following values:

SEVERITY_DEFAULT Unknown at this time
SEVERITY_DEBUG By default, not severe enough to display in an events console
SEVERITY_INFO Most likely, no action is required
SEVERITY_WARNING Action may be required in the future
SEVERITY_ERROR Entity is degraded but not down
SEVERITY_WARNING Entity is down

{{{event.status}}}

The event status, one of the following values:

STATUS_DEFAULT Unknown at this time
STATUS_OPEN Known to be in progress at this time
STATUS_SUPPRESSED Should be ended
STATUS_CLOSED Known to be ended

{{{event.summary}}}
A brief description of the event.
{{{event.tenant}}}
The name of your Zenoss Cloud organization.
{{{event.timestamp}}}
The date and time of the event, specified as milliseconds since the epoch (January 1, 1970 at 00:00:00 UTC).
{{{event.type}}}
A label that classifies the event.

Destination templates

All destinations

{{{destination.name}}}
The destination name.
{{{destination.description}}}
Text describing the destination.
{{{destination.type}}}
The destination type (email, slack or webhook).
{{{destination.rule_names}}}
The list of rules that use the destination.
{{{destination.tags}}}
The tags associated with the destination.
{{{destination.recent_notification_count}}}
The total number of notifications sent in the last 24 hours that used the destination.

Email destinations

{{{destination.to}}}
The email address specified for the destination.
{{{destination.subject}}}
The subject line of the email message.
{{{destination.body}}}
The body of the email message.

Slack destinations

{{{destination.channel}}}
The name of the public channel in your Slack workspace.
{{{destination.token}}}
A bot token provided by the Zenoss Slack app.
{{{destination.color}}}

The color to use in notifications sent to the channel.

The color is applied to a vertical bar accompanying the message block. Standard HTML color codes are supported.

Webhook destinations

{{{destination.url}}}
The URL of a webhook receiver.

Trigger templates

{{{trigger.description}}}
Text describing the trigger.
{{{trigger.name}}}
The trigger name.
{{{trigger.query}}}
The query specified in the trigger.
{{{trigger.recent_notification_count}}}
The total number of notifications sent in the last 24 hours that used the trigger.
{{{trigger.rule_names}}}
The list of rules that use the destination.
{{{trigger.tags}}}
The tags associated with the destination.
{{{trigger.type}}}
The trigger type.

Rule templates

{{{rule.description}}}
Text describing the rule.
{{{rule.destination_names}}}
The list of destinations associated with the rule.
{{{rule.enabled}}}
Whether the rule is enabled (true) or disabled (false).
{{{rule.message}}}
The text of the rule's message.
{{{rule.name}}}
The rule name.
{{{rule.recent_notification_count}}}
The total number of notifications sent in the last 24 hours that used the rule.
{{{rule.repeat}}}
Whether the rule is repeated for each matching trigger (true) or not repeated (false).
{{{rule.repeat_interval}}}
The amount of time to wait to repeat the action (send notifications), in seconds.
{{{rule.send_updates}}}
Whether to perform the action (send notifications) if the same trigger condition occurs, but has been updated in a significant way (true) or not perform the action (false).
{{{rule.tags}}}
The list of tags associated with the rule.
{{{rule.trigger_names}}}
The list of triggers associated with the rule.