Enabling and Executing Policies

Triggering Policies for Execution

The policies have to be triggered for them to be executed within Salesforce. There are 3 ways to do this:

  1. Process Builder
  2. Triggers
  3. Scheduler

Using Process Builder

In order for a fullcast.io policy to work in Salesforce, you must enable it through your Salesforce instance by creating a process for that policy. The Process Builder in Salesforce is a tool that you can use to automate a business process. Your Business Partner will assist in setting this up if you've purchased our Data Desk services.

In order to set up the Process Builder for ANY Fullcast policy in Salesforce:

  1. Log in to your Salesforce instance.
  2. From Setup, type in Process Builder into the Quick Find search box.
  3. Select Process Builder, and click New.
  4. Give the new process a Name and Description. From the drop-down list under The process starts when, select It's invoked by another process.
  5. Click Save.
  1. Click Add Object. Select an object to associate with the process from the drop-down list. Click Save.
  2. Next, define the criteria that must be true before the process can be executed.
  1. Click Add Action. From the drop-down menu, select Apex for the action type.
  2. Fill in an Action Name, and select Policy Handler from the Apex Class drop-down menu.
  3. Now, set the mandatory Apex variables.
  • For the policy type field: select String for the variable type, and under Value, enter the policy name you'd like to set up.
  • For the record ID field: select Field Reference for the variable type, and under Value, search and enter Lead ID.
  • For the Input Value 1 field: select Field Reference for the variable type. Under Value, search and enter for what you'd like the tag to be determined by. If you want to filter by Lead source, for example, you must enter Lead Source in the value section.
  • For the Input Value 2 field: select Field Reference for the variable type. Under Value, search and enter for what you'd like the skills to be determined by. If you want to filter by Status, for example, you must enter Status in the value section.
  • For the Input Value 4 field: select Field Reference for the variable type. Under Value, enter "WILDCARD" to use wildcard operators. Refer to this article for using tag operators. Input Value 4 is only used for Routing.
  • For the Input Value 5 field: select Field Reference for the variable type. Under Value, enter "ASYNC" to make the motion package run asynchronously.

❗️

Input Values vary by policy.

Based on the policy requirements, you'll need to pass a specific combination of Input Values in the Process Builder. This varies by policy and is highly customizable to the business requirements. As an example, Input Value 4 (Wildcard) is only used in routing policies.

  • Click Save when you've finished setting the Apex variables.
  1. When you're done defining the criteria for your process, click Activate.

🚧

Keep your Process Builder light.

It is advised that the process builder setup be very light, as it is only used to trigger a Fullcast Motion policy upon a specific event or point in time at which the policy needs to activate. Here, you're defining those circumstances, but in the Fullcast Motion Module policy pages, you're defining the specific actions to execute.

📘

Hierarchy and Inheritance of Policies

In the fullcast.io hierarchy, policies don't need to be enabled at every node. As long as a parent node in the hierarchy has a policy defined, all immediate children of that parent are able to execute that policy. However, if you'd like to execute a policy at only the child level of a particular parent node, there must still be a placeholder policy in place at the parent level.

Setting up Routing Functions in Salesforce

In addition to the above, in order to set up certain routing functions in Fullcast, such as territory-based lead routing, you must enable it through your Salesforce instance using the Custom Metadata settings.

To set up the following policy functions refer to the guides below:

Lead Routing

[ ] Enabling Triggers on Leads
[ ] Configuring Best Matched Account Logic
[ ] Enabling Territory-based Routing for Leads
-- [ ] Entering Tenant ID Details
-- [ ] Set Field Mapping
-- [ ] Enable Territory-based routing for Leads

Account Routing

[ ] Enabling Triggers on Accounts
[ ] Enabling Territory-based Routing for Accounts
-- [ ] Entering Tenant ID Details
-- [ ] Set Field Mapping
-- [ ] Enable Territory-based Routing for Accounts

Opportunity Routing

[ ] Appointing a Primary Person for Role-based Routing

Account Dedupe

[ ] Setting up Salesforce Standard Duplicate Rules
[ ] Setting Up Best Matched Account Criteria

Setting up Routing for any Object

In order to do any kind of routing in fullcast - before configuring the policy in the Motion Module, you'll need to enter the tenant ID in Salesforce.

To enter or update the correct Tenant ID, follow along here:

  1. Log into your Salesforce instance.
  2. Go to Setup, and search for Custom Metadata Types in the search bar.
  3. Look for the Fullcast Policy Setting in the list.
  4. Click Manage Records for Fullcast Policy Setting.
  1. Click Edit next to the Tenant Id record.
  1. Enter the tenant ID for your Fullcast instance where it says Field Value.
  1. You can find your Fullcast tenant ID by clicking on your user icon in the top right corner of your screen:
  1. Click Save to complete the tenant ID configuration.

Viewing Policy Status and Error Logs

To make sure that your policy has been executed correctly and acted upon the correct entities, we can use the Policy Status and Policy Error Logs objects in Salesforce to track the actions made on your records. Let's go over what each of these is below.

Viewing Policy Status

The Policy Status object in Salesforce can be added by your CRM administrator to view the execution status of each policy. Every time a policy is run, a record for that action is created under the Policy Status object. You can click on any of these records to view the status (E.g., Success, Failure) of that policy execution.

Working on Policy Configuration

Assessing Policy Error Logs

The Policy Error Logs object in Salesforce can be added by your CRM administrator to view errors made while creating policies. If a policy was improperly set up and failed to execute, a record will get created in the Policy Error Logs object, where you can see what went wrong in detail.

After assessing what went wrong, you can go back into the fullcast.io Motion Module and edit the policy to correct it for successful execution.

Working on Policy Configuration

While onboarding and throughout your fullcast.io experience, you'll need to work with your Business Partner on configuring policies so that they run smoothly. In order for your policies to execute properly, you must establish what fields are being mapped on your end with your business partner.