Skip to main content
All CollectionsSolve an issue
Integrate a widget with audience feature
Integrate a widget with audience feature
Marine CIPRIANO avatar
Written by Marine CIPRIANO
Updated over 2 months ago

The code integration procedure remains unchanged from a classic widget, but it includes specific information to take into account.

Use the sendAudienceData function

During integration, use the sendAudienceData function to send data managing audiences. The function supports sending an object containing information such as language, age, gender, eligibility, etc.

Example

sendAudienceData({ age: 20 });

Send various datas types

You can send different types of data, such as text, numbers, booleans, and arrays of text.

Example of data types

  • Text for gender

  • Number for age

  • Booleans (true or false) for eligibility

  • List to directly enter a pre-created audience"

Flexibility in data transmission

You have the flexibility to send multiple values at once or in separate transmissions. If you send the same property multiple times, only the last sent value will be considered. For example, if you first send 'age: 20' and then 'age: 25', the considered value will be 'age: 25'.

Did this answer your question?