Skip to main content

Device Targeting

The tvlabs:constraints capability provides a powerful way to target your test scripts to specific devices on the TV Labs platform. It supports two formats: Kibana Query Language (KQL) query strings and key-value objects.

Constraint Query​

info

For more information about Kibana Query Language, see the Elastic documentation.

For a query to be valid, the platform_key must be unambiguous. If multiple platform keys could match the query, the request will fail.

A valid query must not:

  • Use a glob pattern for a platform key e.g. platform_key:*os
  • Be contained in a list of values e.g. platform_key:(tizen or web_os)
  • Contain an OR condition that can evaluate to multiple platform keys e.g. platform_key:android_tv and make:nvidia or platform_key:roku
  • Contain a NOT condition for a platform key e.g. not platform_key:web_os

Available Fields​

FieldDescriptionSupported ComparisonsSupports Glob Pattern
platform_keyAn unambiguous platform key (see available values in the Platforms section):No
makeThe device manufacturer (e.g., Samsung):Yes
device_typeThe device type (tv, stb, or mobile):Yes
modelThe device model (e.g., Express 4K+):Yes
yearThe device model year (e.g., 2024): < > <= >=Yes
platform_os_variantThe platform OS variant (e.g., fire_tv):Yes
chromedriver_versionThe ChromeDriver version (e.g., 76.0.0.0): < > <= >=Yes
account_regionThe Teleport region of the device's logged in account:Yes
version fieldAny of the platform's version fields below (e.g., os_version, chromium_version): < > <= >=Yes
platform_os_version(Deprecated) The platform's OS version. Use the platform's own OS version field below instead (e.g., platform_version on Tizen): < > <= >=Yes

Version Fields​

Every software version a device reports can be targeted by name. Which fields exist depends on the platform, and a query naming a field its platform does not report is rejected with the list of fields that platform does report.

Comparisons (< > <= >=) work against however many dotted numeric components the device reports and the query provides. Both sides are compared component by component after padding the shorter one with zeros, so os_version>=8.0 matches a device reporting 8.0.1 and os_version<8.1 excludes it, the same way 8.0.0/8.1.0 would. The same holds for chromium_version, which always has four: chromium_version>=108 asks for 108.0.0.0. Letters are ignored, so a webOS device reporting webOSTV 6.0 matches os_version>=6. Equality (:) and glob patterns match the reported string as written.

A version with no digits at all can only be matched exactly, ignoring case: yocto_version:"kirkstone" matches a device reporting kirkstone, while yocto_version>=kirkstone matches nothing.

The first field in each table is the platform's OS version, which platform_os_version used to name.

Tizen (tizen)​

FieldDescriptionExample
platform_versionThe Tizen platform version8.0
platform_build_versionThe Tizen platform build20230929.1
product_versionThe TV's product software version3.1.0
sdbd_versionThe SDB daemon version2.2.31
sdbd_cap_versionThe SDB capability protocol version1.0
sdbd_plugin_versionThe SDB plugin version3.9.7
chromium_versionThe Chromium the TV's web runtime is built on94.0.4606.31
webkit_versionThe WebKit version the TV's web runtime reports537.36

webOS (web_os)​

FieldDescriptionExample
os_versionThe webOS product versionwebOSTV 6.0
firmware_versionThe TV firmware version23.20.50
chromium_versionThe Chromium the TV's web runtime is built on87.0.4280.22
webkit_versionThe WebKit version the TV's web runtime reports537.36

Android TV and Android mobile (android_tv, android_mobile)​

