Looker 6.24 introduces a new Slack integration action where you can send or schedule data deliveries to Slack, including direct messages and messages to public or private channels. The existing Slack integration, Slack Attachment (API Token), is still available.
The new Slack integration is a Looker Labs feature and is available to Looker-hosted deployments that satisfy these conditions:
- The Looker instance is on 6.24 or later.
- The Looker instance is not IP whitelisted.
This Slack integration is not supported for customer-hosted instances.
Enabling the Slack (Beta) Action
Before you can enable the Slack (Beta) action, your Looker admin must perform these steps:
- Go to Admin > Labs and enable the Slack App Labs feature.
- Go to Admin > Actions to enable the Slack (Beta) action in the Looker Action Hub and connect it to the Slack workspace.
Once your Looker admin has enabled the feature and connected it to your workspace, perform these steps:
In Looker 6.24 and 7.0, you cannot change your Slack workspace connection!
- From the Actions page, scroll down to the Slack (Beta) action, and click the Enable switch.
- On the Slack (Beta) page, click Connect. Looker will request access to the Slack workspace indicated in the drop-down menu on the top right of the page.
- Click Allow, and return to the Slack (Beta) page.
- Click the Enable switch, and then click Save. Your connection should be indicated by the Test Action field. You can click Test Again to test your Looker connection to your Slack workspace.
Starting in Looker 7.2, you can disconnect an existing Slack workspace connection by clicking the Disconnect button on the Slack (Beta) page and then clicking OK on the pop-up warning message. You will not need to click Save on the Slack (Beta) page to save these settings, and the action will still show as Enabled even though no Slack workspace is connected.
Authenticating into Your Slack Workspace
You must authenticate into the same Slack workspace that your Looker admin has connected to Looker.
There are two options for authenticating into your Slack workspace for the first time:
- From the Account page
- From the Send or Schedule window
Authenticating into Your Slack Workspace from the Account Page
- In Looker, click your user profile icon in the upper right of the screen, and select Account.
- Under Integrations, click Sign in with Slack.
- Looker will request access to the Slack workspace. Click Allow.
- You're authenticated and can now start to send or schedule dashboards, Looks, and Explores.
Be careful not to revoke your Slack token — if you do, any schedules you've created will fail.
Authenticating into Your Slack Workspace from the Send or Schedule Window
See the next section for more information on delivering data to the Slack action.
- In Looker, navigate to the content that you'd like to deliver, click the gear menu, and then click Send or Schedule.
- In the Send or Schedule window, select the Slack (Beta) action as the delivery destination under Where should this data go?
- Next to Slack, click Log in.
- Looker will request access to the Slack workspace. Click Allow.
- The Send or Schedule window should now show your Slack delivery options.
Delivering Data to Slack (Beta)
Before you can deliver data to the new Slack (Beta) action, Looker admins need to follow the steps above to enable the Slack App Labs feature and enable the Slack (Beta) action in the Looker Action Hub. You must also authenticate into the same Slack workspace that your admin has connected to Looker.
To deliver a user-defined dashboard, a LookML dashboard, a Look, or an Explore, first navigate to your content and then perform these steps:
- Click the gear menu, and click Send or Schedule, depending on what is available for your content.
- In the Send or Schedule window, select the Slack (Beta) action as the delivery destination under Where should this data go? If this is your first time using the Slack (Beta) action, you will need to authenticate into Slack (see the previous section about authenticating into your Slack workspace).
- Once you authenticate into Slack, Looker will display delivery options that are specific to Slack (Beta).
- In the Share In field, enter the name of the Slack channel where you want to post your data. You can send direct messages or messages to public or private channels. Include the leading # character, for example, #Sales.
- In the Comment field, enter any text you want to include with the delivery.
- In the Filename field, enter the name you want to give to the attachment file.
- If you are scheduling a data delivery, once you have configured all the options, click Save All. Your query or dashboard will be delivered to Slack as scheduled. Or, if you are sending your data, click Send. Your data will be delivered to your Slack channel.
Sharing Links to Looker Content in Slack
You can share links to user-defined dashboards, LookML dashboards, Looks (but not public embedded Looks), or Explores in Slack.
The link unfurls in Slack to show the content's title and some of its metadata, which will be visible only to those who have access to the underlying content. Once the link unfurls, you or other users have options to post a link back to the content in Looker and a snapshot of the content in the channel (by clicking Post to this Channel) and to add the content to their Looker Favorites folder (by clicking Add to Favorites). Once the content is posted to the channel, anyone in the channel will be able to view the content snapshot and title, even if they do not have access to the underlying content in Looker.
Once you've added content to your Favorites folder, the Looker Slack app will display a message in Slack with a link to access your Favorites folder in Looker.
Using Slash Commands to Retrieve Looker Information in Slack
If you also have Lookerbot enabled, you may need to rename some slash commands. Custom Slack commands cannot be configured with the Slack (Beta) integration. Use Lookerbot for custom commands.
You can use the following slash commands to retrieve information from Looker and post it to Slack:
/looker whoami— The Looker Slack app greets you by name; tells you the Looker instance to which you're connected; and provides links to your Looker Favorites folder, to your personal folder, and to Help.
/looker help— The Looker Slack app lists supported slash commands.
/looker favorites— The Looker Slack app lists the content from your Looker Favorites folder. Click the ellipsis (
...) beside each piece of content to access a menu from which you can Post to this Channel or Remove from Favorites.
/looker folder— The Looker Slack app lists the content from your Looker personal folder. Click the ellipsis (
...) beside each piece of content to access a menu from which you can Post to this Channel or Remove from Favorites (if the content is also in your Favorites folder).