unnbound-logger-sdk 3.0.32 → 3.0.35

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/dist/axios.d.ts CHANGED
@@ -1,11 +1,19 @@
1
1
  import { type AxiosInstance, type AxiosRequestConfig, type AxiosResponse } from 'axios';
2
- import { HttpOptions } from './types';
2
+ import { type HttpOptions } from './types';
3
3
  type GetPayload = (config: AxiosRequestConfig, res?: AxiosResponse) => object;
4
+ type RedactOptions = {
5
+ response?: boolean;
6
+ };
7
+ export type OnRequest = (config: AxiosRequestConfig, callback: (config: AxiosRequestConfig) => Promise<AxiosResponse<any>>) => Promise<AxiosResponse<any>>;
8
+ interface HttpClientOptions extends HttpOptions<GetPayload> {
9
+ onRequest?: OnRequest;
10
+ redact?: RedactOptions | boolean;
11
+ }
4
12
  /**
5
13
  * Wraps an axios instance to add tracing and span tracking
6
14
  * @param axios - The axios instance to wrap
7
15
  * @param options - Configuration options for HTTP tracing
8
16
  * @returns The wrapped axios instance with span tracking
9
17
  */
10
- export declare const traceAxios: (client: AxiosInstance, { ignoreTraceRoutes, traceHeaderKey, getPayload, }?: HttpOptions<GetPayload>) => AxiosInstance;
18
+ export declare const traceAxios: (client: AxiosInstance, { ignoreTraceRoutes, traceHeaderKey, getPayload, onRequest, redact: redactOptions, }?: HttpClientOptions) => AxiosInstance;
11
19
  export {};
package/dist/axios.js CHANGED
@@ -2,10 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.traceAxios = void 0;
4
4
  const axios_1 = require("axios");
5
- const types_1 = require("./types");
5
+ const span_1 = require("./span");
6
6
  const storage_1 = require("./storage");
7
+ const types_1 = require("./types");
7
8
  const utils_1 = require("./utils");
8
- const span_1 = require("./span");
9
9
  const buildUrl = (baseUrl, url) => {
10
10
  return url?.startsWith('http') ? url : [baseUrl, url].filter(Boolean).join('');
11
11
  };
@@ -16,7 +16,7 @@ const extractQueryParams = (url, config) => {
16
16
  keys.forEach((key) => object.searchParams.delete(key));
17
17
  return { url: object.toString(), query: keys.length > 0 ? query : undefined };
18
18
  };