FieldDescriptionExample
android_versionThe Android release12
api_versionThe Android API level32
security_patchThe security patch level2024-01-05
build_idThe build IDSTTL.240206.002
build_display_idThe build ID as shown in settingsSTTL.240206.002.A1
build_incrementalThe incremental build number11407591
build_fingerprintThe full build fingerprintgoogle/sabrina/...
fire_versionThe Fire OS version (Fire TV only)7.6.9.4
fire_build_nameThe Fire OS build name (Fire TV only)PS7694
fire_os_majorThe Fire OS major version (Fire TV only)7
fire_build_numberThe Fire OS build number (Fire TV only)0006
fire_build_serialThe Fire OS build serial (Fire TV only)20240223
shield_experience_versionThe Shield Experience version (NVIDIA Shield only)9.1.1
chromium_versionThe Chromium version of the installed WebView138.0.7204.244

Roku (roku)​

FieldDescriptionExample
software_versionThe Roku OS version14.1.4
software_buildThe Roku OS build5217
build_numberThe full build number14.1.4.5217
lightning_base_build_numberThe Lightning base build number14.1.4.5217
ui_software_versionThe UI software version14.1.4
ui_software_buildThe UI software build5217
ui_build_numberThe UI build number14.1.4.5217
grandcentral_versionThe Grand Central version10.1.34
brightscript_debugger_versionThe BrightScript debugger protocol version3.3.0
trc_versionThe TRC version (devices that support TRC)3.0
trc_channel_versionThe TRC channel version (devices that support TRC)4.1.5

Vizio SmartCast (smartcast)​

FieldDescriptionExample
os_versionThe SmartCast OS version4.20.10.1
firmware_versionThe TV firmware version4.20.10.1
conjure_versionThe Conjure API version3.1.0
scpl_versionThe SCPL version1.0.6
cast_versionThe Chromecast built-in version1.56.500000
airplay_versionThe AirPlay version2.0
apple_tv_versionThe Apple TV app version1.6.6
bluetooth_versionThe Bluetooth stack version5.0
vizio_ndk_versionThe Vizio NDK version2.3.0
sc_config_versionThe SmartCast configuration version20240110
chromium_versionThe Chromium the TV's web runtime is built on105.0.5195.68
webkit_versionThe WebKit version the TV's web runtime reports537.36

Apple TV (tv_os) and iOS (ios)​

FieldDescriptionExample
os_versionThe tvOS or iOS version17.4
os_buildThe OS build21L227

Amazon Vega (vega)​

FieldDescriptionExample
os_versionThe Vega OS version1.2
software_versionThe device software version1.2.0.4
build_fingerprintThe full build fingerprintamazon/...
kernel_versionThe Linux kernel version5.15.41
oe_versionThe OpenEmbedded release4.0.12
release_idThe release ID20240501
branch_codeThe build branch code1.2
build_dateThe build date20240501

Entertainment OS (Sky and Xumo)​

FieldDescriptionExample
rdk_versionThe RDK release8.6p3s1
yocto_versionThe Yocto releasekirkstone
sky_versionThe Sky firmware buildQSE042.003.00U
branchThe build branchsupport_8.6
image_nameThe firmware image nameSKTL21MEI_E042.003.00.8.6p3s1_DEV
wpe_webkit_versionThe WPE WebKit release2.38.8+gitAUTOINC+680d0afd32-r12.1
as_versionThe application services versionRDK8.6.00.315.7
mw_versionThe middleware version8.6p3s1
network_versionThe network stack version2.00
version_numberThe box's version code32C00A
apps_service_gatewaydThe apps service gateway version85.3.0
as_analytics_service_tagThe analytics service tagAS_ANALYTICS_RDK8.6.69.3
as_apps_service_tagThe apps service tag85.3.0
as_network_service_tagThe network service tagNETWORK_REL_RDK8.6.99.1
as_peripherals_tagThe peripherals service tagAS_PERIPHERALS_RDK8.6.76.1
as_player_tagThe player service tagAS_PLAYER_REL_RDK8.6.288.3
as_proxy_service_tagThe proxy service tagAS_PROXY_REL_000.181
as_system_service_tagThe system service tagAS_SYSTEM_REL_RDK8.6.308.7
as_voice_service_tagThe voice search service tagAS_VOICE_SEARCH_RDK8.6.86.1
jspp_tagThe JSPP tag1.47.7
lib_as_service_tagThe application services library tagAS_LIB_SERVICE_REL_RDK8.6.124.1
mw_local_store_tagThe middleware local store tagSKY_MWLOCALSTORE_000.21

