Connecting Slack

edit

Connecting Slack

edit

Slack is the new digital office space. Teams of all shapes and sizes use Slack to stay in touch. People share videos, pictures, GIFs and lots of emojis.

You can now connect Slack to Workplace Search, and search through all your public channels, private channels, and direct messages.

Remote sources like Slack are private sources. Once you have configured the connector, each individual member must add it as a unique private source via their personal settings. The connecting person can access their own private channels and direct messages, and only they have access. Each member may connect only one Slack private content source.

The Slack connector searches the following data from Slack:

Fetched Slack Documents

Including ID, File Metadata, Excerpt, Attachments, Sender, Recipient and Timestamps

The connector will also index the following data from Slack for speedier retrieval:

Stored Slack Documents

Users, Channels, Emojis

Configuring the Slack Connector

edit

Configuring the Slack connector is the first step prior to connecting the Slack service to Workplace Search, and requires that you create an OAuth App from the Slack platform.


Step 1. Login to the Slack Apps Portal.

Make sure that you create the app through a trusted and stable Slack account. We recommend using a team-owned account.


Step 2. Create an app, and then configure appropriate access levels. Click Create New App when prompted. In the modal, provide a name — like Workplace Search — and choose the right Workspace. After that, click Create App.

Figure 88. Connecting Slack

Step 3. A set of choices appears. Under Add features and functionality, click Permissions.

Figure 89. Connecting Slack

Step 4. Provide a redirect URL. You will need to ensure the URL is relative to your deployment. If you were setting it up on your local machine, you would use: http://localhost:3002/ws/sources/slack/create. After you have added it, click Save URLs.

Figure 90. Connecting Slack

Examples:

# Deployment using a custom domain name
https://www.example.com/ws/sources/slack/create

# Deployment using a default Elastic Cloud domain name
https://c3397e558e404195a982cb68e84fbb42.ent-search.us-east-1.aws.found.io/ws/sources/slack/create

# Unsecured local development environment
http://localhost:3002/ws/sources/slack/create

Step 5. Next, we must define scope. You will need to add five under User Token Scopes.

  • channels:read
  • users:read
  • emoji:read
  • files:read
  • search:read
Figure 91. Connecting Slack

Step 5. Next, on the left-hand side of the application menu, click Basic Information. Under the section Install your app to your workspace, select Install or Request to Install your application. Which you will see depends on your permissions. An admin must approve the application if you lack the permissions to do so.

Figure 92. Connecting Slack

Step 6. Once approved, you will have the option to view your App Credentials. Retrieve your Client ID and Client Secret. Workplace Search will need them!

Figure 93. Connecting Slack

Step 7. Return to Workplace Search. From the Workplace Search administrative dashboard, click Sources, locate Slack, click Configure and provide both your Client ID and Client Secret. Proceed forward.

Voilà! The Slack connector is now configured, and ready to be used to synchronize content. To enable Slack, visit the Security menu and enable the Slack connector for your team.

Reminder: Slack must be added as a private content source.

Connecting Slack to Workplace Search

edit

Once the Slack connector has been configured, you may connect a Slack instance to your private search experience.


Step 1. Access your own Workplace Search search dashboard, and click the Manage button.

Figure 94. Connecting Slack

Step 2. Click Add a private content source.

Figure 95. Connecting Slack

Step 3. Click Connect Slack. You will see Slack’s OAuth screen.

Accept the permissions to connect your Slack account.

Figure 96. Connecting Slack

Step 4. Success! Your personal Slack is now available to your search experience.

Figure 97. Connecting Slack

You will have the freshest content available each time you query.