Datazoom is a high-availability real-time data collection solution. This document summarizes how to integrate the IVS Player video player with the Datazoom platform.
Login to Datazoom here: https://app.datazoom.io
Add a Collector as indicated here: How to add a Collector
Copy the CONFIG ID
to be used in the subsequent steps
Plugin Integration
Datazoom provides plugins for data collection through our Beacon Services. Integrate the IVS Player plugin into your web application with the following snippet:
<script src='https://platform.datazoom.io/beacon/v1/config?configuration_id=CONFIG_ID'></script>
Insert this JS line into your HTML
Replace the CONFIG_ID value with collector configuration ID.
This inserts Datazoom's data collection SDK into the page.
Activate Data Collection for an IVS Player
To activate data collection for an IVS player instance, create a Datazoom context which references the player instance with the following snippet:
datazoom_context = datazoom.createContext(player);
For example:
<html> <head> <script src="https://player.ivideosmart.com/ivsplayer/v4/dist/js/loader.js"></script> <script src='https://platform.datazoom.io/beacon/v1/config?configuration_id=CONFIG_ID'></script> </head> <body> <div id="ivsplayer01-container"> <ivs-player id="ivsplayer01" data-ivs-key="<customer api key>" data-ivs-spid="<service provider id>" data-ivs-vid="<video id>"> </ivs-player> </div> <script> var ivs_player; var datazoom_context; document.addEventListener('ivs.player.rendered', function (event) { ivs_player = event.detail.instance; datazoom_context = datazoom.createContext(ivs_player); }); </script> </body> </html>
Stop Data Collection
If the data collection must be stopped for any reason, invoke the destroy()
method of the Datazoom context object as in the following example:
if (datazoom_context) { datazoom_context.destroy(); datazoom_context = null; }
NPM (Node Package Manager)
We have made it convenient to manage your IVS Collector integration by providing NPM (Node Package Manager) support. Please see installation details here.
References
IVS Player SDK Manual: https://ivideosmart.zendesk.com/hc/en-us/articles/360041163474-User-Manual-for-iVideoSmart-IVS-Player-SDK-for-HTML5
Comments
0 comments
Article is closed for comments.