Slack
GitNotify in Slack creates private channels for your repositories, posts live cards into them as Block Kit messages with a colour bar, and answers one slash command, /gitnotify. It has no scope that reads messages.
Set up a workspace
Section titled “Set up a workspace”You need to be a workspace admin or owner, or the person who installs GitNotify, and an admin of the GitHub repositories you want to follow. Install the GitHub App on the account that owns them first, or from the repository picker in step 2.
-
Install GitNotify. Open Add to Slack and choose a workspace. GitNotify installs into one workspace at a time. Enterprise Grid organisation-wide installs are not supported.
-
Connect repositories. Run
/gitnotify connect. GitNotify replies privately with a one-time link. It works once, lasts 10 minutes and is bound to the workspace, to you and to your browser. Sign in to GitHub. Only repositories you administer and where the GitHub App is installed are offered. -
Build the channels. Run
/gitnotify setup. GitNotify creates two private channels for every connected repository not set up yet, and invites you:#gn-<repo>-activityfor pull requests#gn-<repo>-deploysfor CI and deploys
Channel names use the repository name without its owner. If a name is taken, GitNotify tries a number, such as
#gn-web-2-activity, up to five attempts. It never takes over an existing channel. A workspace can follow at most 50 repositories. -
Invite your team to those channels from Slack. There are no Slack categories or role-based access settings: channel membership is the access control.
-
Have your team link themselves. Each member runs
/gitnotify link, then/gitnotify notify mention,dmoroff. See Notifications and linking. -
Optionally, turn on digests with
/gitnotify digest. See Digests and email.
Commands
Section titled “Commands”Slack has one command, /gitnotify, with subcommands. Replies are private to the person who ran them. In this table, admin means a workspace admin or owner, or the person who installed GitNotify.
| Command | Who | Does |
|---|---|---|
/gitnotify help |
anyone | lists the commands and what GitNotify does. /gitnotify alone also shows help |
/gitnotify status |
admin | routed repositories, paused routes or channels needing repair, connected repositories awaiting setup, how many people are linked, and digest and email status |
/gitnotify connect |
admin, who must also be a GitHub repository admin | a one-time GitHub sign-in link to choose repositories for this workspace |
/gitnotify setup |
admin | builds private activity and deploys channels for every connected repository not set up yet |
/gitnotify repair |
admin | replaces missing, archived, inaccessible or public repository channels with new private ones, and invites the admin. See Repair |
/gitnotify link |
anyone | proves your GitHub id and login in this workspace. It reads only /user and revokes the GitHub token straight away. A newer link replaces an older one for that GitHub account here |
/gitnotify notify mention|dm|off |
anyone linked | chooses review and incident notifications in this workspace. Cards keep updating when notifications are off |
/gitnotify digest team <zone> [times] |
admin | makes or reuses GitNotify's own private #gn-digest, invites the admin and schedules the team digest. There is no channel option |
/gitnotify digest me <zone> [times] [email|dm] |
anyone linked | schedules your digest by DM (the default) or email. Built-in email sends a test before saving. Relay email needs a tested relay |
/gitnotify digest email [address] |
admin | with no address, gives a one-time secret for the workspace's own email relay. Run it again with the relay's HTTPS address to test it. Built-in email needs no relay |
/gitnotify digest off me|team|email |
anyone for me, admin for team or email |
stops your digest, the team digest or the workspace's relay. Turning relay email off moves personal email digests to DM |
/gitnotify digest preview |
anyone linked, or admin | privately previews your work if you are linked, otherwise the team's |
/gitnotify forget-me |
anyone | asks first, then removes your link, notification records and personal digest in this workspace |
connect, setup, link, digest team and digest email are rate-limited per workspace and person, five a minute.
Slack has no people or access subcommand. Use status for the linked-person count, and Slack itself to invite channel members.
Times are local times on a 24-hour clock, up to four, after an IANA time zone, for example /gitnotify digest team UTC 09:00 21:00 or /gitnotify digest me UTC 09:00 email.
Repair
Section titled “Repair”When a repository's channel is deleted, archived or no longer reachable, GitNotify pauses that route instead of retrying, and /gitnotify status shows it as needing repair. /gitnotify repair replaces each broken channel with a new private one and invites the admin who ran it. Invite your team to the new channel.
A channel that someone made public is left alone and receives no more cards. Repair makes a new private channel in its place. It never makes a channel public.
Repair does not cover the digest channel. If #gn-digest is deleted or made public, run /gitnotify digest team <zone> [times] again.
What the app can see and do
Section titled “What the app can see and do”The app has a bot token and six bot scopes. It has no user token and no scope that reads messages:
| Scope | Why it is needed |
|---|---|
chat:write |
posts and edits cards, notifications and digests |
commands |
handles /gitnotify |
im:write |
opens DMs for linked people who choose DM notifications or personal digests |
groups:read |
checks the private channels GitNotify is in, including whether they are still private during repair or digest setup. It does not grant message history |
groups:write |
creates private channels, invites the admin and sets their purpose |
users:read |
checks whether someone is a workspace admin or owner before management commands |
Other guarantees:
- Its only events are
app_uninstalledandtokens_revoked. There are no message subscriptions. - Every command, button press and event is checked against Slack's signature (
X-Slack-Signature, HMAC-SHA256 over the raw body) before it is parsed, and one more than 5 minutes old is refused. - Text from GitHub is escaped, automatic mention and link parsing is off, and mentions are built only from the Slack ids of linked people.
- The bot token is encrypted at rest. Token rotation is off.
- Each workspace has its own delivery queue, which folds bursts into one edit and waits out Slack's rate limits without holding up other workspaces.
See What GitNotify reads and Security model.
Removing GitNotify
Section titled “Removing GitNotify”When you uninstall the app or revoke its token, Slack tells GitNotify. The bot token is wiped at once and the workspace's routes stop. After 30 days the workspace's data is deleted. The messages already posted stay in your channels. See Data and retention.