シルバーエッグレコメンドメッセージ¶
アプリ内メッセージでシルバーエッグレコメンドメッセージを表示するために、アプリ内に追加の実装が必要になります。 このページでは追加の実装について記載します。
警告
本機能の利用には、以下を全て満たしている必要があります。
- シルバーエッグ・テクノロジー社との契約があり、アイジェントレコメンダーシステムを利用できる状態である
- 弊社へシルバーエッグレコメンドメッセージの利用申請済みである
- Repro iOS SDK 5.3.0 以上、Repro Android SDK 5.2.0以上を利用している
はじめに¶
シルバーエッグレコメンドメッセージ表示のため、以下の2つの項目を追加で実装する必要があります。
- (必須)Cookie
- シルバーエッグ上でのユーザーIDに相当する値です。アプリ本体で取得しているレコメンデーションの cookie と必ず一緒になるよう設定する必須パラメータです。
- (任意)ProdKey
- 指定した
ProdKey
を元に、シルバーエッグレコメンドメッセージを表示します。メッセージ表示トリガー のイベントのイベントプロパティとして設定する任意パラメータです。
- 指定した
設定例¶
- Reproの初期化(setup)前にシルバーエッグ・テクノロジー社のユーザーID(cookie)の設定とシルバーエッグ・テクノロジー社に登録してある商品ID(prod)のキー名を設定します。
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
[Repro setSilverEggCookie:@"silver egg's cookie_id"];
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
[Repro setSilverEggProdKey:@"product_id"];
// Setup Repro
[Repro setup:@"YOUR_APP_TOKEN"];
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
Repro.setSilverEggCookie(user_id: "silver egg's cookie_id")
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
Repro.setSilverEggProdKey(key: "product_id")
// Setup Repro
Repro.setup(token: "YOUR_APP_TOKEN")
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
Repro.setSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
Repro.setSilverEggProdKey("product_id");
// Setup Repro
Repro.setup(this, "YOUR_APP_TOKEN");
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
ReproCpp::setSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
ReproCpp::setSilverEggProdKey("product_id");
// Setup Repro
ReproCpp::setup("YOUR_APP_TOKEN");
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
Repro.SetSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
Repro.SetSilverEggProdKey("product_id");
// Setup Repro
Repro.Setup("YOUR_APP_TOKEN");
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
Repro.setSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
Repro.setSilverEggProdKey("product_id");
// Setup Repro
Repro.setup("YOUR_APP_TOKEN");
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
Repro.setSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
Repro.setSilverEggProdKey("product_id");
...
// Setup Repro
// Write 'Repro.setup' in a class that inherits from Application or AppDelegate.
// Register your user ID (cookie) that you have registered with Silver Egg Technology to ReproSDK.
await Repro.setSilverEggCookie("silver egg's cookie_id");
// Register the key name of the event property in which the product ID (prod) registered in Silver Egg Technology is embedded to ReproSDK.
await Repro.setSilverEggProdKey("product_id");
...
// Setup Repro
// Write 'Repro.setup' in a class that inherits from FlutterApplication or AppDelegate.
- メッセージ表示イベントトリガーにプロパティとして上記で設定した
ProdKey
を指定して、メッセージを表示します。
[Repro track:@"addCart" properties:@{
@"product_id": @"abc123"
}];
Repro.track(event: "addCart", properties:[
"product_id": "abc123"
])
Repro.track("addCart", new HashMap<String, Object>() {{
put("product_id", "abc123");
}});
ReproCpp::trackWithProperties("addCart", R"({ "product_id": "abc123" })"); /* Raw string literals, same with {\"product_id\": \"3\"} */
Repro.TrackWithProperties ("addCart", "{\"product_id\": \"abc123\"}");
Repro.trackWithProperties("addCart", "{\"product_id\": \"abc123\"}");
Repro.track("addCart", { product_id: "abc123" });
repro.track("addCart", { product_id: "abc123" });
await Repro.track("addCart", { "product_id": "abc123" });