Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-18355

Slack integration fix

    XMLWordPrintable

Details

    • Problem report
    • Status: Closed
    • Blocker
    • Resolution: Duplicate
    • None
    • None
    • Templates (T)
    • Debian 10
    • Team INT
    • Sprint 68 (Sep 2020), Sprint 69 (Oct 2020), Sprint 70 (Nov 2020), Sprint 71 (Dec 2020), Sprint 72 (Jan 2021), Sprint 73 (Feb 2021), Sprint 74 (Mar 2021), Sprint 75 (Apr 2021)

    Description

      The Slack integration throws a "channel_not_found" error, because the token is missing from the JSON parameters.

       

      The "bot_token" variable should be sent in Headers AND in the payload (which is actually not the case).

       

      Source is: https://git.zabbix.com/projects/ZBX/repos/zabbix/browse/templates/media/slack/media_slack.xml

       

      handlerAlarm() and handlerEvent() functions should provide the token in the payload like this:

      var fields =

      {    channel: params.channel,    *token: params.bot_token,*    as_user: params.slack_as_user, }

      ;

       

      Slack docs: https://api.slack.com/methods/chat.postMessage

      Attachments

        Issue Links

          Activity

            People

              zabbix.dev Zabbix Development Team
              pierrebaz Pierre Bazoge
              Votes:
              3 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: