Advanced Activation Flow

This guide explains the advanced activation flow, which works for both scheduled and real-time triggered campaigns. This model provides your system with full flexibility to embed its own custom business logic, such as fraud checks, VIP segmentation, or dynamic reward scaling, into the promotion delivery process.

This flow is designed for complex eligibility workflows where you need to orchestrate the validation and reward delivery in response to a direct customer action.

Prerequisite: Register a Webhook Listener (One-Time Setup)

Before you can use this flow, your system must be able to receive notifications from Optimove. This requires registering an endpoint (a webhook listener) that you control. This is a one-time setup.

  • For scheduled campaigns, use the RegisterEventListener API with EventTypeID: 5.
  • For triggered campaigns, use the POST /conditional-execution/v2/triggered/webhooks/ endpoint.

The Activation Flow

The activation flow begins with a webhook from Optimove and is completed by a series of API calls and internal logic managed by your system. This sequence is interactive, requiring a direct customer action to trigger the final validation and reward delivery.

Sequence Diagram for the Advanced Activation Flow

Sequence Diagram for the Advanced Activation Flow

1. Campaign Trigger (Webhook)

What happens: An Optimove campaign is executed. Optimove sends a webhook notification to your registered endpoint to signal that the campaign has started.

Why it's important: This webhook acts as the starting pistol for the entire process, informing your system that a new promotion is active and customers have been targeted.

2. Get Targeted Customers

What happens: Upon receiving the webhook, your system makes an API call to Optimove (Get Campaign Customers) to retrieve the full list of targeted customers.

Why it's important: This step provides your system with the specific audience for the promotion. At this stage, you can apply your own preliminary business logic, such as:

  • Scrubbing the customer list based on consent status.
  • Performing initial fraud checks.
  • Segmenting customers for different user experiences.

3. Calculate Customer's Rewards

What happens: This step is initiated by a customer's action on your website or app (e.g., clicking a "Claim Reward" button). In response, your system calls the OptiPromo validateCustomers API.

Why it's important: This real-time check is crucial. It asks OptiPromo to:

  • Validate Eligibility: Confirm the customer is still eligible for the reward by checking promotion rules and budget limits.
  • Determine the Reward: Calculate and return the specific bonus or reward the customer is entitled to based on campaign logic (e.g., reward tiers).

4. Activate Reward on Your Platform

What happens: After receiving a successful validation response from OptiPromo, your system activates the reward internally. This is a process that occurs entirely within your own environment.

Why it's important: This is the moment the customer actually receives their reward. Examples include adding free spins to a gaming account, applying a discount to a shopping cart, or crediting bonus money to a wallet. You can also apply any final, post-validation logic at this point.

5. Update Customer Status

What happens: Immediately after your system successfully delivers the reward, it must make a final API call to Optimove (Update Customer Status) to confirm the action.

Why it's important: This final "closing the loop" call is critical. It informs Optimove that the reward has been successfully delivered, which:

  • Prevents the same customer from receiving the reward twice.
  • Ensures accurate campaign reporting.
  • Keeps the promotion budget up-to-date.

What OptiPromo Still Handles

Even in this advanced flow, OptiPromo's promotion engine automatically handles the core business logic during the validation step (Step 3), including:

  • Promotion rule enforcement
  • Reward tier assignment
  • Budget enforcement

API Reference

Your system will need to make the following calls to implement this flow.