CONNECT Player SDK 5 for Browsers and Connected TV

Error reporting

If required, errors can be reported from the SDK player engine to a listener function in your Application layer. The function signature needs to be as follows:

JavaScript
function onErrorCallback(
	errorSeverity,
	errorCategory,
	errorCode,
	errorMessage
) {
	// functionality to be implemented by the integrator
}

The listener function name should be passed to the SDK via a call through otvtoolkit to setErrorListener() on the exposed errorReporting component as follows:

JavaScript
window.player.otvtoolkit().errorReporting.setErrorListener({
	errorChanged: onErrorCallback
});