docs icon indicating copy to clipboard operation
docs copied to clipboard

Doc how to push integration info into channels for larger deployments, many developers

Open it33 opened this issue 8 years ago • 2 comments
trafficstars

Met with customer trying to get dozens of groups pushing notifications into Mattermost and we need to better document how to do this:

  1. Single webhook - shared by developers that can post to channels by overriding the channel_id. Webhook URLs are secured behind firewall with GUID tokens and anyone who knows how to call them can post. Different webhooks for different groups of developers. Link to where they can find open source examples, like Jira webhook integrations: https://about.mattermost.com/community-applications/. Also note that webhooks can be created via APIs: https://api.mattermost.com/
  2. Posting notifications via APIs - Much more powerful, but takes more time to set up. Can authencation using session token or OAuth (question: Do we need something in advanced permissions specification about a special account that can post webhooks across the system, but not do anything else System Admin level?).
  3. Managing permissions across many developers creating integrations - Discuss how to use APIs to build a user interface enabling you to query different channels (among possibility thousands in an enterprise deployment) to use in setting up an integration

it33 avatar Feb 23 '17 16:02 it33

Some additional info from @jwilander

Here is our integration guide https://docs.mattermost.com/guides/integration.html which should contain the majority of the information you'll need.

Specific documention on incoming webhooks can be found here https://docs.mattermost.com/developer/webhooks-incoming.html

APIs you'll likely need for automatic webhook creation and building a GUI to make it an easy set-up process:
- Create an incoming webhook: https://api.mattermost.com/#tag/incoming-webhooks%2Fpaths%2F~1teams~1%7Bteam_id%7D~1hooks~1incoming~1create%2Fpost
- Get teams: https://api.mattermost.com/#tag/teams%2Fpaths%2F~1teams~1all%2Fget 
- Get channels for a user on a team: https://api.mattermost.com/#tag/channels%2Fpaths%2F~1teams~1%7Bteam_id%7D~1channels~1%2Fget

You mentioned using JavaScript, which we have an API driver for: https://github.com/mattermost/mattermost-driver-javascript

How to build OAuth2 integrations: https://docs.mattermost.com/developer/oauth-2-0-applications.html

Zapier with Mattermost: https://docs.mattermost.com/integrations/zapier.html

Metrics with Grafana & Prometheus: https://docs.mattermost.com/deployment/metrics.html

it33 avatar Feb 24 '17 05:02 it33

@aaronrothschild, is this something that you could take a look at?

justinegeffen avatar Jan 14 '22 14:01 justinegeffen