Hi Brian,
After I removed the 3 fields in the sample alert, it worked. The alert was able 
to be sent to MSTeams. But just modifying the alert is not a solution as all 
the alerts generated from the AlertManager still contains these 3 fields. What 
shall I modify in alert manager.yaml config? Or is there a way to remove these 
3 field from all alerts?

 "groupLabels":"",
   "commonLabels":"",
   "commonAnnotations":"",







> On Jun 3, 2020, at 3:00 AM, Brian Candler <[email protected]> wrote:
> 
> > json: cannot unmarshal string into Go struct field Message.commonLabels of 
> > type template.KV
> 
> means: "I tried to unpack a template.KV object, but you gave me a string 
> instead".  First try:
> 
> "groupLabels": {},
> "commonLabels": {},
> "commonAnnotations": {},
> 
> and if that works, you can change it to
> 
> "groupLabels": {
>   "alertname":"KubeControllerManagerDown",
>   .. etc
> },
> 
> This is like the example shown at 
> https://github.com/prometheus-msteams/prometheus-msteams#simulating-a-prometheus-alerts-to-teams-channel
>  
> <https://github.com/prometheus-msteams/prometheus-msteams#simulating-a-prometheus-alerts-to-teams-channel>
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Prometheus Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] 
> <mailto:[email protected]>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/prometheus-users/50c98d18-fd13-4580-91df-55b2ff235970%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/prometheus-users/50c98d18-fd13-4580-91df-55b2ff235970%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/84D1A674-ECCD-401E-8D37-7AB09DC3643D%40gmail.com.

Reply via email to