Hi i have tried creating custom message templates for MS-Teams alerts, but it was not coming as per the requirement, can anyone suggest me with one message template
i was using this
{{ define "teams.title" -}}
{{ template "alert_severity_prefix_emoji" . }}
[{{- .Status | toUpper -}}{{- if eq .Status "firing" }} x {{ .Alerts.Firing | len -}}{{- end }} | {{ .CommonLabels.env | toUpper -}} ] || {{ .CommonLabels.alertname -}}
{{- end -}}
{{- define "teams.text" -}}
{{- range .Alerts -}}
{{ if gt (len .Annotations) 0 }}
*Summary*: {{ .Annotations.summary}}
*Description*: {{ .Annotations.description }}
Labels:
{{ range .Labels.SortedPairs }}{{ if or (eq .Name "env") (eq .Name "instance") }}• {{ .Name }}: `{{ .Value }}`
{{ end }}{{ end }}
{{ end }}
{{ end }}
{{ end }}
THANK YOU!!
~ the grafana team