Define a Groovy Trigger to Send Notifications to Slack
Before writing the groovy scripts, ensure that you complete these steps:
-
Create a Slack Channel. For more information, see "Create a Slack Channel in Your Fusion Application".
-
Enable notifications for service requests. For more information, see "Enable Notifications for Service Requests".
To define a groovy trigger to send notifications to Slack:
-
Sign in to the application as an administrator.
-
Ensure that you're in a sandbox.
-
Navigate to Application Composer.
-
In the Application field, select CRM Cloud from the drop-down list.
-
In the Object Tags region, select the Service check box.
Note: If you're writing a groovy trigger on a Sales object, select the Sales check box. -
Expand the Service Request object.
-
Click Server Scripts.
-
Select the Triggers tab.
-
Create an object trigger for Service Request Server Scripts.
-
Define your groovy trigger as described in "Examples of Groovy Scripts for Sending Notifications to Slack".