smartClientCore - Static API

The static API can be used to create and connect instances of the add-on with the video player. It is available from the global namespace on the window object.

Table of contents

Methods

connect(player : PlayerFacade) : smartClientCore

The video player calls smartClientCore.connect()

setup(pluginSetup : GlobalConfig) : Promise<PluginAPI>

Sets up a new add-on instance with the given configuration, as specified in Global Configuration. Returns the add-on API as a promise that resolves when the add-on has finished the setup.

Properties

EVENT: Object

Declaration of events as ENUMs that occur during playback of a single ad or mutliple ads delivery. See smartClientCore - Ad Events for more details.

EVENTS: Array

List of event names as defined in the EVENT object.

SCHEMA: Object

The SCHEMA Object introduces default schemes for frequently used Objects and methods that help creating and validating these. All SCHEMA definitions and helpers are accessible via the smartClientCore.SCHEMA Object.

Schemes

AD_BREAK : JSONSchema
Setup definition for a commercial break. Properties are described within section Sequential Config: Ad-Break.

GLOBAL_CONFIG : JSONSchema
Setup definition for the current session that is applied to all commercial breaks. Properties are described within section Global Config.

Helpers

validate(input : Object, schema : JSONSchema) : Boolean
Can be used to check the validity of Configuration Objects against a corresponding schema.

create(schema : JSONSchema) : Object
Returns a qualified Object for the given schema definition, filled with the expected default values.

supportedFacadeVersion: String

Returns the version number for the supported Facade interface.

AD_TYPE

Declaration of ad types as ENUMs that can be used with requesting an ad slot.