Open LukeFlynn opened 8 years ago
I was able to get this working with Mattermost. See #7 for more details on how to configure the slack plugin.
for me it only it worked only after adding the content type to the post request.
req = Net::HTTP::Post.new("#{uri.path}?#{uri.query}", 'Content-Type' => 'application/json')
I should check if this works with slack as well, it might make sense to add it even for the non mattermost users?
This plugin seems to be correctly sending the content-type since this commit in december 2015:
https://github.com/sensu-plugins/sensu-plugins-slack/blame/master/bin/handler-slack.rb#L152
I can also confirm this plugin works well with Mattermost, here's an example config:
{
"slack": {
"webhook_url": "https://mattermost.example.com/hooks/xxxxx-xxxxx-xxxxx-xxxxx",
"dashboard": "https://uchiwa.example.com/#/client/my-datacenter/",
"channel": "my-channel-name",
"bot_name": "sensu",
"icon_url": "https://raw.githubusercontent.com/sensu/sensu-logo/master/sensu1_flat%20white%20bg_png.png",
"message_prefix": "@user-x, @user-y "
}
}
Note that you'll need #71 in order for the notifications based on the message_prefix
to work though.
Hello!
My team recently migrated from Slack to Mattermost. Mattermost has support for quite a few Slack webhooks already, this one doesn't seem to work though. Is there anyways support could be implemented.. or a way I could hack this together to work?
I understand if this is not possible, being that your primary focus is obviously Slack. If there's nothing you guys can do about, is it possible to make a suggestion for a new plugin that does this?
Thanks.