Monitor THEOPlayer
The FastPix Data SDK with THEOplayer helps you track key video metrics like user interactions, playback quality, and performance to enhance the viewing experience. It lets you customize data tracking, monitor streaming quality, and securely send insights for better optimization and error resolution.
Key features:
- Capture user engagement through detailed viewer interaction data.
- Monitor playback quality with real-time performance analysis.
- Identify and fix video delivery bottlenecks on Android.
- Customize tracking to match specific monitoring needs.
- Handle errors with robust reporting and diagnostics.
- Gain deep insights into video performance with streaming diagnostics.
Prerequisites:
To track and analyze video performance, initialize the SDK with your Workspace key. Learn about Workspaces.
- Access the FastPix Dashboard: Log in and navigate to the Workspaces section.
- Locate Your Workspace Key: Copy the Workspace Key for client-side monitoring. Include this key in your Java/Kotlin code on every page where you want to track video performance.
Install and setup
-
Open your Android Studio project where you want to integrate the SDK.
-
Add the FastPix Data SDK dependency:
-
Navigate to your app-level
build.gradlefile (orbuild.gradle.ktsif using Kotlin DSL).
Navigate to your settings.gradle file
- Sync your project with Gradle files
Click
Sync Nowin the notification bar to download and integrate the FastPix Data SDK.
Import the SDK
Basic Integration
1.Ensure that the workSpaceId is provided, as it is a mandatory field for FastPix integration, uniquely identifying your workspace. Install and import THEOplayer into your project, and create an theoplayer instance to bind it to. If you are using any other custom player then create an instance of that player.
- Next, create an instance of
FastPixBaseTheoPlayerto track analytics. After the video URL loads and playback begins, the SDK automatically begins tracking analytics.
- You can initialize THEOPlayer with a
THEOplayerViewin your Android application to enable seamless functionality. Use the following Kotlin or Java code in your Android application to configure ExoPlayer with FastPix:
Include custom data and metadata
workSpaceIdis a mandatory parameter that tells the SDK on which workspace the data will collect.playerViewis another mandatory parameter comingTHEOPlayerview.
- You can use custom metadata fields like
customField1tocustomField10for your business logic, giving you the flexibility to pass any required values. Named attributes, such asvideoIdandvideoTitle, can be passed directly as they are. See the user-passable metadata documentation to see the metadata supported by FastPix.
- To set up video analytics, create a FastPixBaseTheoPlayer object by providing the following parameters: your application’s
Context(usually the Activity), theTHEOPlayerinstance, and thecustomerData.
- Finally, when destroying the player, make sure to call the
FastPixBaseTheoPlayer.release()function to properly release resources.
- After completing the integration, start playing a video in your player. A few minutes after stopping playback, you’ll see the results in your FastPix Video Data dashboard. Log in to the dashboard, navigate to the workspace associated with your
workspaceId, and look for video views.
Understanding CustomerData
What FastPix Tracks
After initialization, the SDK automatically collects:
Example to configure THEOPlayer with FastPix Data SDK.
Provide your stream URL in the url field “https://example.com/video.m3u8” and your FastPix workspace key in the workspaceIdfield.
Debug Logging
Enable logs using:
Change logs
All notable changes to this project will be documented in this file.
[v0.3.0]
- Code standardization updates applied across the SDK to align with best practices and strengthen overall stability.
[v0.2.0]
- Updated iOS Data Core SDK by updating the SDK’s default metrics collection domain to improve endpoint reliability and alignment with current infrastructure.
[v0.1.0]
Added
-
Integration with THEOPlayer:
- Enabled video performance tracking using FastPix Data SDK, supporting user engagement metrics, playback quality monitoring, and real-time streaming diagnostics.
- Provides robust error management and reporting capabilities for video performance tracking.
- Includes support for custom metadata, enabling users to pass optional fields such as
video_id,video_title,video_duration, and more. - Introduced event tracking for
videoChangeto handle metadata updates during playback transitions.
Support
📩 Email: support@fastpix.io 📚 Docs: fastpix.com/docs