/**
 * @module errors
 * Named error class hierarchy for xBind agent-sdk.
 *
 * These classes are supplementary — existing `Result<T, E>` string codes are
 * unchanged. Use `toXBindError()` to convert a string error code into a
 * class-based error for try/catch consumers.
 */
import type { ACIErrorDetail } from '@private.me/ux-helpers';
/** Base error class for all XBind errors. */
export declare class XBindError extends Error {
    /** Machine-readable error code matching the Result<T,E> string unions. */
    readonly code: string;
    /** Sub-code parsed from colon-separated codes (e.g. 'DECRYPTION' from 'DECRYPT_FAILED:DECRYPTION'). */
    readonly subCode?: string;
    /** URL to relevant documentation for this error. */
    readonly docUrl?: string;
    constructor(code: string, message: string, docUrl?: string);
}
/** Ed25519/X25519 identity errors (keygen, sign, verify, DID, import/export). */
export declare class XBindIdentityError extends XBindError {
    constructor(code: string, message: string);
}
/** Envelope creation, encryption, decryption, and parsing errors. */
export declare class XBindEnvelopeError extends XBindError {
    constructor(code: string, message: string);
}
/** Transport-layer errors (send failures, network, timeouts). */
export declare class XBindTransportError extends XBindError {
    constructor(code: string, message: string);
}
/** Trust registry errors (lookup, registration, revocation). */
export declare class XBindRegistryError extends XBindError {
    constructor(code: string, message: string);
}
/** X25519 ECDH key agreement errors. */
export declare class XBindKeyAgreementError extends XBindError {
    constructor(code: string, message: string);
}
/** XorIDA split-channel errors (split, reconstruct, HMAC, shares). */
export declare class XBindSplitChannelError extends XBindError {
    constructor(code: string, message: string);
}
/** High-level Agent errors (wraps subsystem errors with context). */
export declare class XBindAgentError extends XBindError {
    constructor(code: string, message: string);
}
/** Billing and payment errors (subscriptions, limits, verification). */
export declare class XBindBillingError extends XBindError {
    constructor(code: string, message: string);
}
/** Vault Store errors (Full Control IP protection, crypto loading). */
export declare class VaultStoreError extends XBindError {
    constructor(code: string, message: string);
}
/** Quota exceeded error (Free tier >120K hard cap). */
export declare class QuotaExceededError extends XBindBillingError {
    /** Upgrade URL for Pro tier */
    readonly upgradeUrl: string;
    constructor(code: string, message: string, upgradeUrl?: string);
}
/**
 * Create detailed error information for a given error code.
 *
 * Implements white paper's "Developer experience focus - structured error details".
 * Every error includes:
 * - code: Machine-readable identifier (e.g., 'INVALID_DID')
 * - message: Human-readable description of the failure
 * - cause: Root cause explanation (from 'hint' field)
 * - resolution: Actionable suggestion for resolution (from 'suggested_action')
 * - field: Specific field that caused the error (when applicable)
 * - docs: Documentation URL for additional context
 *
 * @param code - Error code (e.g., 'INVALID_DID')
 * @param additionalContext - Optional context (field name, custom hint/resolution)
 * @returns ACIErrorDetail with code, message, cause, resolution, field, and docs
 */
export declare function createXBindErrorDetail(code: string, additionalContext?: {
    field?: string;
    hint?: string;
    resolution?: string;
}): ACIErrorDetail;
/**
 * Convert a string error code to a typed XBindError instance.
 * Handles colon-separated sub-codes (e.g. 'DECRYPT_FAILED:KEY_AGREEMENT').
 * Falls back to base XBindError for unknown codes.
 *
 * @param code - Error code string from Result<T,E> (e.g. 'REPLAY_DETECTED')
 * @returns Typed XBindError subclass instance
 */
export declare function toXBindError(code: string): XBindError;
/**
 * Type guard for XBindError instances.
 *
 * @param err - Unknown value to check
 * @returns True if err is a XBindError instance
 */
export declare function isXBindError(err: unknown): err is XBindError;
