Cast Events

This API call allows a developer to listen for cast events.


.on('cast')

Triggered when a cast property changes

{
  "available": true,
  "active": true,
  "deviceName": "ViewerTV",
  "type": "cast"
}
ValueDescription
active booleanIndicates that casting has started (true) or has stopped (false)
available booleanIndicates a device is (true) or is not (false) available for casting

When a device is available to be cast to, the cast icon appears in the player control bar.
deviceName stringName that the viewer assigns to device (receiver)

This property is only populated when "cast.active": "true".
type stringCategory of player event

This is always cast for this event.