Closed mirodietiker closed 8 years ago
I can help out, but I dont think I be including channels in Courier core that Drupal core doesnt natively support.
From what I understand Mattermost is Slack API-compatible?
https://github.com/maknz/slack would reduce the complexity of the integration
Yeah it is Slack compatible.
But just posting to the API is so much simple... It feels kinda overkill to use a library for that. I guess the access key settings form is the most complex part. ;-)
I think if I were doing the integration, I would also create a new identity type, where each identity mapped to one of the Slack/MM channels. That way you would target the sendMessage identity at the Slack channel, as you wouldnt target a Drupal user (?).
Yeah, ability to target a channel would make sense. Or also a private conversation. But again since the recipient is a different identity, you tell me i need to write code to trigger that message?
We need to be able to add a second message instance to an existing code trigger with a recipient override to give the UI sense and flexibility.
You don't need a different template template collection.
If you are looking at the code from dpi/tmgmt#1. You would add the entity mapping to the Slack channel to the $users
array in Notification service.
I whipped up something over lunch:
I've put it up here: https://github.com/dpi/courier_slack
The code is very rough, only a couple of hours worth of work. I used the composer dependency to get on my feet faster.
If you're wish to improve the module I can add a co-maintainer. Since I do not have much free time for the near future.
Continue discussions at https://github.com/dpi/courier_slack
Thank you, this is awesome. :-)
We are using Mattermost and i would love to see some events / notifications propagated to our mattermost channel.
Sure, i guess, can be a separate module, say courier_mattermost. It's a trivial REST POST resource with a key and a body. We can make the key globally configurable for now.
The difference here is that it's a channel and not a message to an individual. So it is not a full replacement for the direct message to the individual and more an additional notification.
With our proposed in TMGMT courier integration we would expect to simply add a new template collection to the same trigger.