Media Stream Analytics by connecting the APIs of Adobe Experience Cloud

Registering the visitor with Adobe AnalyticsSending the above obtained visitor id (mid) and the Org Id to the Analytics tracking server, would suffice in registering the visitor in the Analytics servers. However for debugging purpose, it is advised to add few more custom variables in the Query String ParameterWhen to trigger: At page or screen load complete.Key components of the request would look like:3. Streaming events in to the Heartbeat API serverAs of the above two steps, we have established a visitor being identified in the Analytics server. Now we would be sending the heartbeat stream events to the heartbeat api server which would server-side forward to the analytics server. As mentioned previously, the Visitor ID will be the primary connecting key between the Analytics server and the Heartbeat server.There are several stream events for the Heartbeat tracking server. This blog would cover the essential events that are required for tracking a complete media playback. Post practicing these handson, you would be equipped with enough knowledge on how to implement the rest. List of events covered:sessionStart — Initiates a heartbeat/media stream session at heartbeat serverplay — Sets the event for start of a media contentping — HeartbeatspauseStart — Sets the event for pausing the media contentsessionEnd — Sets the event for completion of a media contentsessionComplete — Compelte the heartbeat/media stream sessionAll these events are sent to the heartbeat tracking server, which appears similar to the analytics tracking server, except the “.sc.” would be replaced by “.d2.hb-api”, which points to the heartbeat api tracking server. Example:Analytics server = API server = abc123corp.d2.hb-api.omtrdc.netKnowledge of the Media player api would be essential for this step. For example a HTML5 player would emit the following events via its API: It is necessary for the platform developer to tap into these events using the event listener of the platforms.Now let’s start sending the stream events to the heartbeat serverWhen to set sessionStart: Begin of a media playback engagementKey Components for the sessionStart API request:For the subsequent events, it is suggested to develop an OOPS function which would scale across all the media events and send the API request. The subsequent api request have a similar api request json formatWhen to set play event: Start of the media playbackKey Components for the play event:When to set ping event: Once in every 10 second would be ideal for main media content streaming and when the media playback resumes from a pause start or buffering state.Key components of the ping event:When to set the pauseStart event: The media playback is pausedKey Components of the pause event:When to set the sessionEnd event: The media playback endsKey Components of the sessionEnd event:When to set the sessionComplete event: The visitor moved to different page or screen of the experienceKey components of the sessionComplete event:Validation of the ImplementationOn successful implementation of the above apis in the mentioned order and manner, the Analytics server will merge the summarized table sent from the heartbeat server. This is a server side forward mechanism. In order to validate this implementation, Analysis workspace and the afore mentioned Adobe Analytics variables would be helpful.A recap on the data being sent:Visitor ID and behaviour data are sent to Adobe Analytics serverVisitor ID and Media Events are sent to Heartbeat Analytics serverWe should be able to breakdown Visitor ID variable from Analytics server Hits with Media Name Variable from the Heartbeat server hits and appropriate metrics like Media Initiates, Plays , Pauses etc.. would be reported in the breakdown. This would mark the success of the implementation. Mission Accomplished !!!ConclusionAs mentioned in the Introduction, this a humble effort 🙂 and looking forward to experts in the Adobe Analytics World to come up with better versions and media application.The essentials in implementing an API-only Media Analytics framework, would be the knowledge of the Adobe APIs, the platform libraries and the Media Player events.There will be new media experiences like VR, Fitness Bands, TV stick etc….that are coming up and it might not be scalable to rely on the SDKs from the Analytics Platforms..It would be beneficial for Adobe Analytics strategist to leverage APIs for onboarding data from the new platforms.Hope this blog helps you gaining confidence in experimenting with the API-only Media Analytics Implementation.. More details

Leave a Reply