Overview
This tutorial explains how to configure:
- Rule for creating CTAs when there is a change in sponsor attributes (company, location, or title)
- Rule for creating CTAs that prompts you to delete a sponsor if the sponsor is deleted from SponsorTracking::Contact or SponsorTracking::RelationshipContact.
See Also:
- Rule Building Process section in Rules Engine Overview.
Assumptions
- A Relationship Type is already configured. This tutorial uses “PaaS” (Platform as a Service) as an example.
Rule for Tracking Sponsor Attribute Changes
To create a rule for sponsor tracking that triggers a CTA whenever there is a change in sponsor attributes:
- Under Edit Rule, enter or select the following details:
- Rule Type: Select Custom.
- Rule For: Select Relationship.
- Rule Name: Enter the rule name. For example. Standard Sponsor Tracking Rule for PaaS.
- Relationship Type: Select the Relationship Type. For example, PaaS.
- Description: Enter description, if any.

- Click NEXT.
- Under Setup Rule, drag-and-drop the following fields from the
RelationshipSponsorTrackingHistory object in the Show section:
- RelationshipSponsorTrackingHistory::Relationship (This field will be available by default)
- RelationshipSponsorTrackingHistory::Relationship Name
- RelationshipSponsorTrackingHistory::ChangedAttribute
- RelationshipSponsorTrackingHistory::NewValue
- RelationshipSponsorTrackingHistory::PreviousValue
- RelationshipSponsorTrackingHistory::Contact Name

- Drag-and-drop the following fields in the Filters section.
- GS Relationship::Relationship Type (This field and its value are available by default after you select the relationship type in step 1.)
- RelationshipSponsorTrackingHistory::ChangedAttribute - equals - company.
- RelationshipSponsorTrackingHistory::ChangedAttribute | equals | location.
- RelationshipSponsorTrackingHistory::ChangedAttribute | equals | title.
- RelationshipSponsorTrackingHistory::Created Date | greater or equal | Add N Days to Rule Date | -1.
- RelationshipSponsorTrackingHistory::Created Date | less than | Rule Date.

- Modify the Advanced Logic to A AND (B OR C OR D) AND E AND F.

- Click NEXT.
- Under Setup Action, enter or select the following details:
- Action Type: select Call To Action.
- Priority: select High.
- Type: select Risk.
- Status: select New.
- Playbook: select a playbook if you already have one for sponsor tracking related changes.
- Reason: select Sponsor Change.
- Owner Field: select the owner for the CTA being created.
- Due Date: Run Date + 5 Days.
- Default Owner: enter a default owner.

- Post update to chatter: select Always.
- Post update to comments: select Once.
- Comments: enter <${RelationshipSponsorTrackingHistory::Contact Name}> has changed <${RelationshipSponsorTrackingHistory::ChangedAttribute}> from <${RelationshipSponsorTrackingHistory::PreviousValue}> to <${RelationshipSponsorTrackingHistory::NewValue}>.
Note: Type @ to see the token values for Comments.

- Click SAVE.
Rule for Tracking Sponsors to be Deleted
Similar to Rule for Tracking Sponsor Attribute Changes, you can configure a rule for tracking sponsors that are to be deleted.
- Under Setup Rule, drag-and-drop the following fields in the Show section.
- SponsorTracking::GSRelationship (This field is available by default as you select the relationship type while creating the rule)
- SponsorTracking::SponsorFullName
- SponsorTracking::Account
- SponsorTracking::GSRelationshipName
- Account::Created By ID Name
- SponsorTracking::Account Name

- Drag-and-drop the following fields in the Filters section:
- GS Relationship::Relationship Type. (This field is available by default after you select the relationship type while configuring the rule.)
- SponsorTracking::Contact | equals | NULL.
- SponsorTracking::Last Modified Date | greater or equal | Add N Days to Rule Date | -1.
- SponsorTracking::RelationshipContact | equals | NULL.

- Modify the Advanced Logic to A AND C AND (B OR D).

- Click NEXT.
- Under Setup Action, enter or select the following details:
- Action Type: select Call To Action.
- Priority: select High.
- Type: select Risk.
- Status: select New.
- Playbook: select a playbook if you already have one for sponsor tracking related changes.
- Reason: select Sponsor Change.
- Owner Field: select the owner for the CTA being created.
- Due Date: Run Date + 1 Days.
- Default Owner: enter a default owner.

- Post update to chatter: select Always.
- Post update to comments: select Once.
- Comments: enter The contact <${SponsorTracking::SponsorFullName}> of Relationship <${SponsorTracking::GSRelationship Name}> has been deleted.
Note: Type @ to see the token values for Comments.

- Click SAVE.