Skip to main content

API Reference

Overview​

This API Reference provides detailed information on all SDK methods and resources. The methods are organized by Core SDK and Maestro Event Interface.

Core SDK​

The Core SDK provides the fundamental methods and fields for initializing and configuring the Maestro Roku SDK. These methods and fields serve as the entry point for integrating the SDK into your Roku application and allow you to configure behavior, manage event lifecycles, and control the panel.

Configurable Fields​

These fields are set by the client application to control SDK behavior:

FieldTypeDescription
configassocArrayPrimary configuration object; triggers Maestro config fetch
configurationassocArrayPasses runtime configuration to SDK panels, overriding server-side defaults
displayQRCodesbooleanEnables/disables QR code display
fetchDataOnInitbooleanFetch panel data on load (default: true)
handleLoadingSceneActionstringCommunicates loading actions to your app
heightintegerPanel height; alias of panelManagerView.height
sendTestOverlaystring"fantasy" or "bet" triggers an overlay test event
setDataToPanelassocArrayPushes external data into panel (depends on panel type)
userDidStartWatchingEventstringUsed when user switches content; triggers new panel session
userSettingsassocArrayOverride default panel/overlay/user behavior
widthintegerPanel width; alias of panelManagerView.width

Public Functions​

FunctionDescription
destroySDK()Clean teardown; removes all listeners
fetchMaestroModule()Returns configured SDK overlay modules for mounting in the host scene
dismissOverlay()Dismisses the visible overlay; fires did-dismiss and restores focus
getDataFromPanel()Returns panel data (polling model)
onPlayerTimeCodeUpdated()Passes player timecode to SDK
setConfiguration()Applies runtime configuration to SDK panels
restartSDK()Destroys and re-initializes the SDK without removing the node
setPanelFocus()Moves Roku focus into the panel

Maestro Event Interface​

The Maestro Event Interface defines observable fields that your application can monitor to respond to SDK events and state changes. These fields allow you to track panel visibility, user interactions, and error conditions.

Panel Management​

These fields allow you to monitor panel visibility and user interactions:

FieldTypeDescription
focusedTabItemintegerCurrent tab index
onOverlayEventassocArrayOverlay lifecycle events (will-appear, did-appear, did-engage, did-dismiss)
onPanelEventassocArrayPanel-specific events
panelOpenedThroughOverlaybooleanSpecial state: overlay → panel transition
panelsBuiltbooleanFires when the SDK finishes building panels; signal to call fetchMaestroModule()
shouldShowPanelbooleanPanel visibility recommendation
userViewedPanelassocArrayEmits panel name when opened

State & Tracking​

These fields allow you to monitor SDK state, errors, and analytics:

FieldTypeDescription
errorInformationassocArrayError reporting from SDK
lastDataReceivedassocArrayLiveness signal for the live data poll
isReadybooleanSDK initialization state
trackingEventassocArrayDetailed analytics event stream
userRequestedLoginbooleanUser tapped "Login" button

Overlay Events​

These fields allow your application to monitor and control the overlay display lifecycle:

FieldTypeDescription
onOverlayEventassocArrayOverlay lifecycle events: will-appear, did-appear, did-engage, did-dismiss
setDataToOverlayassocArrayGrant or deny overlay appearance in response to will-appear

Client Action Fields​

These fields allow your application to trigger actions in the SDK:

FieldTypeDescription
openToPanelstringOpen panel by name ("keyplays", "fantasy", "stats", etc.)
setDataToOverlayassocArrayGrant or deny overlay display and focus in response to will-appear events
showPanelbooleanShow/hide the Maestro panel