Skip to content

Slack

A workspace can post its events to a Slack channel: a line when an app is deployed, an app is shared, a member is added, a bypass token is created or someone asks for access to an app, and once an hour the visits we refused, by app. It’s on every plan. Each line links to the workspace’s activity in the dashboard.

Only a workspace’s owners and admins can connect Slack. It counts towards the workspace’s 10 webhooks and Slack channels.

  1. In Slack, create an incoming webhook for the channel: open Apps, find Incoming Webhooks, choose the channel and copy the webhook URL. It looks like https://hooks.slack.com/services/T…/B…/….

  2. In the dashboard, open the workspace’s Webhooks page and select Add Slack channel. Paste the URL and keep the events, or choose others. Every workspace event can go to Slack.

  3. Select Send test event. A test line should appear in the channel.

From the CLI, paste the URL when it asks, or pipe it in so it never sits in your shell history:

Terminal window
jiayang webhook add acme --slack
pbpaste | jiayang webhook add acme --slack

Every owner of the workspace gets an email when a channel is added. Add --name "#deploys" to name it, so you can tell it from other channels. We take only a Slack incoming webhook URL here, and not the example one, https://hooks.slack.com/services/T000/B000/XXXX. Anyone who has that URL can post to the channel, so we keep it encrypted and show only its start afterwards. To change the channel, remove it and add the new URL.

Unless you choose otherwise, the channel gets:

Event The line says
app.deploy Who deployed which app, and the version
grant.put Who shared which app with whom, and as what
member.put Who added whom to the workspace, and as what
token.create Who created a bypass token, and for which app
access.refused_digest How many visits were refused in the last hour, by app
access_request.create Who asked for access to which app. What they wrote isn’t sent

Names, addresses and app names are shown as code, so nothing in one can mention a channel or make a link.

Retries work as they do for any workspace webhook: a failed post is tried again for a day, and then the channel is turned off and the workspace’s owners get an email.

A test that Slack answers with a 404 means Slack doesn’t know the webhook or its channel: it was removed in Slack, or the URL has a typo. A 410 means the channel is archived. Either way, make a new incoming webhook and add it again.