UNPKG

@mastra/core

Version:
19 lines • 1.08 kB
/** @internal Transported with failures, never inferred from messages or error codes. */ export interface SpanErrorOrigin { traceId: string; spanId: string; occurrenceId: string; attemptId?: string; } /** @internal Register the server-only retry context without importing Node APIs here. */ export declare function setSpanErrorAttemptResolver(resolver: () => string | undefined): void; /** @internal Read through wrappers without retaining errors or traversing span trees. */ export declare function getSpanErrorOrigin(error: unknown): SpanErrorOrigin | undefined; /** @internal Keep origin available to forwarding and explicit serializers without mutating user errors. */ export declare function setSpanErrorOrigin(error: object, origin: SpanErrorOrigin): void; /** @internal Return an occurrence only to the span where it originated. */ export declare function claimSpanError(error: Error, traceId: string, spanId: string, options?: { occurrenceId?: string; origin?: 'new' | 'propagated'; }): string | undefined; //# sourceMappingURL=error-count.d.ts.map