Cubicle

CubicleError

The CubicleError class of @cubicle/sdk: its constructor, properties and methods.

Base class for every error the SDK raises. An aborted signal rejects with its reason.

The SDK raises CubicleError itself, rather than a subclass, for configuration and client-side problems: missing_api_url, missing_api_key, invalid_option, org_required and missing_result.

See

Errors and retries

Extends

  • Error

Extended by

Constructors

Constructor

new CubicleError(
   code, 
   message, 
   options?
): CubicleError;

Parameters

ParameterTypeDescription
codestringA stable machine-readable code, such as not_found or wait_timeout.
messagestring-
options?{ cause?: unknown; }-
options.cause?unknown-

Returns

CubicleError

Overrides

Error.constructor

Properties

PropertyModifierTypeDescription
cause?publicunknown-
codereadonlystringA stable machine-readable code, such as not_found or wait_timeout.
messagepublicstring-
namepublicstringAlways "CubicleError".
stack?publicstring-

On this page