Skip to main content
Every failure the SDK reports — from any module — arrives as a ProviewError through the global Proview.onError handler.

The error object

Error types

Severity is decided per occurrence, so the same code can arrive as critical in one situation and warning in another. Read type on every error rather than assuming a fixed severity per code.

Error codes

The playback module raises its own codes instead of these — see Playback → Errors.

Session

API

Authentication

Resource

Configuration

Known messages

The SDK ships fixed message strings for the codes below. For the remaining codes the message comes from the underlying failure — an API response body, a network error — rather than from this catalogue.
These strings are for reading logs. Do not compare against them in code: wording can change in any release, and a message check that silently stops matching is very hard to spot. Use code, which is stable.

Validation errors

When a configuration object fails schema validation, the SDK attaches validationErrors:
validationErrors is a single object, not an array.

Handling errors

Register one handler before Proview.init(), then switch on code:
Proview.onError supports a single handler — registering a new one replaces the previous. If several parts of your app need to react to SDK errors, fan out from inside one handler rather than calling onError again.
Errors thrown inside your own callbacks are swallowed by the SDK so they cannot disrupt core functionality — they do not reach onError. Wrap callback bodies in their own try/catch. See Best Practices.