Integrating Slack with Salesforce

Slack is one of the chat platforms which is used by many businesses and organizations across the world. People who use Slack can directly grab the information from Salesforce. The main advantage of integrating Salesforce and Slack is to search the Salesforce data (object & records) using the Slack commands. It can also be possible to directly share a Salesforce record in Slack to other people/groups within Slack. In this guide, we will see how to integrate Salesforce into Slack and get/share the Salesforce records in Slack with examples.

Salesforce Slack Integration

We need to install both Slack and Companion App. There are 10 steps to install and configure Salesforce to Slack. Let’s see how to install Slack:

1. Go to the link and click on “Sign In to install” slack.

2. Enter the email for Slack that is similar to a Salesforce user email.

3. Now, create Workspace in your Slack.

4. Enter the company name. Here, we use the “Linuxhint test”.

5. Specify your name. Here, we use the “Linuxhint_testuser”.

6. Let’s create a channel named “testing”.

7. Now, add Salesforce to Slack.

8. Allow the permission.

9. Finally, you are in Salesforce and Slack is integrated.

Next, we need to install the “companion app” from the AppExchange portal. It’s free.

10. Go to the AppExchange portal by navigating to the link

11. Type “companion app” in the search box and get it.

12. It will ask to login to our Salesforce through account. In this case, log in using the “” account.

13. You will be redirected to the Salesforce page to login.

14. Install this package in production (chosen org) by clicking on “Install in Production”.

15. Agree for the terms and conditions and click on “Confirm and Install”.

16. Now, you need to install it. Select “Install for All Users” and click on “Install”.

17. It’s almost done. You will receive an email when the installation is complete. Click on “Done”.

The package is now successfully installed.

Use Case 1: Searching the Salesforce Records

We can fetch the records that are present in our Salesforce org by typing the “/salesforce search-term” command. Basically, this command returns the total number of records that include the specified search-term of accounts, opportunities, leads, contacts, cases and tasks objects. If the search-term does not find any record, it returns “Your search did not return any results.”

Example 1:

Let’s search for “Burlington Textiles”. In this example, we view the records with respect to all objects and post the record to the channel.

/salesforce Burlington Textiles


Slack returns the following message:

Let’s elaborate by clicking on “Object”.

You can see the record by clicking the “View Record”. Let’s view the account.

Post to Channel:

Let’s post the previous lead record to the channel. Click the “Post to Channel” button.

Now, the lead record is posted to the channel.

Example 2:

Let’s search for “linux”. Here, the search-term is “linux”.

/salesforce linux


There are no records that include the “linux” search-term.

Use Case 2: Sharing the Salesforce Records to Slack Members

If you want to share a specific record to slack team/channel/user, you need to utilize the “Find and share a record” that first asks the search-term to search the record. If a record is found, it fetches the record in the drop-down format. We need to select that record and share it to a specific user in Slack. If multiple records exist, it gives the drop-down results object wise.


Let’s share the account record to Linuxhint_testuser with the account name as “Edge Communications”.

1. Search for “Find and share a record” in the Salesforce messages.

2. Type the search term as “Edge” and choose “Edge Communications” under the “Account” object and click on “View record”.

3. Now, the “Account” record is displayed with details. Click on “Share”.

4. Next, you need to specify the Channel. We select our user. Then, click on “Share”.

5. This record is shared with @Linuxhint_testuser. Click on “Done” and open the Linuxhint_testuser chat.

6. The “Account” record is now shared to this user.


We learned how to integrate Salesforce with Slack. For a clear understanding, each step is explained with screenshots. After the integration, we learned two different use-cases to fetch and share the records in Slack from Salesforce. If we want to get the records from Salesforce, we need to use the “/salesforce [search-term]” command. Record sharing can be done using the “Find and share a record” option in Slack.

About the author

Gottumukkala Sravan Kumar

B tech-hon's in Information Technology; Known programming languages - Python, R , PHP MySQL; Published 500+ articles on computer science domain