@coralogix/browser
Version:
Official Coralogix SDK for browsers
10 lines (9 loc) • 835 B
TypeScript
import { SpanStatusCode } from '@opentelemetry/api';
import { CustomTimestamp, CxSpanOtelSpan, OtlpKeyValueJson, OtlpStatusCodeJson, OtlpStatusJson } from './traces-exporter.types';
export declare function toOtlpKeyValue(key: string, value: unknown): OtlpKeyValueJson;
export declare function toOtlpAttributes(attributes?: Record<string, unknown>): OtlpKeyValueJson[];
export declare function timestampToNanosNumber(timestamp: CustomTimestamp): number;
export declare function timestampToNanosString(timestamp: CustomTimestamp): string;
export declare function mapStatusCodeToOtlp(code?: SpanStatusCode | number): OtlpStatusCodeJson | undefined;
export declare function toOtlpStatus(spanStatus?: CxSpanOtelSpan['status']): OtlpStatusJson | undefined;
export declare function isWithinAllowedWindow(start: number, now: number): boolean;