import type { Logger } from './types.js'; /** @internal */ export declare const NOOP_LOGGER: Logger; /** @internal */ export declare function assertString(value: unknown, name: string): asserts value is string; /** @internal */ export declare function assertBytes(value: unknown, name: string): asserts value is Uint8Array; /** @internal */ export declare function assertCompressedPubkey(value: unknown, name: string): asserts value is Uint8Array; /** * The message of the deepest meaningful error in a cause chain. * * Walks `err.cause` links (capped at 16 hops, cycle-safe) and returns the * message of the deepest link that has one. Rules, in order, at each link: * * - A string link is its own message. * - An object link with a non-empty string `message` contributes that message. * - An object link with an empty message but an `errors` array (an * `AggregateError`, e.g. a Node fetch failure against a host with several * addresses) contributes the first sub-error's message. * - A link with no usable message is skipped, so the nearest non-empty * message above it in the chain wins. * * Never throws: throwing getters, null-prototype objects, and non-Error * values all degrade to `String(value)` or `'Unknown error'`. * * @param err The caught value whose root cause message to extract. * @returns A non-empty, human-readable message. */ export declare function rootCauseMessage(err: unknown): string; /** * The DID Resolution error code of a caught value. * * Walks `err.cause` links from the top (capped at 16 hops, cycle-safe) and * returns the `type` of the first link that is a {@link DidMethodError} whose * type is a member of {@link MethodErrorCode}. The nearest typed link wins, so * a wrapper that re-types a deeper failure decides the code. Every other value * maps to `INTERNAL_ERROR`, the code DID Resolution v1 gives to an unexpected * error. Never throws. * * @param err The caught value. * @returns A member of {@link MethodErrorCode}. */ export declare function resolutionErrorCode(err: unknown): string; //# sourceMappingURL=helpers.d.ts.map