VO Player (Nowtilus SSAI)
Step by step guide for integrating the VO Player SDK with Nowtilus SSAI to a VO Player based Player Application
STEP 0
Please find the Sample reference application under
STEP 1
Add the following lines to access the SDK
In the Sample Application this is added in CustomPlayerActivity.java
STEP 2
startMediaMelonSDK() API calls all MediaMelon SDK Integration API's. To start MediaMelon SDK, please call startMediaMelonSDK() API.And register MediaMelon SDK using your assigned customerID in StartMediaMelonSDK() API. Please refer code block below.
Note:
Please provide the exact correct details in all fields like CUSTOMER_ID, ASSET_ID, ASSET_TITLE, VIDEO_ID, PLAYER_BRAND, PLAYER_MODEL, PLAYER_VERSION, PLAYER_NAME, DOMAIN_NAME, SUBSCRIBER_ID, SUBSCRIBER_TYPE & SUBSCRIBER_TAG. This data helps in debugging through MediaMelon SmartSight if anything goes wrong.
Parameters passed in Registration call
$PLAYERNAME
Player Name as in ExoPlayer, KalturaPlayer etc.
$CUSTOMERID
String containing your MediaMelon-assigned Customer ID.
$SUBSCRIBERID
String containing your subscriber’s ID. If you do not use subscriber IDs, leave it as it is.
$DOMAINNAME
String containing your section of your subscriber or assets. (Optional)
$SUBSCRIBERTYPE
String containing the subscriber type (e.g. “Free”, “Paid”). If you do not use subscriber types, leave it as it is.
$SUBSCRIBERTAG
String containing an additional subscriber-specific information. This is sent in clear (not hashed) to SmartSight and it is advised to not send sensitive information in this field.
STEP 3
Add the below lines following the registration to enable the Nowtilus SSAI Ad Manager in startMediaMelonSDK() API.
NOTE - boolean enablePollingforSSAI
variable indicates whether the Mediamelon SDK needs to poll for the VAST URL or not. Please set it to true if you want to opt for polling else set it to false.
For VOD Streams , set isLive Parameter false and stores AD information in vodResponseData and sends to NowtilusAdManager
Refer getURLDetails
function in the sample application to get the mediaURL and AD Data from the curl request for both live and VoD streams. If the stream is VoD, set the isLive
variable to false
. If the stream is Live, set the isLive
variable to true
.
STEP 4
Subscribe to AD EVENTS in startMediaMelonSDK() API. Please refer code block below
STEP 5
ADD API for stopping MediaMelon SDK.To stop MediaMelon SDK please call stopMediaMelonSDK(). Please refer code block below
STEP 6 : To Stop the SSAI Ad Manager
Report the player state has ENDED, when the player was destroyed
ADD closeSSAIAdManager() API in onDestroy() listener in CustomPlayerActivity.java
List of AD EVENTS
onAdImpression
Fired when an Ad Impression occurs
onAdStarted
Fired when Ad starts playing
onAdFirstQuartile
Fired when Ad playback reaches the First Quartile point
onAdMidpoint
Fired when Ad playback reaches the Midpoint
onAdThirdQuartile
Fired when Ad playback reaches the Third Quartile point
onAdProgress
Fired every second during Ad Playback, used to track Ad Playback progress
onAdComplete
Fired when Ad Playback completes
onCueTimelineAdded
Fired when an Ad break information gets added
onCueTimelineEnter
Fired when an Ad break ( which can contain multiple Ads) starts
onCueTimeLineExit
Fired when an Ad break ( which can contain multiple Ads) ends
Get Ad Related Information
You can use the below commands from inside any of the AD Events(listed above) that you subscribe to.
ssaiAdInfo.getTotalAds()
- returns aint
which signifies the number of Ads in the current Ad break.ssaiAdInfo.getClickTrackingURLs()
-returns the click tracking URLs as a List<String>.ssaiAdInfo.getClickThroughURLs()
-returns the clickthrough URLs as a List<String>.ssaiAdInfo.getAdSkipOffset()
- returns the AD offset inseconds.
ssaiAdInfo.getCompleteTrackers()
-
returns the AD Complete Tracking URLs as a List<String>.ssaiAdInfo.getMidpointTrackers()
-
returns the AD Midpoint Tracking URLs as a List<String>.ssaiAdInfo.getThirdQuartileTrackers()
-
returns the AD ThirdQuartile Tracking URLs as a List<String>.ssaiAdInfo.getFirstQuartileTrackers()
-
returns the AD FirstQuartile Tracking URLs as a List<String>.ssaiAdInfo.getImpressionTrackers()
-
returns the AD Impression URLs as a List<String>.ssaiAdInfo.getAdIndex()
-
returns the index of the current AD in the AD break.ssaiAdInfo.getStartPos()
-
returns the start position of the Ad Break relative to the first manifest program timessaiAdInfo.getEndPos()
-
returns the end position of the Ad Break relative to the first manifest program time
Last updated