Sending alerts to Zoom via webhook from Alertmanager

Hello everybody!
I ran into a problem when connecting sending alerts via Alert manager to webhook zoom.
Token and endpoint url received in the chat. The Curl request goes fine.
There was a problem when adding Alert manager to the configuration.
Part of the configuration is given below.

- name: "zoom"
  webhook_configs:
  - url: 'url'
    send_resolved: true
    http_config:
      authorization:
         credentials: 'token'

amtool check-config passes without errors. An error is generated when connecting to Alert manager.

msg="Notify for alerts failed" num_alerts=2 err="zoom/webhook[0]: notify retry canceled due to unrecoverable error after 1 attempts: unexpected status code 400: url: Invalid request body format."

Can you tell me what this could be related to? Maybe I need to specify a special type in authorization?

Also, please tell me how I can add an incoming webhook (a bot that sends notifications) to the channel.

Hi @ivan.vinogradov
Thanks for reaching out to the Zoom Developer Forum and welcome to our community! I am happy to help here!
Have you been able to troubleshoot this on your end or are you still looking for assistance on this?

No, we haven’t fixed it yet. I still need help.

Could you please share with me the documentation for Alert manager please?
@ivan.vinogradov

In fact, I’ve already figured it out. The problem is in the Alert manager, which substitutes Bearer in the header when sending, because of its format changes.
That is, you need to send the header -H ‘Authorization: TOKEN’, and instead Alert manager substitutes Bearer by default, which results in -H ‘Authorization: Bearer TOKEN’. I tried to remove the authorization type, but without success. In Grafana, when setting up sending notifications using the web interface, the error is similar.
In this regard, it is necessary to install a proxy server that will change the header before sending it to zoom.

You can define type authorization to “”:


receivers:
  - name: "zoom"
    webhook_configs:
    - url: "url"
      send_resolved: true
      http_config:
        authorization:
          type: ""
          credentials: "asdas123123"

It should be enough to fix it.

Ref.: Configuration | Prometheus