Conviva Device Metadata
Conviva Device Metadata is used to provide additional information about the device that is used to play the video. This information is used by Conviva to provide better analytics and insights.
These parameters can be used for example to override the OS name and version in those cases where Conviva fails to detect the correct values.
customDeviceMetadata: () => ConvivaDeviceMetadata;
export interface ConvivaDeviceMetadata {
DeviceBrand?: string;
DeviceManufacturer?: string;
DeviceModel?: string;
DeviceType?: ConvivaDeviceType;
DeviceVersion?: string;
OperatingSystemName?: string;
OperatingSystemVersion?: string;
DeviceCategory?: ConvivaDeviceCategory;
ScreenWidth?: number;
ScreenHeight?: number;
ScaleFactor?: number;
}
export const ConvivaDeviceCategory = {
// Device Categories
ANDROID_DEVICE: 'AND',
APPLE_DEVICE: 'APL',
CHROMECAST: 'CHR',
DESKTOP_APP: 'DSKAPP',
DEVICE_SIMULATOR: 'SIMULATOR',
KAIOS_DEVICE: 'KAIOS',
LG_TV: 'LGTV',
NINTENDO: 'NINTENDO',
PLAYSTATION: 'PS',
ROKU: 'RK',
SAMSUNG_TV: 'SAMSUNGTV',
SET_TOP_BOX: 'STB',
SMART_TV: 'TV',
TIVO: 'TIVO',
WEB: 'WEB',
WINDOWS_DEVICE: 'WIN',
XBOX: 'XB',
} as const;
export type ConvivaDeviceCategory = (typeof ConvivaDeviceCategory)[keyof typeof ConvivaDeviceCategory];
export const ConvivaDeviceType = {
CONSOLE: 'Console',
DESKTOP: 'DESKTOP',
MOBILE: 'Mobile',
SETTOP: 'Settop',
SMARTTV: 'SmartTV',
TABLET: 'Tablet',
} as const;
export type ConvivaDeviceType = (typeof ConvivaDeviceType)[keyof typeof ConvivaDeviceType];
Usage example where the device metadata is set to a specific LG TV version​
export const mediaAnalyticsParam: BoAdapterWebTvProps['mediaAnalyticsParam']= {
userName: 'exampleUserName', // your values
viewerId: 'DivaUser', // your values
cdnName: 'AKAMAI', // your values
playerVersion: version, // your values
customDeviceMetadata: () => ({
DeviceBrand: 'Apple',
DeviceManufacturer: 'Apple',
DeviceModel: 'MacBookPro',
DeviceType: 'SmartTV',
OperatingSystemName: 'WEBOS',
OperatingSystemVersion: '6.2',
DeviceCategory: 'LGTV',
}),
};