When Salesforce meets Slack - 2

In my last blog, I explained about could be done using the drag and drop functionalities from the Slack Managed package. Now, let's dig a little deeper and explore the configurable features that the Slack managed package has to offer. Let's say you have a business use case where a team of Sales Rep collaborate on Slack. There's a process in place which marks the "Escalated" field on Case to true. As soon a case record would be marked escalated, the "Case" channel on Slack should be notified of that record. How would you achieve that? It's pretty simple. **1.** Navigate to App Launcher > Slack Setup. Click on "Continue". Type in the Message Destination Name of your choice. In my case, I have named it "Cases" as I'm making one for Case. Select your workspace and then your channel. After you save it, copy the Message Destination ID as you'll be using it further. ![Capture.PNG](https://cdn.hashnode.com/res/hashnode/image/upload/v1615228345760/4z0qXdzQA.png) **2.** Now, create a new Process Builder as below: ![Capture.PNG](https://cdn.hashnode.com/res/hashnode/image/upload/v1615228723719/NqYKsXoqo3.png) Define the criteria as required. In my case, I have applied a check for "Escalated" field. ![Capture1.PNG](https://cdn.hashnode.com/res/hashnode/image/upload/v1615228731792/UuOQVzvcU.png) Now, set the Immediate action with the action type as "Apex". Select the Apex class as "Slack: Post Message". This is one of the Apex classes that comes with the Slack Managed Package. Enter the respective values and hit Save and activate. ![Capture2.PNG](https://cdn.hashnode.com/res/hashnode/image/upload/v1615228741206/GP_R5CWuU.png) **3.** Now, anytime, a case is marked as escalated, all the users in the respective channel would get a notification as described below: ![Capture4.PNG](https://cdn.hashnode.com/res/hashnode/image/upload/v1615228749976/gJqgC4ub4.png) The similar implementation could be done through flows as well. I'll leave that for you to try. In my next blog, I'll explore the Apex side of customization using the APIs provided by Slack. That's gonna be a challenging one. But, let's see where that goes. Did you find this blog useful? If yes, don't forget to share your feedback or questions! Happy coding :)