@rawnodes/logger 2.9.0 → 2.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -422,6 +422,39 @@ cloudwatch: {
422
422
  }
423
423
  ```
424
424
 
425
+ ### Relay (remote live-tail)
426
+
427
+ The relay transport runs in a worker thread, polls a config endpoint you control, and — when that endpoint returns `enabled: true` — opens a WebSocket and streams logs to it in real time. Lets you flip on live-tail debugging for a running prod service from a dashboard, without redeploying.
428
+
429
+ ```typescript
430
+ Logger.create({
431
+ level: 'info',
432
+ console: { format: 'json' },
433
+ relay: {
434
+ apiUrl: 'https://relay.internal.company.com',
435
+ token: process.env.RELAY_TOKEN!,
436
+ maskSecrets: true, // mask before forwarding (recommended)
437
+ allowedWsHosts: ['ws.internal.company.com'], // only needed if WS host ≠ apiUrl host
438
+ },
439
+ });
440
+ ```
441
+
442
+ Server contract (`GET /api/relay/config` with `Authorization: Bearer <token>`):
443
+
444
+ ```jsonc
445
+ {
446
+ "enabled": true, // false = stop streaming, drop logs cheaply
447
+ "wsUrl": "wss://...", // WebSocket gateway to stream to
448
+ "rules": [{ "level": "debug", "context": "auth" }] // optional filters
449
+ }
450
+ ```
451
+
452
+ **Security defaults to know about:**
453
+
454
+ - **`wsUrl` is pinned to `apiUrl`'s origin by default.** A compromised config endpoint cannot redirect your logs to an arbitrary host. Use `allowedWsHosts` to authorize alternates explicitly.
455
+ - **`maskSecrets` does NOT inherit from the parent logger** — the relay runs in a worker thread and gets only the options you pass to its config. Pass it again here if you want forwarded logs masked. Off by default.
456
+ - The relay writes one stderr line on first successful WS open (`[RelayTransport] streaming logs to ...`) so the fact of streaming is auditable in your normal log output.
457
+
425
458
  ### Transport Options
426
459
 
427
460
  All external transports support:
@@ -668,26 +701,62 @@ getOrGenerateRequestId(req.headers); // always returns string
668
701
 
669
702
  ### Secret Masking
670
703
 
671
- Automatically masks sensitive fields in logs:
704
+ Two ways to use it: a **global flag** that masks every log automatically, or **manual utilities** when you want fine-grained control.
672
705
 
673
- ```typescript
674
- import { maskSecrets, createMasker } from '@rawnodes/logger';
706
+ #### Global flag (recommended)
675
707
 