19
- const buildOutgoingHttpPayload = (config, res) => ({
19
+ const buildOutgoingHttpPayload = (config, res, redact) => ({
20
20
  type: 'http',
21
21
  http: {
22
22
  ...extractQueryParams(buildUrl(config.baseURL, config.url), config),
@@ -30,23 +30,26 @@ const buildOutgoingHttpPayload = (config, res) => ({
30
30
  ? {
31
31
  headers: res?.headers,
32
32
  status: res.status,
33
- body: (0, utils_1.safeJsonParse)(res.data),
33
+ body: redact?.response ? '[Redacted]' : (0, utils_1.safeJsonParse)(res.data),
34
34
  }
35
35
  : undefined,
36
36
  },
37
37
  });
38
38
  const getNoopPayload = () => ({});
39
+ const onNoopRequest = (config, callback) => callback(config);
39
40
  /**
40
41
  * Wraps an axios instance to add tracing and span tracking
41
42
  * @param axios - The axios instance to wrap
42
43
  * @param options - Configuration options for HTTP tracing
43
44
  * @returns The wrapped axios instance with span tracking
44
45
  */
45
- const traceAxios = (client, { ignoreTraceRoutes = types_1.defaultIgnoreTraceRoutes, traceHeaderKey = types_1.defaultTraceHeaderKey, getPayload = getNoopPayload, } = {
46
+ const traceAxios = (client, { ignoreTraceRoutes = types_1.defaultIgnoreTraceRoutes, traceHeaderKey = types_1.defaultTraceHeaderKey, getPayload = getNoopPayload, onRequest = onNoopRequest, redact: redactOptions, } = {
46
47
  ignoreTraceRoutes: types_1.defaultIgnoreTraceRoutes,
47
48
  traceHeaderKey: types_1.defaultTraceHeaderKey,
48
49
  getPayload: getNoopPayload,
50
+ onRequest: onNoopRequest,
49
51
  }) => {
52
+ const redact = typeof redactOptions === 'boolean' ? { response: redactOptions } : redactOptions;
50
53
  const createSpanWrappedRequest = (originalMethod, method) => {
51
54
  const { headers: defaultHeaders, ...partialDefaultConfig } = client.defaults;
52
55
  const headers = { ...defaultHeaders.common, ...(method && defaultHeaders[method]) };
@@ -59,16 +62,21 @@ const traceAxios = (client, { ignoreTraceRoutes = types_1.defaultIgnoreTraceRout
59
62
  return originalMethod(config);
60
63
  const traceId = storage_1.storage.getStore()?.traceId;
61
64
  config = { ...config, headers: { ...config.headers, [traceHeaderKey]: traceId } };
62
- // Execute the request within a span
63
- return (0, span_1.startSpan)(`Outgoing HTTP request`, () => originalMethod(config), (options) => {
64
- const response = options
65
- ? options.error
66
- ? (0, axios_1.isAxiosError)(options.error)
67
- ? options.error.response
68
- : undefined
69
- : options.result
70
- : undefined;
71
- return { ...buildOutgoingHttpPayload(config, response), ...getPayload(config, response) };
65
+ return onRequest(config, (config) => {
66
+ // Execute the request within a span
67
+ return (0, span_1.startSpan)('Outgoing HTTP request', () => originalMethod(config), (options) => {
68
+ const response = options
69
+ ? options.error
70
+ ? (0, axios_1.isAxiosError)(options.error)
71
+ ? options.error.response
72
+ : undefined
73
+ : options.result
74
+ : undefined;
75
+ return {
76
+ ...buildOutgoingHttpPayload(config, response, redact),
77
+ ...getPayload(config, response),
78
+ };
79
+ });
72
80
  });
73
81
  };
74
82
  };
package/dist/emf.d.ts ADDED
@@ -0,0 +1,58 @@
1
+ /**
2
+ * CloudWatch Embedded Metric Format (EMF) support.
3
+ *
4
+ * EMF allows you to embed metrics within structured log events.
5
+ * CloudWatch automatically extracts these as CloudWatch Metrics.
6
+ *
7
+ * @see https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Embedded_Metric_Format.html
8
+ */
9
+ export type MetricUnit = 'Seconds' | 'Microseconds' | 'Milliseconds' | 'Bytes' | 'Kilobytes' | 'Megabytes' | 'Gigabytes' | 'Terabytes' | 'Bits' | 'Kilobits' | 'Megabits' | 'Gigabits' | 'Terabits' | 'Percent' | 'Count' | 'Bytes/Second' | 'Kilobytes/Second' | 'Megabytes/Second' | 'Gigabytes/Second' | 'Terabytes/Second' | 'Bits/Second' | 'Kilobits/Second' | 'Megabits/Second' | 'Gigabits/Second' | 'Terabits/Second' | 'Count/Second' | 'None';
10
+ export interface MetricDefinition {
11
+ name: string;
12
+ unit?: MetricUnit;
13
+ value: number;
14
+ }
15
+ export interface EmitMetricOptions {
16
+ /** CloudWatch namespace (default: 'Unnbound') */
17
+ namespace?: string;
18
+ /** Dimension names to use for grouping (keys from dimensions object) */
19
+ dimensionKeys?: string[];
20
+ /** Additional properties to include in the log */
21
+ properties?: Record<string, unknown>;
22
+ }
23
+ /**
24
+ * Emit a metric via CloudWatch EMF format.
25
+ *
26
+ * @example
27
+ * ```ts
28
+ * // Simple counter
29
+ * emitMetric(
30
+ * { name: 'workflow.created', unit: 'Count', value: 1 },
31
+ * { workflowId: 'wf_123', environment: 'prod' }
32
+ * );
33
+ *
34
+ * // Duration histogram
35
+ * emitMetric(
36
+ * { name: 'deployment.duration', unit: 'Seconds', value: 12.5 },
37
+ * { workflowId: 'wf_123', status: 'success' },
38
+ * { dimensionKeys: ['workflowId', 'status'] }
39
+ * );
40
+ * ```
41
+ */
42
+ export declare function emitMetric(metric: MetricDefinition, dimensions: Record<string, string>, options?: EmitMetricOptions): void;
43
+ /**
44
+ * Emit multiple metrics in a single EMF log event.
45
+ * All metrics share the same dimensions.
46
+ *
47
+ * @example
48
+ * ```ts
49
+ * emitMetrics(
50
+ * [
51
+ * { name: 'execution.duration', unit: 'Seconds', value: 1.5 },
52
+ * { name: 'execution.payload_size', unit: 'Bytes', value: 2048 },
53
+ * ],
54
+ * { workflowId: 'wf_123', triggerType: 'http' }
55
+ * );
56
+ * ```
57
+ */
58
+ export declare function emitMetrics(metrics: MetricDefinition[], dimensions: Record<string, string>, options?: EmitMetricOptions): void;
package/dist/emf.js ADDED
@@ -0,0 +1,100 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.emitMetric = emitMetric;
4
+ exports.emitMetrics = emitMetrics;
5
+ const logger_1 = require("./logger");
6
+ const DEFAULT_NAMESPACE = 'Unnbound';
7
+ /**
8
+ * Emit a metric via CloudWatch EMF format.
9
+ *
10
+ * @example
11
+ * ```ts
12
+ * // Simple counter
13
+ * emitMetric(
14
+ * { name: 'workflow.created', unit: 'Count', value: 1 },
15
+ * { workflowId: 'wf_123', environment: 'prod' }
16
+ * );
17
+ *
18
+ * // Duration histogram
19
+ * emitMetric(
20
+ * { name: 'deployment.duration', unit: 'Seconds', value: 12.5 },
21
+ * { workflowId: 'wf_123', status: 'success' },
22
+ * { dimensionKeys: ['workflowId', 'status'] }
23
+ * );
24
+ * ```
25
+ */
26
+ function emitMetric(metric, dimensions, options = {}) {
27
+ const { namespace = DEFAULT_NAMESPACE, dimensionKeys, properties = {} } = options;
28
+ // Use specified dimension keys or all dimension keys
29
+ const dimKeys = dimensionKeys ?? Object.keys(dimensions);
30
+ const emfLog = {
31
+ // EMF metadata
32
+ _aws: {
33
+ Timestamp: Date.now(),
34
+ CloudWatchMetrics: [
35
+ {
36
+ Namespace: namespace,
37
+ Dimensions: [dimKeys],
38
+ Metrics: [
39
+ {
40
+ Name: metric.name,
41
+ Unit: metric.unit ?? 'None',
42
+ },
43
+ ],
44
+ },
45
+ ],
46
+ },
47
+ // Dimension values (must be at root level)
48
+ ...dimensions,
49
+ // Metric value (must be at root level with same name)
50
+ [metric.name]: metric.value,
51
+ // Additional properties
52
+ ...properties,
53
+ };
54
+ // Log at info level - CloudWatch will extract the metric
55
+ logger_1.logger.info(emfLog, `metric: ${metric.name}`);
56
+ }
57
+ /**
58
+ * Emit multiple metrics in a single EMF log event.
59
+ * All metrics share the same dimensions.
60
+ *
61
+ * @example
62
+ * ```ts
63
+ * emitMetrics(
64
+ * [
65
+ * { name: 'execution.duration', unit: 'Seconds', value: 1.5 },
66
+ * { name: 'execution.payload_size', unit: 'Bytes', value: 2048 },
67
+ * ],
68
+ * { workflowId: 'wf_123', triggerType: 'http' }
69
+ * );
70
+ * ```
71
+ */
72
+ function emitMetrics(metrics, dimensions, options = {}) {
73
+ const { namespace = DEFAULT_NAMESPACE, dimensionKeys, properties = {} } = options;
74
+ const dimKeys = dimensionKeys ?? Object.keys(dimensions);
75
+ const metricValues = {};
76
+ const metricDefinitions = metrics.map((m) => {
77
+ metricValues[m.name] = m.value;
78
+ return {
79
+ Name: m.name,
80
+ Unit: m.unit ?? 'None',
81
+ };
82
+ });
83
+ const emfLog = {
84
+ _aws: {
85
+ Timestamp: Date.now(),
86
+ CloudWatchMetrics: [
87
+ {
88
+ Namespace: namespace,
89
+ Dimensions: [dimKeys],
90
+ Metrics: metricDefinitions,
91
+ },
92
+ ],
93
+ },
94
+ ...dimensions,
95
+ ...metricValues,
96
+ ...properties,
97
+ };
98
+ const metricNames = metrics.map((m) => m.name).join(', ');
99
+ logger_1.logger.info(emfLog, `metrics: ${metricNames}`);
100
+ }
package/dist/index.d.ts CHANGED
@@ -5,10 +5,15 @@
5
5
  * Provides consistent, well-typed logging across different operational contexts.
6
6
  */
7
7
  export type { LogLevel, LogType, HttpMethod, Maybe, EventSource, Log, HttpPayload, SftpPayload, EdiPayload, EdiOperation, EdiFormat, EdiX12Payload, EdiX12Operation, } from './types';
8
+ export { defaultTraceHeaderKey, defaultMessageHeaderKey } from './types';
8
9
  export type { ILogger, UnnboundLogger } from './logger';
9
10
  export { logger } from './logger';
10
11
  export { encode, decode } from './encode';
11
12
  export { withTrace, getTraceId } from './trace';
12
13
  export { startSpan } from './span';
13
- export { traceAxios } from './axios';
14
+ export { traceAxios, type OnRequest } from './axios';
14
15
  export { traceMiddleware } from './middleware';
16
+ export { storage, withStorage } from './storage';
17
+ export type { UnnboundContext } from './storage';
18
+ export type { MetricUnit, MetricDefinition, EmitMetricOptions } from './emf';
19
+ export { emitMetric, emitMetrics } from './emf';
package/dist/index.js CHANGED
@@ -1,6 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.traceMiddleware = exports.traceAxios = exports.startSpan = exports.getTraceId = exports.withTrace = exports.decode = exports.encode = exports.logger = void 0;
3
+ exports.emitMetrics = exports.emitMetric = exports.withStorage = exports.storage = exports.traceMiddleware = exports.traceAxios = exports.startSpan = exports.getTraceId = exports.withTrace = exports.decode = exports.encode = exports.logger = exports.defaultMessageHeaderKey = exports.defaultTraceHeaderKey = void 0;
4
+ var types_1 = require("./types");
5
+ Object.defineProperty(exports, "defaultTraceHeaderKey", { enumerable: true, get: function () { return types_1.defaultTraceHeaderKey; } });
6
+ Object.defineProperty(exports, "defaultMessageHeaderKey", { enumerable: true, get: function () { return types_1.defaultMessageHeaderKey; } });
4
7
  var logger_1 = require("./logger");
5
8
  Object.defineProperty(exports, "logger", { enumerable: true, get: function () { return logger_1.logger; } });
6
9
  var encode_1 = require("./encode");
@@ -15,3 +18,9 @@ var axios_1 = require("./axios");
15
18
  Object.defineProperty(exports, "traceAxios", { enumerable: true, get: function () { return axios_1.traceAxios; } });
16
19
  var middleware_1 = require("./middleware");
17
20
  Object.defineProperty(exports, "traceMiddleware", { enumerable: true, get: function () { return middleware_1.traceMiddleware; } });
21
+ var storage_1 = require("./storage");
22
+ Object.defineProperty(exports, "storage", { enumerable: true, get: function () { return storage_1.storage; } });
23
+ Object.defineProperty(exports, "withStorage", { enumerable: true, get: function () { return storage_1.withStorage; } });
24
+ var emf_1 = require("./emf");
25
+ Object.defineProperty(exports, "emitMetric", { enumerable: true, get: function () { return emf_1.emitMetric; } });
26
+ Object.defineProperty(exports, "emitMetrics", { enumerable: true, get: function () { return emf_1.emitMetrics; } });
@@ -1,2 +1,3 @@
1
1
  export declare const hidden: (data: object) => unknown;
2
+ /** @public - used by SDK consumers via dist/internal */
2
3
  export declare const internal: () => Record<string, unknown>;
package/dist/internal.js CHANGED
@@ -8,5 +8,6 @@ if (process.env.UNNBOUND_IDLE_TIMEOUT)
8
8
  o._hide = true;
9
9
  const hidden = (data) => '_hide' in data && data._hide;
10
10
  exports.hidden = hidden;
11
+ /** @public - used by SDK consumers via dist/internal */
11
12
  const internal = () => o;
12
13
  exports.internal = internal;
package/dist/logger.js CHANGED
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.logger = void 0;
7
7
  const pino_1 = __importDefault(require("pino"));
8
8
  const uuid_1 = require("uuid");
9
- const storage_1 = require("./storage");
10
9
  const encode_1 = require("./encode");
11
10
  const internal_1 = require("./internal");
11
+ const storage_1 = require("./storage");
12
12
  const levels = new Set(['debug', 'info', 'warn', 'error']);
13
13
  const formatLevel = (level) => ({ level });
14
14
  // TODO: Check if there is a better way to encode the log object.
@@ -24,7 +24,7 @@ const formatLog = (log, visited = new WeakSet()) => {
24
24
  for (const key in log) {
25
25
  const value = log[key];
26
26
  // We don't want to encode undefined values.
27
- if (value == undefined)
27
+ if (value === undefined)
28
28
  continue;
29
29
  // We can't encode immutable properties.
30
30
  if (!Object.getOwnPropertyDescriptor(log, key)?.writable)
@@ -52,6 +52,7 @@ exports.logger = (0, pino_1.default)({
52
52
  workflowId: process.env.UNNBOUND_WORKFLOW_ID,
53
53
  serviceId: process.env.UNNBOUND_SERVICE_ID,
54
54
  deploymentId: process.env.UNNBOUND_DEPLOYMENT_ID,
55
+ source: process.env.UNNBOUND_LOG_SOURCE ?? 'workflow',
55
56
  },
56
57
  mixin: () => ({ ...storage_1.storage.getStore(), logId: (0, uuid_1.v4)() }),
57
58
  serializers: {
@@ -73,9 +74,7 @@ exports.logger = (0, pino_1.default)({
73
74
  if ((0, internal_1.hidden)(firstArg))
74
75
  return;
75
76
  // Dynamic log level by allowing overwriting the log level
76
- if ('level' in firstArg &&
77
- typeof firstArg.level === 'string' &&
78
- levels.has(firstArg.level)) {
77
+ if ('level' in firstArg && typeof firstArg.level === 'string' && levels.has(firstArg.level)) {
79
78
  method = this[firstArg.level];
80
79
  firstArg.level = undefined;
81
80
  }
@@ -96,7 +95,7 @@ exports.logger = (0, pino_1.default)({
96
95
  });
97
96
  process.on('uncaughtException', (err, origin) => {
98
97
  try {
99
- exports.logger.error({ err, origin }, `Uncaught exception.`);
98
+ exports.logger.error({ err, origin }, 'Uncaught exception.');
100
99
  }
101
100
  catch {
102
101
  // noop
@@ -104,7 +103,7 @@ process.on('uncaughtException', (err, origin) => {
104
103
  });
105
104
  process.on('unhandledRejection', (err, origin) => {
106
105
  try {
107
- exports.logger.error({ err, origin }, `Unhandled rejection.`);
106
+ exports.logger.error({ err, origin }, 'Unhandled rejection.');
108
107
  }
109
108
  catch {
110
109
  // noop
@@ -1,5 +1,5 @@
1
- import { Request, RequestHandler } from 'express';
2
- import { HttpOptions } from './types';
1
+ import type { Request, RequestHandler } from 'express';
2
+ import { type HttpOptions } from './types';
3
3
  interface Response {
4
4
  status: number;
5
5
  headers?: Record<string, string | undefined>;
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.traceMiddleware = void 0;
4
4
  const span_1 = require("./span");
5
5
  const types_1 = require("./types");
6
- const utils_1 = require("./utils");
7
6
  const trace_1 = require("./trace");
7
+ const utils_1 = require("./utils");
8
8
  const extractQueryParams = (url) => {
9
9
  const object = new URL(url);
10
10
  const query = Object.fromEntries(object.searchParams.entries());
@@ -18,8 +18,9 @@ const getFullUrl = (req) => {
18
18
  return url;
19
19
  // Check if we have a workflow URL configured (preferred method)
20
20
  if (process.env.UNNBOUND_WORKFLOW_URL) {
21
- // Use workflow URL as the base URL
22
- return `https://${process.env.UNNBOUND_WORKFLOW_URL.replace(/\/$/, '')}${url}`;
21
+ // Use workflow URL as the base URL (strip any existing protocol to avoid duplication)
22
+ const workflowUrl = process.env.UNNBOUND_WORKFLOW_URL.replace(/^https?:\/\//, '').replace(/\/$/, '');
23
+ return `https://${workflowUrl}${url}`;
23
24
  }
24
25
  // Fallback to constructing from request info for incoming requests
25
26
  const protocol = req.protocol || (req.secure ? 'https' : 'http');
package/dist/span.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { Maybe } from './types';
1
+ import type { Maybe } from './types';
2
2
  export type LogPayloadGetterOptions<T> = Maybe<T>;
3
3
  type LogPayloadGetter<T> = object | ((o?: LogPayloadGetterOptions<T>) => object);
4
4
  /**
package/dist/span.js CHANGED
@@ -2,9 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.startSpan = void 0;
4
4
  const uuid_1 = require("uuid");
5
+ const logger_1 = require("./logger");
5
6
  const storage_1 = require("./storage");
6
7
  const trace_1 = require("./trace");
7
- const logger_1 = require("./logger");
8
8
  /**
9
9
  * Starts a span that tracks the duration of a callback
10
10
  * @param spanName - The span name to use for logging
package/dist/storage.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { AsyncLocalStorage } from 'async_hooks';
1
+ import { AsyncLocalStorage } from 'node:async_hooks';
2
2
  export interface UnnboundContext {
3
3
  traceId?: string;
4
4
  spanId?: string;
package/dist/storage.js CHANGED
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.withStorage = exports.storage = void 0;
4
- const async_hooks_1 = require("async_hooks");
5
- exports.storage = new async_hooks_1.AsyncLocalStorage();
4
+ const node_async_hooks_1 = require("node:async_hooks");
5
+ exports.storage = new node_async_hooks_1.AsyncLocalStorage();
6
6
  const withStorage = async (data, callback) => {
7
7
  const previous = exports.storage.getStore();
8
8
  return exports.storage.run({ ...previous, ...data }, callback);
package/dist/trace.d.ts CHANGED
@@ -5,6 +5,7 @@
5
5
  export declare const getTraceId: () => string;
6
6
  /**
7
7
  * Generates a message ID
8
+ * @public - used by SDK consumers via dist/trace
8
9
  * @returns A message ID
9
10
  */
10
11
  export declare const getMessageId: () => string;
package/dist/trace.js CHANGED
@@ -11,6 +11,7 @@ const getTraceId = () => (0, uuid_1.v4)();
11
11
  exports.getTraceId = getTraceId;
12
12
  /**
13
13
  * Generates a message ID
14
+ * @public - used by SDK consumers via dist/trace
14
15
  * @returns A message ID
15
16
  */
16
17
  const getMessageId = () => (0, uuid_1.v4)();
package/package.json CHANGED
@@ -1,21 +1,19 @@
1
1
  {
2
2
  "name": "unnbound-logger-sdk",
3
3
  "description": "A structured logging library with TypeScript support using Pino. Provides consistent, well-typed logging with automatic logId, workflowId, traceId, and deploymentId tracking across operational contexts.",
4
- "version": "3.0.32",
4
+ "version": "3.0.35",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
7
  "scripts": {
8
- "build": "tsc",
9
- "test": "jest",
10
- "test:coverage": "jest --coverage",
11
- "test:watch": "jest --watch",
8
+ "build": "bun x tsc",
9
+ "test": "echo 'No tests'",
12
10
  "typecheck": "tsc -noEmit",
13
11
  "lint": "eslint --cache --cache-location ./node_modules/.cache/eslint .",
14
- "lint:fix": "pnpm lint --fix",
15
- "format": "prettier --write .",
16
- "format:check": "prettier --check .",
17
- "prepublishOnly": "pnpm build",
18
- "start:example": "npx --yes tsx --watch examples/node-express.ts",
12
+ "lint:fix": "bun run lint --fix",
13
+ "format": "biome format --write .",
14
+ "format:check": "biome format .",
15
+ "prepublishOnly": "bun run build",
16
+ "start:example": "bun --watch examples/node-express.ts",
19
17
  "version:bump": "npm version patch"
20
18
  },
21
19
  "keywords": [
@@ -47,9 +45,9 @@
47
45
  },
48
46
  "devDependencies": {
49
47
  "@types/express": "^4.17.21",
50
- "@types/jest": "^29.5.12",
51
48
  "@types/node": "^22",
52
- "@types/uuid": "^9.0.8"
49
+ "@types/uuid": "^9.0.8",
50
+ "typescript": "^5.9.3"
53
51
  },
54
52
  "peerDependencies": {
55
53
  "axios": "^1.12.2",