Skip to content

Mattemost posts API reference isn't available to use. #840

Open
@agepalmist

Description

Problematic:
Currently, there is a chance to use Slack provider to inject Flux alerts to a Mattermost channel via a webhook.
But if I want to use Mattermost API to send notifications with a Mattermost bot, like
https://my_mattermost_uri/api/v4/posts it's impossible to do because of a small difference in request bodies Slack and Mattermost.
Slack has the channel field to refer a message to a channel (https://api.slack.com/methods/chat.postMessage)
and Mattermost has the channel_id field for this (https://api.mattermost.com/#tag/posts).

That would be useful to add channel_id to Flux Provide to handle Mattermost posts API reference also.

apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
  name: mattermost
  namespace: default
spec:
  type: slack
  #channel: general
  #address: https://slack.com/api/chat.postMessage
  channel_id: xxxxxxxxxxxxxxxxxxxxxxxxxx
  address: https://my_mattermost_uri/api/v4/posts
  secretRef:
    name: mattermost-token

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions