Messaging outputs: Slack message processor

message_slack
Maintained by Picture of Mike Churchward Mike Churchward
This plugin provides a Moodle message output for Slack. Sites can select a Slack team, and users can connect their Moodle notifications to their Slack account for that team.
2 sites
16 downloads
Build passing

This plugin experiments with providing a Moodle message provider plugin for Slack.


It requires a Slack App be set up in the team, using https://api.slack.com/apps. Once created, the basic information screen for that
App will show the Client ID and the Client Secret required for the Moodle plugin configuration.

This is setup so that "only one" Slack Team can be set up at the site level. Anyone wishing to have a Slack notification setup
for their Moodle account must be a member of that team and use their account for that team.

The user connection is done via the Slack button, which uses the OAuth 2.0 protocol in Slack (https://api.slack.com/docs/oauth).
The team will require an App setup in order to get the client id and secret that is required for the OAuth protocol and to attach
incoming webhooks to for each user account. Team apps can be set up here - https://api.slack.com/apps.

If the user logs into a different team Slack when trying to connect Moodle, they will receive the error:
"OAuth Error: invalid_team_for_non_distributed_app".
If the user is already logged into a different team Slack when trying to connect Moodle, they will receive the team login screen
for Slack until they do login to the correct Slack.
I am trying to determine if there is a way to "force" the login to the correct team.

-----
*** This is an BETA release, and is not intended to be used in any production environment ***

If you wish to contribute in any way, message me on github or to mike.churchward@poetgroup.org.

-----
Future thoughts:
- It may be possible to allow users to pick their own teams, but it would involve the same complex setup for each user as it is
for the site setup.
- It would be great if the current configuration forced the team set at the site level so that the user account connection is
simplified.
- It would also be great if the connection to Slack could use the Slack user's user name to set the channel rather than force the
user to pick one.

Screenshots

Screenshot #0
Screenshot #1

Contributors

Picture of Mike Churchward
Mike Churchward (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Show comments
Please login to post comments