Advanced Scenes Usage
Scenes Flow
If there are flow map configured in your project, you can use that as well inside the scenes array. For example:
If you configured in Platform - Flow Map
this scenes flow definition:

You can use the SDK with:
BlingsPlayer.create({
// ...
scenes: [{ "lineup": "short flow" }]
})
Scenes with data
You can also pass data directly to each scene, instead of passing global data. This will allow re-using same scene with different data
BlingsPlayer.create({
// ...
scenes: [
"Intro Scene",
{ id: 'Prodcut Scene', data: products[1] },
{ id: 'Prodcut Scene', data: products[2] }
],
data: { user_name: "John" } // Data that exist on scene level will override global data
})
Example usage of data in scenes:
// example data: product 1
{
days_left: 4,
title: "earn 200 bonus points",
description: "Iced Coffee with..",
CTA_link: "link.com/prod1",
image: "images.com/prod1.png"
}

// example data: product 2
{
days_left: 4,
title: "$6.99 Breakfat Combo",
description: "Classic Breakfast..",
CTA_link: "link.com/prod2",
image: "images.com/prod2.png"
}

Last updated