Opt In Customer to Campaign

Opts a customer in to an active campaign for which they are eligible. An opt-in period requires the customer to indicate that they want to participate in a campaign before receiving any of the outcomes or messaging connected with the campaign. When a customer opts in, their status is updated and they are then allowed to earn the specified reward.

Sequence Diagram

See the overall flow for this task below.

CUSTOMER CUSTOMER CLIENT MIDDLEWARE CLIENT MIDDLEWARE SESSIONM SESSIONM OPT IN CUSTOMER TO CAMPAIGN Opt in to campaign Opt in customer to eligible campaign Opt in customer to campaign, changing status so they can earn incentive Send OK response for opt-in Display opt-in response

Take Note

To enable "opt-ins," a campaign must be created with optin_required set to "true": optin_required=true.