Create reactors for joining or leaving an audience
Introduction
Reactors that trigger when an end-user joins or leaves an audience is a great way to incentivise and reward specific behaviour. You can use them in addition to your main loyalty offering, or even as part of the core logic of your program.
Configuration
Navigate to Events > Reactors. Click 'Create' in the top right corner.
Give the reactor a name and choose
AUDIENCE_JOINED
orAUDIENCE_LEFT
from the 'Event type' list.Choose whether you want this reactor to occur an unlimited number of times or be limited to user or tenant activations.
Move to the 'Payload Constraints' tab. Click 'Is Audience' in the 'Audiences' section. Select the audience you want the
AUDIENCE_JOINED
orAUDIENCE_LEFT
event to be related to in order for this reactor to trigger. This will create a JSON schema which references theaudienceId
of that audience.Move to the 'Reactions' tab. Configure the reaction as needed. For more information about how to configure a reaction see the Activation limits page.
Optional - Move to the 'Effectivity' tab. Set a start date and an end date for the reactor. If you'd like the reactor to run immediately and indefinitely skip this step.
Click 'Save'.
Tips
Not selecting a particular audience in step four of the tutorial will mean that the reactor will trigger when an
AUDIENCE_JOINED
orAUDIENCE_LEFT
event is reported for any audience.Depending on your audience criteria setting an activation limit may not be needed in order to ensure the user only triggers the reactor a certain number of times. Consider adding one as an extra layer of security. For example;
Imaging you have an audience which an end-user joins when they make their first purchase. A corresponding
AUDIENCE_JOINED
reactor for this audience wouldn't need an activation limit, as a user is only ever going to be able to join that audience once. However, setting an activation limit ensures that if the audience criteria contained errors or was changed in the future then the user is still only going to be able to trigger the reactor once.
You can specify multiple audiences within the payload constraints by using the following schema in advanced mode. You can find the audienceId of an audience in the URL shown when viewing an audience in the console.
{ "type": "object", "$schema": "http://json-schema.org/draft-06/schema#", "properties": { "audienceId": { "type": "string", "enum": [ "audienceId1", "audienceId2", "audienceId3" ] } }, "required": [] }
Last updated
Was this helpful?