import { PrivacyConfig } from "./core/privacy.js"; //#region src/config.d.ts /** * Content privacy mode for LLM message tracking. * * - `FULL`: Capture complete message content (default). * - `METADATA_ONLY`: Strip content, keep token counts and metadata. * - `CUSTOMER_ENRICHED`: Let customer enrich events post-hoc. * * Both `ContentMode.FULL` (const accessor) and `'full'` (string literal) * are valid — they produce the same value. */ type ContentMode = 'full' | 'metadata_only' | 'customer_enriched'; declare const ContentMode: { readonly FULL: ContentMode; readonly METADATA_ONLY: ContentMode; readonly CUSTOMER_ENRICHED: ContentMode; }; interface AIConfigOptions { contentMode?: ContentMode; redactPii?: boolean; customRedactionPatterns?: Array; customRedactionFn?: (text: string) => string; onEventCallback?: (event: unknown, statusCode: number, message: string | null) => void; debug?: boolean; dryRun?: boolean; /** * Capture post-redaction events and print sanitized upload previews * without sending them. Default: `false`. */ reviewMode?: boolean; validate?: boolean; /** * When `true`, provider wrappers created from this instance send W3C * `traceparent` plus `x-amplitude-session-id` / `x-amplitude-agent-id` * request headers on LLM calls (for gateway correlation). End-user and * device IDs are never sent to the provider. Applies only to wrappers * bound to this `AmplitudeAI`; a wrapper's own `propagateContext` option * takes precedence. Default: `false`. */ propagateContext?: boolean; /** * When `true`, capture `error.stack` on error events and attach as * `[Agent] Stack Trace`. Default: `false`. Only enable when explicitly * opted in — stack traces may contain file paths and internal details. */ captureStackTrace?: boolean; /** Raise when tokens > 0 but cost cannot be calculated (dev/CI). */ strictCost?: boolean; /** * Upper bound (ms) on how long `session.run()` waits for its automatic * flush. Event delivery has no network timeout of its own, so without a * bound an unreachable endpoint could stall the caller indefinitely. On * timeout the flush keeps running in the background and `run()` resolves. * Default: 3000. Values above 300000 are clamped; non-positive or * non-numeric values fall back to the default. */ flushTimeoutMs?: number; } /** Default for {@link AIConfigOptions.flushTimeoutMs}. */ declare const DEFAULT_FLUSH_TIMEOUT_MS = 3000; /** @internal Normalize a flush timeout: positive, finite, clamped. */ declare function normalizeFlushTimeoutMs(value: unknown): number | null; /** * Configuration for the Amplitude AI SDK. * * Controls content capture mode, PII redaction, debug output, * and validation behavior. * * @example * ```typescript * const config = new AIConfig({ * contentMode: ContentMode.METADATA_ONLY, * redactPii: true, * debug: true, * }); * ``` */ declare class AIConfig { readonly contentMode: ContentMode; readonly redactPii: boolean; readonly customRedactionPatterns: Array; readonly customRedactionFn: ((text: string) => string) | null; readonly onEventCallback: ((event: unknown, statusCode: number, message: string | null) => void) | null; readonly debug: boolean; readonly dryRun: boolean; readonly reviewMode: boolean; readonly validate: boolean; readonly propagateContext: boolean; readonly captureStackTrace: boolean; readonly strictCost: boolean; readonly flushTimeoutMs: number; constructor(options?: AIConfigOptions); toPrivacyConfig(): PrivacyConfig; } //#endregion export { AIConfig, AIConfigOptions, ContentMode, DEFAULT_FLUSH_TIMEOUT_MS, normalizeFlushTimeoutMs }; //# sourceMappingURL=config.d.ts.map