---
schema_version: "1"
id: cd15a6efe21ea19f03a52fcf5a6019da26c77fbd2dd486563ff3d8b8e3ff6699
title: Overview of Opt Out of Promotion Process Template
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/bapi_promotion_opt_out_overview.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.bapi_promotion_opt_out_overview.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 9fccdf1abc0e06145c13d4c6fa9da972f82f5f4b454817edaf7cbc2613230c24
description: Learn about the parts of the Opt Out of Promotion loyalty program process template. Also, understand how to use the template to create a process based on your loyalty program’s requirements.
products:
  - Loyalty Management
release: "264"
---
# Overview of Opt Out of Promotion Process Template

Learn about the parts of the Opt Out of Promotion loyalty program process template. Also, understand how to use the template to create a process based on your loyalty program’s requirements.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: Lightning Experience in&nbsp;<strong>Enterprise</strong>,&nbsp;<strong>Performance</strong>, <strong>Unlimited</strong>, and&nbsp;<strong>Developer</strong>&nbsp;Editions</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: Orgs that have the B2C - Loyalty, B2C - Loyalty Plus, B2B - Loyalty, Loyalty Management - Growth, or Loyalty Management - Advanced license enabled</td></tr></tbody></table>

## What Does the Template Contain?

The template contains a rule and a set of parameters. The Opt Out of Promotion rule has one condition and the condition has a child action.

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small ">
        <colgroup>
          <col style="width:20%">
          <col style="width:20%">
          <col style="width:20%">
          <col style="width:20%">
          <col style="width:20%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d46803e85">Rule Step Name</th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d46803e88">What Does the Rule Step Do?</th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d46803e91">Parameters used in the Step</th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d46803e94">What Does the Parameter Do?</th>
            <th scope="col" class="slds-cell-wrap" style="vertical-align:top;" id="d46803e97">Examples of Customization</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="Rule Step Name" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e85 ">Is the Member Enrolled in the Promotion?</td>

            <td data-label="What Does the Rule Step Do?" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e88 ">Checks whether the member is enrolled in the promotion that the member wants to opt
              out of.</td>

            <td data-label="Parameters used in the Step" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e91 ">LoyaltyProgramMbrPromotionRecord </td>

            <td data-label="What Does the Parameter Do?" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e94 ">Checks whether there’s a member promotion record that tracks the member’s promotion
              enrollment.</td>

            <td data-label="Examples of Customization" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e97 ">If you don’t want members to opt out of promotions after the enrollment period, add
              condition criteria that check whether the member is opting out of the promotion
              after the enrollment end date or the promotion end date.</td>

          </tr>
          <tr class="">
            <td data-label="Rule Step Name" class="slds-cell-wrap" rowspan="2" style="vertical-align:top;" headers="d46803e85 ">Change Member's Promotion Enrollment to Not Active </td>

            <td data-label="What Does the Rule Step Do?" class="slds-cell-wrap" rowspan="2" style="vertical-align:top;" headers="d46803e88 ">Set the member’s promotion enrollment status as inactive.</td>

            <td data-label="Parameters used in the Step" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e91 ">LoyaltyProgramMbrPromotionRecord</td>

            <td data-label="What Does the Parameter Do?" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e94 ">Used to determine the member promotion record in which the member’s promotion
              enrollment status has to be set as inactive.</td>

            <td data-label="Examples of Customization" class="slds-cell-wrap" rowspan="2" style="vertical-align:top;" headers="d46803e97 ">If you have a custom field to store the date that the member has opted
              out of the promotion on, add the field as an input parameter and use the TODAY ()
              formula to store the date when the member has opted out of the promotion.</td>

          </tr>
          <tr class="">
            <td data-label="Parameters used in the Step" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e91 ">LoyaltyProgramMbrPromotionId</td>

            <td data-label="What Does the Parameter Do?" class="slds-cell-wrap" style="vertical-align:top;" headers="d46803e94 ">Stores the ID of the member promotion record where the member’s promotion enrollment
              status is set as inactive.</td>

          </tr>
        </tbody>
      </table>

The template has these parameters.

- MemberId—Stores the ID of the member who wants to opt out of the promotion.
- MembershipNumber—Stores the membership number of the member who wants to opt out of the promotion.
- PromotionId—Stores the ID of the promotion that the member wants to opt out of.
- PromotionName—Stores the name of the promotion that the member wants to opt out of.
- LoyaltyProgramMbrPromotionId—Stores the ID of the member promotion that tracks the member’s promotion enrollment status.
- LoyaltyProgramMbrPromotionRecord—Stores the details of the member promotion record that tracks the member’s promotion enrollment status.

## How Can You Execute the Processes Created Using the Opt Out of Promotion Template?

The OptOutPromotion business API allows you to execute the processes created by cloning the Opt Out of Promotion loyalty program process template. You can integrate the API with the external system or website where you let members opt out of promotions.

To execute the API, you’ve to:

- Provide the API name of the cloned process in the API endpoint,
- Provide in the API request
    - The Loyalty Program Member ID or the membership number of the member who wants to opt out of the promotion.
    - The ID or the name of the promotion that the member wants to opt out of.

When you execute the API, the Opt Out of Promotion rule checks whether the member is enrolled in the promotion. If the member is enrolled, the rule changes the member’s promotion enrollment status to inactive. If the member isn’t enrolled in the promotion, a message informs the member that they aren’t enrolled in the promotion.

## Examples of How You Can Use the Template

You can clone and extend the template based on your requirements. Here’s how you can use the process template:

 
| Use Case | How to Achieve the Use Case Goal? |
| --- | --- |
| Members can opt out of promotions from the loyalty program’s site or from the company’s ecommerce site. | Integrate the OptOutPromotion business API with your loyalty program’s site and your company’s ecommerce site. |
| Ask customer service reps to contact the member to check why the member has opted out of the promotion. | Add a Create or Update Record action in the Opt Out of Promotion rule to create a task for customer service reps to contact the customer. |