Examples​

Device Targeting​

Target any webOS device with version 8.0 or higher, and model starting with C or UT but excluding model C1PUB:

platform_key:web_os
AND os_version>=8.0
AND model:(C* OR UT*)
AND NOT model:C1PUB

Target any Tizen device whose web runtime is Chromium 94 or newer:

platform_key:tizen
AND chromium_version>=94.0.0.0

Target any Roku on Roku OS 14 that supports TRC:

platform_key:roku
AND software_version>=14
AND trc_version:*

Target any Vizio V-series device newer than 2021:

platform_key:vizio
AND model:V*
AND year>2021

Target Roku devices not manufactured by Roku:

platform_key:roku
AND NOT make:Roku

Target any Android TV device that is a physical television (not a set-top box):

platform_key:android_tv
AND device_type:tv

Target any Tizen device that supports ChromeDriver:

platform_key:tizen
AND chromedriver_version:*

Escaping Special Characters​

Unquoted values must escape \():<>"* characters. Every character will be treated as a literal in quoted values.

Target a value with spaces in the value:

platform_key:android_tv
AND model:"Fire TV Stick 4K MAX"

Alternatively, the spaces may be escaped without quoting the value:

platform_key:android_tv
AND model:Fire\ TV\ Stick\ 4K\ MAX
info

Targeting one of your organization's own devices directly? See Dedicated Devices.

Narrow constraints take longer to fill. See Device Fulfillment for how requests are matched and how to get a specific variant faster.

Tags​

Some devices are reserved behind a tag. A tagged device only accepts sessions whose tvlabs:constraints capability opts into that tag with a tag:<slug> term. Leave the tag out and your request will never match those devices, so access is opt-in rather than something you fall into by accident.

Rules for tag:<slug> terms:

  • The query must also constrain platform_key. A tag term with no platform key is rejected.
  • Only equality is supported (tag:test-flight). Glob patterns, lists, OR, and NOT are not.
  • Combine multiple tags with AND. The device must carry every tag you list.

Target devices reserved under test-flight on webOS:

platform_key:web_os
AND tag:test-flight

Target devices reserved under both test-flight and beta:

platform_key:web_os
AND tag:test-flight
AND tag:beta

Legacy Constraints​

An alternative constraint format uses key-value objects instead of query strings.

Example tvlabs:constraints capability to target any webOS device on webOS 6 or higher that supports ChromeDriver version 76 or higher:

{
platform_key: 'web_os',
version_requirements: { os_version: '>= 6.0' },
chromedriver_requirement: '>= 76.0.0.0'
}

Available Fields​

KeyDescription
platform_keyRequired. The platform key of the device (see available values in the Platforms section)
makeThe device manufacturer (e.g., Samsung)
device_typeThe device type (tv, stb, or mobile)
modelThe device model (e.g., Express 4K+)
yearThe device model year (e.g., 2024)
version_requirementsAn object of version field to requirement (e.g., { os_version: '>= 6.0', chromium_version: '>= 87.0.0.0' }). Requirements combine clauses with and/or (e.g., >= 6.0 and < 8.0)
platform_os_requirement(Deprecated) The platform OS version requirement (e.g., >= 10.0.0). Use version_requirements with the platform's OS version field instead
platform_os_variantThe platform OS variant (e.g., fire_tv)
chromedriver_requirement(Deprecated) The ChromeDriver version requirement (e.g., >= 76). Use the constraint query's chromedriver_version instead
supports_chromedriverWhether the device supports ChromeDriver
minimum_chromedriver_major_version(Deprecated) The minimum major version of ChromeDriver
tagsAn array of tag slugs opting into reserved devices (e.g. ['test-flight']). See Tags above