Data Integration
Call to Action
Educational Apps
6min
view item when the user needs to be taken to a particular screen/tab of the app properties key value description actiontype view item type of action to be performed item item docid\ xyfflvav fzf01nmc2zn the object of the item which holds itemid, name it is similar to an item sent via view item docid 3azoy3cgtezkrgmnm9jl5 event or via cms code example function oncooeectalistener(payload) { if (!payload) { return; } if (payload get("actiontype") == "view item") { const item = payload get("item"); // show given item to the user } } ts function oncooeectalistener(payload) { if (!payload) { return; } if (payload\["actiontype"] == "view item") { const item = payload\["item"]; // show given item to the user } }void oncooeectalistener(hashmap\<string, object> payload) { if (payload == null) { return; } if (payload get("actiontype") == "view item") { map\<string,object> item = (map\<string,object>) payload get("item"); // show given item to the user } }fun oncooeectalistener(payload hashmap\<string, any>) { if (payload == null) { return; } if (payload\["actiontype"] == "view item") { val item = payload\["item"] as map\<string, any>; // show given item to the user } } (void) oncooeectaresponsewithpayload (nsdictionary\<nsstring ,id> )payload { if (payload count == 0) { return; } if (\[payload\[@"actiontype"] isequal @"view item"]) { nsdictionary item = payload\[@"item"]; // show given item to the user } }func oncooeectalistener(payload \[string any]) { if (payload isempty) { return } if (payload\["actiontype"] == "view item") { let item = payload\["item"] as \[string any] // show given item to the user } } dart void inapptriggered(map\<string, dynamic> payload) { if(payload == null) { return; } if (map\["actiontype"] == "view item") { var item = payload\["item"]; // show given item to the user } } } play item when a particular course needs to be played users should be first taken to the view page of the course (if available) the app should handle edge cases for example the user is allowed to view the course wrong course id properties key value description actiontype play item type of action to be performed item item docid\ xyfflvav fzf01nmc2zn the object of the item which holds itemid, name it is similar to an item sent via view item docid 3azoy3cgtezkrgmnm9jl5 event or via cms code example function oncooeectalistener(payload) { if (!payload) { return; } if (payload get("actiontype") == "play item") { const item = payload get("item"); // play given item to the user } } ts function oncooeectalistener(payload) { if (!payload) { return; } if (payload\["actiontype"] == "play item") { const item = payload\["item"]; // play given item to the user } }void oncooeectalistener(hashmap\<string, object> payload) { if (payload == null) { return; } if (payload get("actiontype") == "play item") { map\<string,object> item = (map\<string,object>) payload get("item"); // play given item to the user } }fun oncooeectalistener(payload hashmap\<string, any>) { if (payload == null) { return; } if (payload\["actiontype"] == "play item") { val item = payload\["item"] as map\<string, any>; // play given item to the user } } (void) oncooeectaresponsewithpayload (nsdictionary\<nsstring ,id> )payload { if (payload count == 0) { return; } if (\[payload\[@"actiontype"] isequal @"play item"]) { nsdictionary item = payload\[@"item"]; // play given item to the user } }func oncooeectalistener(payload \[string any]) { if (payload isempty) { return } if (payload\["actiontype"] == "play item") { let item = payload\["item"] as \[string any] // play given item to the user } } dart void inapptriggered(map\<string, dynamic> payload) { if(payload == null) { return; } if (map\["actiontype"] == "play item") { var item = payload\["item"]; // play given item to the user } } }