676
- maskSecrets({
677
- user: 'admin',
678
- password: 'secret123',
679
- apiKey: 'key_abc123',
708
+ Set `maskSecrets: true` in `Logger.create` to mask all output across console / file / CloudWatch / Discord / Telegram / Zoho Cliq. Backwards compatible — masking is **off by default**.
709
+
710
+ ```typescript
711
+ const logger = Logger.create({
712
+ level: 'info',
713
+ console: { format: 'json' },
714
+ file: { format: 'json', dirname: './logs', filename: 'app.log' },
715
+ maskSecrets: true,
680
716
  });
681
- // { user: 'admin', password: '***', apiKey: '***' }
682
717
 
683
- // Custom masker
684
- const masker = createMasker({
685
- patterns: ['ssn', 'creditCard'],
686
- mask: '[REDACTED]'
718
+ logger.info('login', { user: 'alice', password: 'hunter2' });
719
+ // {"level":"info","message":"login","user":"alice","password":"***",...}
720
+
721
+ logger.info('connect', { url: 'https://u:p@db.example.com/foo' });
722
+ // URL credentials masked: "https://***:***@db.example.com/foo"
723
+ ```
724
+
725
+ Custom patterns / mask string:
726
+
727
+ ```typescript
728
+ Logger.create({
729
+ ...,
730
+ maskSecrets: {
731
+ patterns: ['ssn', 'creditCard'], // adds to defaults? NO — replaces them
732
+ mask: '[REDACTED]',
733
+ },
687
734
  });
688
735
  ```
689
736
 
690
- **Default masked patterns:** `password`, `secret`, `token`, `apikey`, `api_key`, `api-key`, `auth`, `credential`, `private`
737
+ **Default masked patterns:** `password`, `secret`, `token`, `apikey`, `api_key`, `api-key`, `auth`, `credential`, `private` (case-insensitive substring match on key names).
738
+
739
+ **Performance:** ~+2.5 µs per log call on a typical payload. Implemented via a `JSON.stringify` replacer for json/CloudWatch (zero clone) and a one-shot clone for HTTP transports that build markdown/embed payloads (Discord/Telegram/Zoho). For most services (< 10k logs/sec) the cost is invisible.
740
+
741
+ #### Manual utilities
742
+
743
+ If you only want to mask specific calls — or need a `JSON.stringify` replacer for your own serialization — three helpers are exported:
744
+
745
+ ```typescript
746
+ import { maskSecrets, createMasker, maskReplacer } from '@rawnodes/logger';
747
+
748
+ // One-shot: returns a deep-cloned masked object
749
+ maskSecrets({ user: 'admin', password: 'secret' });
750
+ // { user: 'admin', password: '***' }
751
+
752
+ // Reusable: pre-resolves options, slightly faster for repeated calls
753
+ const masker = createMasker({ patterns: ['ssn'], mask: '[REDACTED]' });
754
+ masker({ ssn: '123-45-6789' }); // { ssn: '[REDACTED]' }
755
+
756
+ // JSON.stringify replacer: zero allocations, masks during serialization
757
+ JSON.stringify(payload, maskReplacer());
758
+ JSON.stringify(payload, maskReplacer({ patterns: ['ssn'] }), 2);
759
+ ```
691
760
 
692
761
  ## Error logging
693
762
 
package/dist/index.d.mts CHANGED
@@ -1,244 +1,7 @@
1
+ import { L as LoggerContext, a as LoggerConfig, b as LevelOverrideMatch, c as LogLevel, d as LevelOverride, M as Meta, D as DiscordConfig, T as TelegramConfig, C as CloudWatchConfig, e as MaskReplacer, Z as ZohoCliqConfig, f as CallerConfig, g as CallerInfo, h as LogFormat, i as LevelRule, j as ConsoleConfig, F as FileConfig, H as HttpTransportBaseConfig, k as LevelConfigObject, l as LevelConfig, R as RelayConfig, A as AutoShutdownConfig, m as LogStreamPattern, n as LogStreamPatternConfig, o as LogStreamTemplateConfig, p as LogStreamName } from './types-lfJLhC8J.mjs';
2
+ export { q as LOG_LEVELS, x as MaskSecretsOptions, t as ZohoCliqBotConfig, s as assertLogLevel, v as createMasker, r as isValidLogLevel, w as maskReplacer, u as maskSecrets } from './types-lfJLhC8J.mjs';
1
3
  import { z } from 'zod';
2
4
 
3
- declare const LOG_LEVELS: {
4
- readonly off: -1;
5
- readonly error: 0;
6
- readonly warn: 1;
7
- readonly info: 2;
8
- readonly http: 3;
9
- readonly verbose: 4;
10
- readonly debug: 5;
11
- readonly silly: 6;
12
- };
13
- type LogLevel = keyof typeof LOG_LEVELS;
14
- declare function isValidLogLevel(level: string): level is LogLevel;
15
- declare function assertLogLevel(level: string): asserts level is LogLevel;
16
- type LogFormat = 'json' | 'plain' | 'logfmt' | 'simple';
17
- interface LevelRule {
18
- match: Record<string, unknown> & {
19
- context?: string;
20
- };
21
- level: LogLevel;
22
- }
23
- /**
24
- * Controls whether a transport respects runtime level overrides registered via
25
- * `setLevelOverride(...)` (or the top-level `level.rules` in the logger config).
26
- *
27
- * When `true` (the default for observability transports — console/file/cloudwatch/relay):
28
- * a matching override bypasses the transport's own `level`/`rules` so that
29
- * targeted troubleshooting actually surfaces logs in the viewing channels.
30
- *
31
- * When `false` (the default for alert-style transports — discord/telegram/zohoCliq):
32
- * the transport filters strictly by its own `level`/`rules` and ignores runtime
33
- * overrides, which prevents ad-hoc debug overrides from flooding user-facing
34
- * notification channels.
35
- *
36
- * Every transport config accepts this flag; the only time it needs to be set
37
- * explicitly is when overriding the default for the transport kind.
38
- */
39
- type RespectRuntimeOverrides = boolean;
40
- interface ConsoleConfig {
41
- format: LogFormat;
42
- level?: LogLevel;
43
- rules?: LevelRule[];
44
- respectRuntimeOverrides?: RespectRuntimeOverrides;
45
- }
46
- interface FileConfig {
47
- format: LogFormat;
48
- level?: LogLevel;
49
- rules?: LevelRule[];
50
- respectRuntimeOverrides?: RespectRuntimeOverrides;
51
- dirname: string;
52
- filename: string;
53
- datePattern?: string;
54
- interval?: string;
55
- zippedArchive?: boolean;
56
- maxSize?: string;
57
- maxFiles?: string;
58
- }
59
- interface HttpTransportBaseConfig {
60
- level?: LogLevel;
61
- rules?: LevelRule[];
62
- respectRuntimeOverrides?: RespectRuntimeOverrides;
63
- batchSize?: number;
64
- flushInterval?: number;
65
- maxRetries?: number;
66
- retryDelay?: number;
67
- /**
68
- * Maximum number of messages the in-memory queue will hold before dropping.
69
- * Provides a hard upper bound on memory usage when a transport is degraded
70
- * or offline — without this, a failing transport + steady log volume grows
71
- * the queue until OOM. Default: unbounded.
72
- *
73
- * Recommended for production: `10_000` — enough to absorb transient blips,
74
- * small enough to avoid runaway memory.
75
- */
76
- maxQueueSize?: number;
77
- /**
78
- * Policy applied when the queue is full.
79
- * - `'drop-oldest'` (default): prefers keeping recent events — during an
80
- * outage old logs are usually stale.
81
- * - `'drop-newest'`: prefers preserving historical context — useful if you
82
- * care more about the events leading up to the outage than the noise
83
- * happening during it.
84
- */
85
- dropPolicy?: 'drop-oldest' | 'drop-newest';
86
- /**
87
- * Called when messages are dropped due to queue overflow. Receives only the
88
- * messages that were discarded. If not provided, drops are silent.
89
- *
90
- * Callback MUST NOT throw; if it does, the exception is swallowed.
91
- */
92
- onDrop?: (droppedMessages: unknown[]) => void;
93
- /**
94
- * Called when a batch fails after all retries and messages are dropped.
95
- * If not provided, the error is logged to stderr.
96
- *
97
- * The callback MUST NOT throw; if it does, the failure is swallowed and a
98
- * stderr fallback is used. This is intentional — a logger must never
99
- * propagate its own transport errors back into the host application.
100
- */
101
- onError?: (error: Error, droppedMessages: unknown[]) => void;
102
- /**
103
- * Timeout in milliseconds for a single outbound HTTP request. Default:
104
- * `10_000`. Applies to Discord/Telegram `fetch`. CloudWatch uses the AWS
105
- * SDK's own timeout configuration.
106
- */
107
- requestTimeout?: number;
108
- }
109
- interface DiscordConfig extends HttpTransportBaseConfig {
110
- webhookUrl: string;
111
- format?: 'embed' | 'markdown';
112
- username?: string;
113
- avatarUrl?: string;
114
- embedColors?: Partial<Record<LogLevel, number>>;
115
- includeTimestamp?: boolean;
116
- includeMeta?: boolean;
117
- maxEmbedFields?: number;
118
- }
119
- interface TelegramConfig extends HttpTransportBaseConfig {
120
- botToken: string;
121
- chatId: string | number;
122
- parseMode?: 'Markdown' | 'MarkdownV2' | 'HTML';
123
- disableNotification?: boolean;
124
- threadId?: number;
125
- replyToMessageId?: number;
126
- }
127
- interface ZohoCliqBotConfig {
128
- /** Bot display name (shown in the channel). */
129
- name: string;
130
- /** Optional bot avatar URL. */
131
- image?: string;
132
- }
133
- interface ZohoCliqConfig extends HttpTransportBaseConfig {
134
- /**
135
- * Incoming webhook URL. If provided, `companyId`/`channel`/`region` are
136
- * ignored and this URL is used as-is (with `zapikey` appended as query).
137
- */
138
- webhookUrl?: string;
139
- /** Zoho Cliq company/org ID. Required unless `webhookUrl` is set. */
140
- companyId?: string;
141
- /** Target channel name (the `channelsbyname` API segment). Required unless `webhookUrl` is set. */
142
- channel?: string;
143
- /** Zoho region/TLD: 'eu' | 'com' | 'in' | etc. Default: 'eu'. */
144
- region?: string;
145
- /** Zoho API key (zapikey). Required. */
146
- apiKey: string;
147
- /** If true (default), message is posted as a broadcast so all members are notified. */
148
- broadcast?: boolean;
149
- /** Post as a custom bot instead of the default user. */
150
- bot?: ZohoCliqBotConfig;
151
- /** Include ISO timestamp in each formatted message. Default: true. */
152
- includeTimestamp?: boolean;
153
- /** Include meta as a fenced code block. Default: true. */
154
- includeMeta?: boolean;
155
- }
156
- type LogStreamPattern = 'hostname' | 'hostname-date' | 'hostname-uuid' | 'date' | 'uuid';
157
- interface LogStreamPatternConfig {
158
- pattern: LogStreamPattern;
159
- }
160
- interface LogStreamTemplateConfig {
161
- /** Custom template with variables: {hostname}, {date}, {datetime}, {uuid}, {pid}, {env} */
162
- template: string;
163
- }
164
- type LogStreamName = string | LogStreamPatternConfig | LogStreamTemplateConfig;
165
- interface RelayConfig {
166
- /** URL of the relay API (e.g., https://relay.example.com) */
167
- apiUrl: string;
168
- /** Authentication token for the relay server */
169
- token: string;
170
- /** Polling interval in ms (default: 30000) */
171
- pollInterval?: number;
172
- /** Ring buffer capacity - max logs held during reconnect (default: 1000) */
173
- bufferSize?: number;
174
- /** WebSocket reconnect base delay in ms (default: 1000) */
175
- reconnectDelay?: number;
176
- /** Max reconnect delay in ms (default: 30000) */
177
- maxReconnectDelay?: number;
178
- /** See RespectRuntimeOverrides. Default: true (relay is an observability transport). */
179
- respectRuntimeOverrides?: RespectRuntimeOverrides;
180
- }
181
- interface CloudWatchConfig extends HttpTransportBaseConfig {
182
- logGroupName: string;
183
- /** Log stream name - string, pattern config, or template config. Defaults to hostname pattern */
184
- logStreamName?: LogStreamName;
185
- region: string;
186
- accessKeyId: string;
187
- secretAccessKey: string;
188
- createLogGroup?: boolean;
189
- createLogStream?: boolean;
190
- }
191
- interface LevelConfigObject {
192
- default: LogLevel;
193
- rules?: LevelRule[];
194
- }
195
- type LevelConfig = LogLevel | LevelConfigObject;
196
- interface CallerConfig {
197
- /** Stack depth to capture (default: 1). Higher values trace further up the call stack */
198
- depth?: number;
199
- /** Include full file path (default: false). If false, shows relative or basename only */
200
- fullPath?: boolean;
201
- }
202
- interface CallerInfo {
203
- file: string;
204
- line: number;
205
- column?: number;
206
- function?: string;
207
- }
208
- interface AutoShutdownConfig {
209
- /** Timeout in ms before forcing exit (default: 5000) */
210
- timeout?: number;
211
- /** Custom signals to handle (default: ['SIGTERM', 'SIGINT']) */
212
- signals?: NodeJS.Signals[];
213
- }
214
- interface LoggerConfig {
215
- level: LevelConfig;
216
- console: ConsoleConfig;
217
- file?: FileConfig;
218
- discord?: DiscordConfig | DiscordConfig[];
219
- telegram?: TelegramConfig | TelegramConfig[];
220
- cloudwatch?: CloudWatchConfig | CloudWatchConfig[];
221
- zohoCliq?: ZohoCliqConfig | ZohoCliqConfig[];
222
- /** Relay transport config — streams logs to a remote server via WebSocket (runs in worker thread) */
223
- relay?: RelayConfig;
224
- /** Enable caller info (file:line) in logs. Pass true for defaults or CallerConfig for options */
225
- caller?: boolean | CallerConfig;
226
- /** Hostname to include in all log entries. Defaults to os.hostname() if not specified */
227
- hostname?: string;
228
- /** Auto-register graceful shutdown handlers. Pass true for defaults or config object */
229
- autoShutdown?: boolean | AutoShutdownConfig;
230
- }
231
- type LoggerContext = Record<string, unknown>;
232
- type LevelOverrideMatch<TContext extends LoggerContext> = Partial<TContext> & {
233
- context?: string;
234
- };
235
- interface LevelOverride<TContext extends LoggerContext> {
236
- match: LevelOverrideMatch<TContext>;
237
- level: LogLevel;
238
- readonly?: boolean;
239
- }
240
- type Meta = object | (() => object);
241
-
242
5
  declare class LoggerStore<TContext extends LoggerContext = LoggerContext> {
243
6
  private storage;
244
7
  getStore(): TContext | undefined;
@@ -387,10 +150,19 @@ interface BaseHttpTransportOptions {
387
150
  * back into the host application.
388
151
  */
389
152
  onError?: (error: Error, droppedMessages: BufferedMessage[]) => void;
153
+ /**
154
+ * If provided, applied to `meta` once per message in `transformMessage`. Used
155
+ * by transports that build payloads via `Object.entries(meta)` iteration
156
+ * (Discord/Telegram/Zoho), where a JSON.stringify replacer can't reach the
157
+ * top-level key. CloudWatch passes `undefined` here and uses a replacer in
158
+ * its own `sendBatch` instead.
159
+ */
160
+ masker?: (value: unknown) => unknown;
390
161
  }
391
162
  declare abstract class BaseHttpTransport {
392
163
  protected buffer: MessageBuffer;
393
164
  private onErrorCallback?;
165
+ private masker?;
394
166
  constructor(opts?: BaseHttpTransportOptions);
395
167
  log(info: Record<string, unknown>, callback: () => void): void;
396
168
  /**
@@ -416,7 +188,7 @@ declare function matchesContext(storeContext: LoggerContext | undefined, loggerC
416
188
  declare class DiscordTransport extends BaseHttpTransport {
417
189
  private config;
418
190
  private requestTimeout;
419
- constructor(config: DiscordConfig);
191
+ constructor(config: DiscordConfig, masker?: (value: unknown) => unknown);
420
192
  protected sendBatch(messages: BufferedMessage[]): Promise<void>;
421
193
  private sendEmbedBatch;
422
194
  private sendMarkdownBatch;
@@ -432,7 +204,7 @@ declare class TelegramTransport extends BaseHttpTransport {
432
204
  private config;
433
205
  private apiUrl;
434
206
  private requestTimeout;
435
- constructor(config: TelegramConfig);
207
+ constructor(config: TelegramConfig, masker?: (value: unknown) => unknown);
436
208
  protected sendBatch(messages: BufferedMessage[]): Promise<void>;
437
209
  private formatBatchMessage;
438
210
  private formatMarkdown;
@@ -450,7 +222,8 @@ declare class CloudWatchTransport extends BaseHttpTransport {
450
222
  private initialized;
451
223
  private initPromise;
452
224
  private resolvedLogStreamName;
453
- constructor(config: CloudWatchConfig, configHostname?: string);
225
+ private maskReplacer;
226
+ constructor(config: CloudWatchConfig, configHostname?: string, maskReplacerFn?: MaskReplacer);
454
227
  protected sendBatch(messages: BufferedMessage[]): Promise<void>;
455
228
  private ensureInitialized;
456
229
  private initialize;
@@ -465,7 +238,7 @@ declare class ZohoCliqTransport extends BaseHttpTransport {
465
238
  private config;
466
239
  private endpoint;
467
240
  private requestTimeout;
468
- constructor(config: ZohoCliqConfig);
241
+ constructor(config: ZohoCliqConfig, masker?: (value: unknown) => unknown);
469
242
  private buildEndpoint;
470
243
  protected sendBatch(messages: BufferedMessage[]): Promise<void>;
471
244
  private formatMessage;
@@ -495,14 +268,6 @@ declare function generateRequestId(options?: RequestIdOptions): string;
495
268
  declare function extractRequestId(headers: Record<string, string | string[] | undefined>): string | undefined;
496
269
  declare function getOrGenerateRequestId(headers: Record<string, string | string[] | undefined>, options?: RequestIdOptions): string;
497
270
 
498
- interface MaskSecretsOptions {
499
- patterns?: string[];
500
- mask?: string;
501
- deep?: boolean;
502
- }
503
- declare function maskSecrets(obj: unknown, options?: MaskSecretsOptions): unknown;
504
- declare function createMasker(options?: MaskSecretsOptions): (obj: unknown) => unknown;
505
-
506
271
  declare function getCallerInfo(config: CallerConfig, additionalOffset?: number): CallerInfo | undefined;
507
272
  declare function formatCallerInfo(info: CallerInfo): string;
508
273
 
@@ -701,6 +466,11 @@ declare const LoggerConfigSchema: z.ZodObject<{
701
466
  caller: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodType<CallerConfig, unknown, z.core.$ZodTypeInternals<CallerConfig, unknown>>]>>;
702
467
  hostname: z.ZodOptional<z.ZodString>;
703
468
  autoShutdown: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodType<AutoShutdownConfig, unknown, z.core.$ZodTypeInternals<AutoShutdownConfig, unknown>>]>>;
469
+ maskSecrets: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
470
+ patterns: z.ZodOptional<z.ZodArray<z.ZodString>>;
471
+ mask: z.ZodOptional<z.ZodString>;
472
+ deep: z.ZodOptional<z.ZodBoolean>;
473
+ }, z.core.$strip>]>>;
704
474
  }, z.core.$strip>;
705
475
  declare function validateConfig(config: unknown): z.infer<typeof LoggerConfigSchema>;
706
476
  declare function safeValidateConfig(config: unknown): z.ZodSafeParseResult<{
@@ -765,6 +535,11 @@ declare function safeValidateConfig(config: unknown): z.ZodSafeParseResult<{
765
535
  caller?: boolean | CallerConfig | undefined;
766
536
  hostname?: string | undefined;
767
537
  autoShutdown?: boolean | AutoShutdownConfig | undefined;
538
+ maskSecrets?: boolean | {
539
+ patterns?: string[] | undefined;
540
+ mask?: string | undefined;
541
+ deep?: boolean | undefined;
542
+ } | undefined;
768
543
  }>;
769
544
 
770
- export { type AutoShutdownConfig, AutoShutdownConfigSchema, BaseHttpTransport, type BaseHttpTransportOptions, type BufferOptions, type BufferedMessage, type CallerConfig, CallerConfigSchema, type CallerInfo, type CloudWatchConfig, CloudWatchConfigSchema, CloudWatchTransport, type ConsoleConfig, ConsoleConfigSchema, type DiscordConfig, DiscordConfigSchema, DiscordTransport, type FileConfig, FileConfigSchema, type GracefulShutdownOptions, type HttpErrorData, type HttpTransportBaseConfig, HttpTransportBaseConfigSchema, LOG_LEVELS, type LevelConfig, type LevelConfigObject, LevelConfigObjectSchema, LevelConfigSchema, type LevelOverride, type LevelOverrideMatch, type LevelRule, LevelRuleSchema, type LogFormat, LogFormatSchema, type LogLevel, LogLevelSchema, type LogStreamName, LogStreamNameSchema, type LogStreamPattern, type LogStreamPatternConfig, LogStreamPatternConfigSchema, LogStreamPatternSchema, type LogStreamTemplateConfig, LogStreamTemplateConfigSchema, Logger, type LoggerConfig, LoggerConfigSchema, type LoggerContext, LoggerStore, type MaskSecretsOptions, MessageBuffer, type Meta, type RelayConfig, RelayConfigSchema, type RequestIdOptions, type SerializedError, type SingletonLogger, type TelegramConfig, TelegramConfigSchema, TelegramTransport, type TimingResult, type ZohoCliqBotConfig, type ZohoCliqConfig, ZohoCliqConfigSchema, ZohoCliqTransport, assertLogLevel, createMasker, createSingletonLogger, extractRequestId, flattenObject, formatCallerInfo, formatLogfmt, formatLogfmtValue, generateRequestId, getCallerInfo, getOrGenerateRequestId, isValidLogLevel, maskSecrets, matchesContext, measureAsync, measureSync, registerShutdown, safeValidateConfig, serializeError, validateConfig };
545
+ export { AutoShutdownConfig, AutoShutdownConfigSchema, BaseHttpTransport, type BaseHttpTransportOptions, type BufferOptions, type BufferedMessage, CallerConfig, CallerConfigSchema, CallerInfo, CloudWatchConfig, CloudWatchConfigSchema, CloudWatchTransport, ConsoleConfig, ConsoleConfigSchema, DiscordConfig, DiscordConfigSchema, DiscordTransport, FileConfig, FileConfigSchema, type GracefulShutdownOptions, type HttpErrorData, HttpTransportBaseConfig, HttpTransportBaseConfigSchema, LevelConfig, LevelConfigObject, LevelConfigObjectSchema, LevelConfigSchema, LevelOverride, LevelOverrideMatch, LevelRule, LevelRuleSchema, LogFormat, LogFormatSchema, LogLevel, LogLevelSchema, LogStreamName, LogStreamNameSchema, LogStreamPattern, LogStreamPatternConfig, LogStreamPatternConfigSchema, LogStreamPatternSchema, LogStreamTemplateConfig, LogStreamTemplateConfigSchema, Logger, LoggerConfig, LoggerConfigSchema, LoggerContext, LoggerStore, MaskReplacer, MessageBuffer, Meta, RelayConfig, RelayConfigSchema, type RequestIdOptions, type SerializedError, type SingletonLogger, TelegramConfig, TelegramConfigSchema, TelegramTransport, type TimingResult, ZohoCliqConfig, ZohoCliqConfigSchema, ZohoCliqTransport, createSingletonLogger, extractRequestId, flattenObject, formatCallerInfo, formatLogfmt, formatLogfmtValue, generateRequestId, getCallerInfo, getOrGenerateRequestId, matchesContext, measureAsync, measureSync, registerShutdown, safeValidateConfig, serializeError, validateConfig };