I am trying to use {{ .StartsAt }} in template as below
But getting error as below while previewing.
Can someone please help here.
Thanks in advance.
I am trying to use {{ .StartsAt }} in template as below
But getting error as below while previewing.
Can someone please help here.
Thanks in advance.
@jangaraj can you please help here ?
The struct template.ExtendedData
does not have a field StartsAt. Check available fields here. You need to change the template to something like
{{ index .Alerts 0 }}
{{ .StartsAt }}
{{end}}
@yuriy.tseretyan
Thank you so much for your response.
In Grafana version 10.2.3
.StartsAt is working fine, but .EndsAt gives 0001-01-01 00:00:00 +0000 UTC when firing.
In Grafana version 8.5.15
I added template in message box. But Template is printed as plain text and variables are not resolved.