INTEGRATE SALESFORCE WITH SLACK

Today, We are going to integrate Salesforce (The Biggest CRM Platform) with Slack.

By using Salesforce and slack together, teams can easily up to date on their Salesforce record within Slack. Salesforce buys Slack in a $27.7 billion Mega Deal in Dec, 2020. 

Integration can be easily done and configured by Salesforce Administrator and incorporated into a flow and process to send messages and notifications to a public or private Slack channel or an individual user/group of users.


Also Read: Connect Dropbox with Salesforce using REST API

Let’s Start the Integration: 

  • You have to create a slack app and install it into your environment.

  • Go through Slack < Click on App < Search ‘Salesforce’ App.

            

or you can also go through Slack App Directory ‘https://app.slack.com/apps/’.

                

                

  • After Clicking on Add, you will be redirected to Slack App Directory. In the App Directory.

                

  • Click Add to Slack.

  • Now, We have to Click Add to Slack Again.


                
  • Review the conditions and permissions and Click Allow.
                  
  • Enter your Salesforce Credentials to Connect Account with Slack.

                      

  • Yeah!! We have integrated salesforce to slack successfully.

  • I have one Account Named Burlington Textiles in my Salesforce org as you can see below.

                    

  • Now, We can fetch details in any channel in slack of any record using ‘/salesforce [keyword]’. I have searched for Burl.

      

And got it.

   

Further we can view all the detailed records.

  

After Clicking on Account ‘View Record’. I got..

        


Now, To Send Notifications or send Messages or for automating, we have to do some more steps.

  • Go to Slack < Apps < Salesforce < Click on Get Companion App.

            

  • You are redirected to the page below.

            

  • Click on Get It Now Button. Tell where you want to install this package “In Production” or  “In Sandbox”. I am installing it in Production.

              

  • Now, Read the terms and conditions carefully and then Click on Confirm and Install.

            

  • If you want that everyone can access slack then click “Install for All Users” and If you want to specify for specific profiles then choose the third option. I am choosing the first One, Only for Admins.

        

  • After Installation, You can see Slack as Installed Package in Installed Packages from Setup.

           

Woohoo! We have Installed Slack in Salesforce Successfully.

  • To set Up Slack in org, Go to App Launcher and Select Slack App.

         

  • We have to Set Up Slack with completing the five steps by Clicking Get Started.

            

  • First Step is System Connections. We have to make a connection between Salesforce and Slack by clicking on Authorize Button. 


        

  • Your First Step is completed. Click on Continue  to start the second step.

            

  • Add Custom Objects which you want to be used in Slack.

  • Click Add and then Select Activate Link, then select Automatic Activation.

  • If automatic Activation Fails Due to some error, You’ll need to activate it manually.

  • Now, Click Activate to Confirm and then Click Finish.


            

  • After that you have to Click on Continue to start the third step which is Custom Alerts. Now, You have to create a New Alert. Give New Custom Alert, a Name and select on which object you want alerts and then Select Alert Type Record Level and then Click Next.


              

  • Now, Set your Alert Criteria by Selecting a field, an operator and a value.


            

  • Click on Save and then Click Finish.


            

  • Now, We have two steps remaining. Click on Step 4: Org Configuration.


            

  • First, You have to Add Slack Actions to Layouts.

  • Check the box to select your Salesforce Environment(s).

  • You have two types of Salesforce Actions available: Send to Slack and Slack Alerts.

  • Select the Checkbox on which page layouts you want to add these actions. 

  • Click Add Actions to Layouts and then Click Next.


    

         

  • Second, You have to Add Slack Message Viewer Component to Pages.

  • This component is to view Slack Messages in Salesforce. This is only supported for Standard Objects.

  • Select the Checkbox on which page layouts you want to add this component.

  • Click Add Component to Pages.

  • Click Finish and then Click Continue to move on to Last Step.



          

  • In the last step, you can create custom message destinations to send Information from Salesforce to Specific Slack Conversation.

  • Give a Message Destination Name, Select Slack Workspace and Select the Channel or direct message.

  • Click on Save and then Click on Finish.


                

  • Copy the Message Destination File Id which we used in the next step.

    

        

  • Make a New Process. Give the process, a name and Select a process Starts When a Record Changes.


              

  • Select the object on which you want to start the process. Make Sure only when the process is created is selected.

  • Click Save.

  • In the Add Criteria Section, Give Criteria a name and Select No Criteria-just execute the actions! Is selected.

  • Click Save.


            .

  • Click on Add Action and Select Apex as action type. Give Action, a Name and Select Slack: Post Message as Apex Class. 

  • Now, Set Apex Variables. 

  • In Record Id, Give Field Reference, Enter Contact and Select Contact ID.

  • In Message Destination ID, Paste the Destination ID which you copied before.

  • Click Add Row. Select Message Variable, Type String, Value is New Contact is Created.

  • Click Save.

  • Click Activate and then Click Confirm.



            

Woohoo!!! We have completed all Steps to Setup the Integration. Now, There’s only one thing you need to do is Test.


Benefits

There are many Benefits of Integrating Slack with Salesforce like:

  • Your Sales team gets the latest Information.

  • Users can create and edit Salesforce Objects from Slack.

  • Users can have access to Reports and Dashboards through Slack Channels.

  • You never miss important updates.

  • Easy File Access and Sharing.

  • Enhances Customer Engagement and Experience.


Comments