/** * W3C Trace Context - `traceparent` parsing/formatting + id generation. This is OpenTelemetry's * wire format for propagating a trace across services, so producing/forwarding it correctly is the * core of distributed tracing regardless of which backend ends up collecting the spans. * * traceparent: 00-<32-hex trace-id>-<16-hex span-id>-<2-hex flags> * * Pure + dependency-free; the request plugin is a thin layer over this. */ /** A parsed inbound `traceparent`. */ export interface ParsedTraceparent { readonly traceId: string; readonly spanId: string; readonly sampled: boolean; } /** * Parse a `traceparent` header, or `null` if it's absent/malformed/version-unknown - per the spec, * a bad header means "start a fresh trace", never an error. Only version `00` is accepted. */ export declare function parseTraceparent(header: string | null | undefined): ParsedTraceparent | null; /** Format a `traceparent` header value (version `00`). */ export declare function formatTraceparent(traceId: string, spanId: string, sampled: boolean): string; /** A fresh 16-byte (32-hex) trace id. */ export declare function generateTraceId(): string; /** A fresh 8-byte (16-hex) span id. */ export declare function generateSpanId(): string; //# sourceMappingURL=traceparent.d.ts.map