BrightcoveDataCollectionConfig

data class BrightcoveDataCollectionConfig(val accountId: Long, val videoId: String, val videoName: String? = null, val sessionId: String? = null, val engagementEventInterval: Int? = DEFAULT_ENGAGEMENT_INTERVAL_MS, val userId: String? = null, val deviceType: String? = null, val deviceOs: String? = null, val deviceOsVersion: String? = null, val deviceManufacturer: String? = null, val deviceModel: String? = null, val country: String? = null, val countryName: String? = null, val region: String? = null, val regionName: String? = null, val city: String? = null, val dma: String? = null, val destination: String? = null, val source: String? = null, val playerId: String? = null, val playerName: String? = null, val application: String? = null, val debugLogging: Boolean = false, val includeQoEMetrics: Boolean = false)

Configuration for Brightcove Data Collection API v2 integration.

This configuration enables optional tracking of playback QoE metrics and events to the Brightcove analytics platform. When provided, the player will automatically report metrics such as video views, engagement, buffering, and errors.

See also

Constructors

Link copied to clipboard
constructor(accountId: Long, videoId: String, videoName: String? = null, sessionId: String? = null, engagementEventInterval: Int? = DEFAULT_ENGAGEMENT_INTERVAL_MS, userId: String? = null, deviceType: String? = null, deviceOs: String? = null, deviceOsVersion: String? = null, deviceManufacturer: String? = null, deviceModel: String? = null, country: String? = null, countryName: String? = null, region: String? = null, regionName: String? = null, city: String? = null, dma: String? = null, destination: String? = null, source: String? = null, playerId: String? = null, playerName: String? = null, application: String? = null, debugLogging: Boolean = false, includeQoEMetrics: Boolean = false)

Properties

Link copied to clipboard

Brightcove Video Cloud account ID (required). This is the numeric account ID used to identify the account in the Data Collection API.

Link copied to clipboard
val application: String? = null

Custom application identifier (optional). Can be used to identify the application using the player.

Link copied to clipboard
val city: String? = null

City name (optional).

Link copied to clipboard
val country: String? = null

ISO-3166 alpha-2 country code (optional). Example: "US", "GB", "DE".

Link copied to clipboard
val countryName: String? = null

Human-readable country name (optional). Example: "United States", "United Kingdom".

Link copied to clipboard
val debugLogging: Boolean = false

Enable debug logging (optional). Default: false. When true, additional logging is output for troubleshooting.

Link copied to clipboard
val destination: String? = null

Current page URL / deep-link destination (optional). Used to track where the video is being played.

Link copied to clipboard

Device manufacturer (optional). Example: "Apple", "Samsung", "Sony", etc.

Link copied to clipboard
val deviceModel: String? = null

Device model (optional). Example: "Pixel 8", "Galaxy S24", "Fire TV Stick", etc.

Link copied to clipboard
val deviceOs: String? = null

Operating system override (optional). Overrides automatic OS detection. Supported values: "android", "ios", "linux", "mac", "windows", "tv", etc.

Link copied to clipboard
val deviceOsVersion: String? = null

OS version (optional). Example: "14.5", "11", etc.

Link copied to clipboard
val deviceType: String? = null

Device type override (optional). Overrides automatic device detection. Supported values: "mobile", "tablet", "tv", "desktop", "other".

Link copied to clipboard
val dma: String? = null

DMA code (optional). Designated Market Area code for US locations.

Link copied to clipboard

Interval in milliseconds between video engagement events (optional). Default: 10000 (10 seconds). Recommended range: 5000–20000 ms. Note: Engagement ranges must not exceed 20 seconds, otherwise events will be discarded by Brightcove Analytics.

Link copied to clipboard

Include QoE (Quality of Experience) metrics in video_engagement events (optional). Default: false. When false, video_engagement events are still sent (mandatory) but WITHOUT optional QoE metrics. When true, includes optional QoE metrics like rendition details, dropped frames, bandwidth, etc. Note: Collecting QoE metrics may impact performance on low-end devices (LG, Tizen, Vizio).

Link copied to clipboard
val playerId: String? = null

Player ID (optional). Custom identifier for the player instance.

Link copied to clipboard
val playerName: String? = null

Player name (optional). Human-readable name for the player.

Link copied to clipboard
val region: String? = null

ISO-3166 alpha-2 region code (optional). Example: "CA" (California), "NY" (New York).

Link copied to clipboard
val regionName: String? = null

Human-readable region name (optional). Example: "California", "New York".

Link copied to clipboard
val sessionId: String? = null

Unique session identifier (optional). If not provided, a UUID will be generated automatically. Session ID must be globally unique to prevent data collisions. Format recommendation: accountId_timestamp or standard UUID v4.

Link copied to clipboard
val source: String? = null

Referring page URL / source (optional). Typically the previous screen or entry point that led the user to this video.

Link copied to clipboard
val userId: String? = null

Unique user identifier (optional). Should be hashed with SHA-256 for privacy. If not provided, the API falls back to IP + User-Agent hashing.

Link copied to clipboard

Video Cloud video ID (required). The unique identifier for the video being tracked.

Link copied to clipboard
val videoName: String? = null

Human-readable name of the video (optional). Used for identification in analytics reports.