Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

slack: allow saving user group ID to schedule notification rules #2882

Merged
merged 9 commits into from
Mar 22, 2023

Conversation

mastercactapus
Copy link
Member

Description:
This PR adds the slack-ug feature flag, starting support for Slack user group updates for schedule changes.

Which issue(s) this PR fixes:
Part of #1228

Out of Scope:

  • non-functional (this PR is data only)
  • UI bits are not yet available
  • API for listing groups is not available

Describe any introduced API changes:

  • new slack-ug experimental flag
  • new slackUserGroup target/notification channel type

Additional Info:
Start with make start EXPERIMENTAL=slack-ug

  • you must have a slack workspace with user groups enabled (paid only feature)

Testing can be done with the following mutation:

mutation ($input: SetScheduleOnCallNotificationRulesInput!) {
  setScheduleOnCallNotificationRules(input: $input)
}

And variables:

{
  "input": {
    "scheduleID": "<schedule id goes here>",
    "rules": [
      {
        "target": {
          "type": "slackUserGroup",
          "id": "<user group ID goes here>:<fallback channel id goes here>"
        }
      }
    ]
  }
}

You can get user group IDs from this page; you will need your bot token, with the usergroups.list scope:
https://api.slack.com/methods/usergroups.list/test

Channel IDs can be found in the slack app by opening the channel info and going to the bottom.

@mastercactapus mastercactapus merged commit 1827651 into master Mar 22, 2023
@mastercactapus mastercactapus deleted the slack-user-groups branch March 22, 2023 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants