Gets the user presence. The service must implement this method to retrieve the user presence live data. When data is updated from ayoba, then ayoba calls this javascript method on service to pass the new data
onPresenceChanged(presence)
function onPresenceChanged(presence) {
currentPresence = presence
}
Gets the user nickname. The service must implement this method to retrieve the user nickname live data. When data is updated from ayoba, then ayoba calls this javascript method on service to pass the new data
function onNicknameChanged(nickname) {
currentNickname = nickname
}
Gets the user avatar. The service must implement this method to retrieve the user avatar live data. When data is updated from ayoba, then ayoba calls this javascript method on service to pass the new data
onAvatarChanged(avatar)
function onAvatarChanged(avatar) {
currentAvatarPath = avatarPath
}
Gets the user language code in ISO-639-1
Ayoba.getLanguage()
var languageCode = Ayoba.getLanguage();
Send a generic event to Firebase Analytics.
function sendGenericEvent(eventNumber, description) {
Ayoba.sendGenericEvent(eventNumber, description);
}
<script type="text/javascript">
Ayoba.sendGenericEvent(1, "Generic Event Number 2"); // This will send an event called "genericEvent2"
</script>
That’s all to read on the Events documents. Continue to learn more about our APIs, next is some documentation on our Payment APIs
Previous
Media
Next
Payment Process