Segmentation

Introduction

Use Audiences in Satori to segment your players into distinct groups based on shared properties. Audiences or Segmentation extend Remote Configuration and allow targeted remote configuration values. For example, grant early access to a new feature to your VIP audience or provide different in-game experiences based on geo, spend, progression, etc.

Satori offers segmentation out of the box based on default user properties. This can be extended with custom user properties and events. LionSDK also sets up some basic user properties during initialization to save time.

Using events, the user can form computed properties on the Satori dashboard. Audience filters can use both custom and computed properties to form custom audiences to enhance segmentation.

This document explains how to use and extend these base segmentation capabilities using Custom Properties and Events.

Requirements

  • Make sure that you have set up Remote Configuration following the guide here: Remote Configuration
  • Understand how players can be assigned to Segments or Audiences using the following in Satori:
  • Read the examples here on how to use Filter Expressions to construct audiences using Default, Custom, and Computed properties.
  • Use the methods below to fire events or update custom property values if a custom segmentation is needed

Implementation

Update Custom Property

The custom property must be configured in Satori Dashboard for this function to work. See HeroicLabs guides.

Function signature to add a custom property

SetCustomProperties(Dictionary<string, string> customPropertiesList)

Example

Dictionary<string, string> customProperties = new Dictionary<string, string>
{
		{ "examplePropertyName", "value" }
};
SatoriController.SetCustomProperties(customProperties);

Log Event

The event must be created in Satori Dashboard for this function to work. See HeroicLabs Guides

Function signature

SatoriController.LogEvent(
	string name, 
	string value, 
	Dictionary<string, string> metadata = null)

Example

// This will log an event named "iap_purchase", with a value of "verified"
SatoriController.LogEvent("iap_purchase", "verified");