import type { LogRecord, LogTransport, TrackingConsent } from '@funkit/connect-core'; /** * React Native `LogTransport` that ships records to Datadog over **raw HTTP** * (`fetch`) — deliberately NOT the Datadog SDK. `@datadog/mobile-react-native` * pulls in native modules (autolinking, pods, no Expo Go); a plain `fetch` to * the logs intake needs none, so this works in Expo Go and any RN runtime. * * Records are batched and flushed fire-and-forget on a timer (or when the batch * fills); network errors are swallowed so logging never breaks a user flow. * Authenticates with the public Datadog **client token** via `dd-api-key` * (the same credential the browser SDK uses — safe to embed), so no server-side * API key is needed. */ export interface DatadogHttpLogTransportOptions { /** Datadog client token (`pub…`). Safe to ship in client apps. */ clientToken: string; /** Service name attached to every log. */ service?: string; /** Datadog site, e.g. `datadoghq.com` (default), `datadoghq.eu`. */ site?: string; /** Initial environment tag; also settable later via {@link setEnv}. */ env?: string; /** Flush the batch at most this often (ms). Default 5000. */ flushIntervalMs?: number; /** Flush immediately once the batch reaches this size. Default 50. */ maxBatchSize?: number; } export declare class DatadogHttpLogTransport implements LogTransport { private readonly intakeUrl; private readonly service; private readonly flushIntervalMs; private readonly maxBatchSize; private env; private consent; private queue; private flushTimer; constructor(options: DatadogHttpLogTransportOptions); setEnv(environment: string): void; setTrackingConsent(consent: TrackingConsent): void; log({ level, title, context, error }: LogRecord): void; /** Send the buffered batch. Fire-and-forget; network errors are swallowed. */ flush(): void; private scheduleFlush; private clearTimer; } //# sourceMappingURL=datadogHttpLogTransport.d.ts.map