Skip to main content

Function: xtlError()

function xtlError(code, message): XtlError;

Defined in: src/error-codes.ts:72

Construct an Error with a stable code (ADR-0015). Hosts dispatch on error.code for localization and programmatic handling; the English error.message remains the conformance-corpus contract.

Parameters

ParameterType
codeXtlErrorCode
messagestring

Returns

XtlError

Stable

Frozen at 1.0 per spec/STABILITY.md "Public API surface".