@sentry/server-utils 11.14.0 → 11.15.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/build/cjs/chunks/exports.js +526 -217
- package/build/cjs/chunks/exports.js.map +1 -1
- package/build/cjs/index.js +1028 -120
- package/build/cjs/index.js.map +1 -1
- package/build/esm/ai/anthropic-ai/index.js +32 -56
- package/build/esm/ai/anthropic-ai/index.js.map +1 -1
- package/build/esm/ai/anthropic-ai/streaming.js +10 -6
- package/build/esm/ai/anthropic-ai/streaming.js.map +1 -1
- package/build/esm/ai/anthropic-ai/tool-runner.js +18 -3
- package/build/esm/ai/anthropic-ai/tool-runner.js.map +1 -1
- package/build/esm/ai/anthropic-ai/utils.js +41 -3
- package/build/esm/ai/anthropic-ai/utils.js.map +1 -1
- package/build/esm/ai/core/span-hooks.js +23 -0
- package/build/esm/ai/core/span-hooks.js.map +1 -0
- package/build/esm/ai/core/time-to-first-chunk.js +14 -0
- package/build/esm/ai/core/time-to-first-chunk.js.map +1 -0
- package/build/esm/ai/core/utils.js +29 -3
- package/build/esm/ai/core/utils.js.map +1 -1
- package/build/esm/ai/flue/index.js +15 -12
- package/build/esm/ai/flue/index.js.map +1 -1
- package/build/esm/ai/flue/utils.js +24 -17
- package/build/esm/ai/flue/utils.js.map +1 -1
- package/build/esm/ai/google-genai/index.js +21 -8
- package/build/esm/ai/google-genai/index.js.map +1 -1
- package/build/esm/ai/google-genai/streaming.js +6 -2
- package/build/esm/ai/google-genai/streaming.js.map +1 -1
- package/build/esm/ai/langchain/embeddings.js +5 -2
- package/build/esm/ai/langchain/embeddings.js.map +1 -1
- package/build/esm/ai/langchain/index.js +82 -24
- package/build/esm/ai/langchain/index.js.map +1 -1
- package/build/esm/ai/langchain/utils.js +9 -1
- package/build/esm/ai/langchain/utils.js.map +1 -1
- package/build/esm/ai/langgraph/agent-span.js +13 -5
- package/build/esm/ai/langgraph/agent-span.js.map +1 -1
- package/build/esm/ai/langgraph/index.js +13 -15
- package/build/esm/ai/langgraph/index.js.map +1 -1
- package/build/esm/ai/langgraph/stream.js +4 -3
- package/build/esm/ai/langgraph/stream.js.map +1 -1
- package/build/esm/ai/langgraph/utils.js +17 -8
- package/build/esm/ai/langgraph/utils.js.map +1 -1
- package/build/esm/ai/mastra/classifier-evaluation.js.map +1 -1
- package/build/esm/ai/mastra/index.js +33 -16
- package/build/esm/ai/mastra/index.js.map +1 -1
- package/build/esm/ai/mastra/utils.js +3 -5
- package/build/esm/ai/mastra/utils.js.map +1 -1
- package/build/esm/ai/mistral/index.js +21 -7
- package/build/esm/ai/mistral/index.js.map +1 -1
- package/build/esm/ai/mistral/streaming.js +4 -2
- package/build/esm/ai/mistral/streaming.js.map +1 -1
- package/build/esm/ai/openai/index.js +19 -8
- package/build/esm/ai/openai/index.js.map +1 -1
- package/build/esm/ai/openai/streaming.js +7 -2
- package/build/esm/ai/openai/streaming.js.map +1 -1
- package/build/esm/ai/pi-ai/chat.js +18 -1
- package/build/esm/ai/pi-ai/chat.js.map +1 -1
- package/build/esm/ai/pi-ai/recording.js +34 -15
- package/build/esm/ai/pi-ai/recording.js.map +1 -1
- package/build/esm/ai/pi-durable/index.js +7 -2
- package/build/esm/ai/pi-durable/index.js.map +1 -1
- package/build/esm/ai/pi-durable/runs.js.map +1 -1
- package/build/esm/ai/pi-durable/tools.js +18 -3
- package/build/esm/ai/pi-durable/tools.js.map +1 -1
- package/build/esm/ai/typesafe/index.js +14 -6
- package/build/esm/ai/typesafe/index.js.map +1 -1
- package/build/esm/ai/workers-ai/index.js +26 -9
- package/build/esm/ai/workers-ai/index.js.map +1 -1
- package/build/esm/ai/workers-ai/streaming.js +6 -4
- package/build/esm/ai/workers-ai/streaming.js.map +1 -1
- package/build/esm/cron/common.js +16 -0
- package/build/esm/cron/common.js.map +1 -0
- package/build/esm/cron/cron.js +82 -0
- package/build/esm/cron/cron.js.map +1 -0
- package/build/esm/cron/index.js +13 -0
- package/build/esm/cron/index.js.map +1 -0
- package/build/esm/cron/node-cron.js +66 -0
- package/build/esm/cron/node-cron.js.map +1 -0
- package/build/esm/cron/node-schedule.js +43 -0
- package/build/esm/cron/node-schedule.js.map +1 -0
- package/build/esm/index.js +6 -2
- package/build/esm/index.js.map +1 -1
- package/build/esm/integrations/anthropic.js +25 -16
- package/build/esm/integrations/anthropic.js.map +1 -1
- package/build/esm/integrations/aws-sdk/index.js +1 -0
- package/build/esm/integrations/aws-sdk/index.js.map +1 -1
- package/build/esm/integrations/aws-sdk/services/ServicesExtensions.js +3 -0
- package/build/esm/integrations/aws-sdk/services/ServicesExtensions.js.map +1 -1
- package/build/esm/integrations/aws-sdk/services/bedrock-runtime.js +45 -12
- package/build/esm/integrations/aws-sdk/services/bedrock-runtime.js.map +1 -1
- package/build/esm/integrations/bullmq/contextManager.js +45 -0
- package/build/esm/integrations/bullmq/contextManager.js.map +1 -0
- package/build/esm/integrations/bullmq/index.js +44 -0
- package/build/esm/integrations/bullmq/index.js.map +1 -0
- package/build/esm/integrations/bullmq/meter.js +86 -0
- package/build/esm/integrations/bullmq/meter.js.map +1 -0
- package/build/esm/integrations/bullmq/span.js +114 -0
- package/build/esm/integrations/bullmq/span.js.map +1 -0
- package/build/esm/integrations/bullmq/tracer.js +62 -0
- package/build/esm/integrations/bullmq/tracer.js.map +1 -0
- package/build/esm/integrations/express/instrumentation.js +10 -1
- package/build/esm/integrations/express/instrumentation.js.map +1 -1
- package/build/esm/integrations/google-genai.js +17 -9
- package/build/esm/integrations/google-genai.js.map +1 -1
- package/build/esm/integrations/langgraph.js +5 -7
- package/build/esm/integrations/langgraph.js.map +1 -1
- package/build/esm/integrations/mastra-classifier.js +1 -1
- package/build/esm/integrations/mastra-classifier.js.map +1 -1
- package/build/esm/integrations/mistral.js +13 -4
- package/build/esm/integrations/mistral.js.map +1 -1
- package/build/esm/integrations/openai-compatible.js +16 -8
- package/build/esm/integrations/openai-compatible.js.map +1 -1
- package/build/esm/integrations/openai.js +16 -8
- package/build/esm/integrations/openai.js.map +1 -1
- package/build/esm/integrations/pi-ai.js +39 -18
- package/build/esm/integrations/pi-ai.js.map +1 -1
- package/build/esm/integrations/pino.js +131 -0
- package/build/esm/integrations/pino.js.map +1 -0
- package/build/esm/integrations/typesafe.js +17 -3
- package/build/esm/integrations/typesafe.js.map +1 -1
- package/build/esm/integrations/vercel-ai/index.js.map +1 -1
- package/build/esm/integrations/vercel-ai/util.js +3 -2
- package/build/esm/integrations/vercel-ai/util.js.map +1 -1
- package/build/esm/integrations/vercel-ai/vercel-ai-dc-subscriber.js +44 -17
- package/build/esm/integrations/vercel-ai/vercel-ai-dc-subscriber.js.map +1 -1
- package/build/esm/integrations/vercel-ai/vercel-ai-orchestrion-subscriber.js +22 -16
- package/build/esm/integrations/vercel-ai/vercel-ai-orchestrion-subscriber.js.map +1 -1
- package/build/esm/integrations/winston.js +90 -0
- package/build/esm/integrations/winston.js.map +1 -0
- package/build/esm/orchestrion/detect.js +1 -1
- package/build/esm/orchestrion/detect.js.map +1 -1
- package/build/esm/package.json +1 -1
- package/build/types/ai/anthropic-ai/index.d.ts +1 -5
- package/build/types/ai/anthropic-ai/index.d.ts.map +1 -1
- package/build/types/ai/anthropic-ai/streaming.d.ts +3 -2
- package/build/types/ai/anthropic-ai/streaming.d.ts.map +1 -1
- package/build/types/ai/anthropic-ai/tool-runner.d.ts.map +1 -1
- package/build/types/ai/anthropic-ai/types.d.ts +24 -3
- package/build/types/ai/anthropic-ai/types.d.ts.map +1 -1
- package/build/types/ai/anthropic-ai/utils.d.ts +2 -3
- package/build/types/ai/anthropic-ai/utils.d.ts.map +1 -1
- package/build/types/ai/core/span-hooks.d.ts +31 -0
- package/build/types/ai/core/span-hooks.d.ts.map +1 -0
- package/build/types/ai/core/time-to-first-chunk.d.ts +7 -0
- package/build/types/ai/core/time-to-first-chunk.d.ts.map +1 -0
- package/build/types/ai/core/utils.d.ts +30 -1
- package/build/types/ai/core/utils.d.ts.map +1 -1
- package/build/types/ai/flue/index.d.ts +13 -5
- package/build/types/ai/flue/index.d.ts.map +1 -1
- package/build/types/ai/flue/types.d.ts +20 -2
- package/build/types/ai/flue/types.d.ts.map +1 -1
- package/build/types/ai/flue/utils.d.ts +5 -9
- package/build/types/ai/flue/utils.d.ts.map +1 -1
- package/build/types/ai/google-genai/index.d.ts.map +1 -1
- package/build/types/ai/google-genai/streaming.d.ts +2 -1
- package/build/types/ai/google-genai/streaming.d.ts.map +1 -1
- package/build/types/ai/google-genai/types.d.ts +17 -3
- package/build/types/ai/google-genai/types.d.ts.map +1 -1
- package/build/types/ai/langchain/index.d.ts.map +1 -1
- package/build/types/ai/langchain/types.d.ts +49 -3
- package/build/types/ai/langchain/types.d.ts.map +1 -1
- package/build/types/ai/langchain/utils.d.ts +6 -0
- package/build/types/ai/langchain/utils.d.ts.map +1 -1
- package/build/types/ai/langgraph/agent-span.d.ts +4 -1
- package/build/types/ai/langgraph/agent-span.d.ts.map +1 -1
- package/build/types/ai/langgraph/index.d.ts +1 -1
- package/build/types/ai/langgraph/index.d.ts.map +1 -1
- package/build/types/ai/langgraph/stream.d.ts.map +1 -1
- package/build/types/ai/langgraph/types.d.ts +14 -3
- package/build/types/ai/langgraph/types.d.ts.map +1 -1
- package/build/types/ai/langgraph/utils.d.ts +3 -0
- package/build/types/ai/langgraph/utils.d.ts.map +1 -1
- package/build/types/ai/mastra/classifier-evaluation.d.ts +3 -3
- package/build/types/ai/mastra/classifier-evaluation.d.ts.map +1 -1
- package/build/types/ai/mastra/index.d.ts +17 -3
- package/build/types/ai/mastra/index.d.ts.map +1 -1
- package/build/types/ai/mastra/types.d.ts +2 -0
- package/build/types/ai/mastra/types.d.ts.map +1 -1
- package/build/types/ai/mastra/utils.d.ts.map +1 -1
- package/build/types/ai/mistral/index.d.ts.map +1 -1
- package/build/types/ai/mistral/streaming.d.ts +2 -1
- package/build/types/ai/mistral/streaming.d.ts.map +1 -1
- package/build/types/ai/mistral/types.d.ts +14 -3
- package/build/types/ai/mistral/types.d.ts.map +1 -1
- package/build/types/ai/openai/index.d.ts.map +1 -1
- package/build/types/ai/openai/streaming.d.ts +3 -1
- package/build/types/ai/openai/streaming.d.ts.map +1 -1
- package/build/types/ai/openai/types.d.ts +14 -3
- package/build/types/ai/openai/types.d.ts.map +1 -1
- package/build/types/ai/pi-ai/chat.d.ts +7 -1
- package/build/types/ai/pi-ai/chat.d.ts.map +1 -1
- package/build/types/ai/pi-ai/recording.d.ts +21 -9
- package/build/types/ai/pi-ai/recording.d.ts.map +1 -1
- package/build/types/ai/pi-ai/types.d.ts +16 -0
- package/build/types/ai/pi-ai/types.d.ts.map +1 -1
- package/build/types/ai/pi-durable/index.d.ts +12 -3
- package/build/types/ai/pi-durable/index.d.ts.map +1 -1
- package/build/types/ai/pi-durable/runs.d.ts +2 -0
- package/build/types/ai/pi-durable/runs.d.ts.map +1 -1
- package/build/types/ai/pi-durable/tools.d.ts +4 -3
- package/build/types/ai/pi-durable/tools.d.ts.map +1 -1
- package/build/types/ai/pi-durable/types.d.ts +15 -0
- package/build/types/ai/pi-durable/types.d.ts.map +1 -1
- package/build/types/ai/typesafe/index.d.ts +10 -2
- package/build/types/ai/typesafe/index.d.ts.map +1 -1
- package/build/types/ai/workers-ai/index.d.ts.map +1 -1
- package/build/types/ai/workers-ai/streaming.d.ts +2 -1
- package/build/types/ai/workers-ai/streaming.d.ts.map +1 -1
- package/build/types/ai/workers-ai/types.d.ts +18 -3
- package/build/types/ai/workers-ai/types.d.ts.map +1 -1
- package/build/types/cron/common.d.ts +8 -0
- package/build/types/cron/common.d.ts.map +1 -0
- package/build/types/cron/cron.d.ts +45 -0
- package/build/types/cron/cron.d.ts.map +1 -0
- package/build/types/cron/index.d.ts +10 -0
- package/build/types/cron/index.d.ts.map +1 -0
- package/build/types/cron/node-cron.d.ts +33 -0
- package/build/types/cron/node-cron.d.ts.map +1 -0
- package/build/types/cron/node-schedule.d.ts +19 -0
- package/build/types/cron/node-schedule.d.ts.map +1 -0
- package/build/types/index.d.ts +5 -2
- package/build/types/index.d.ts.map +1 -1
- package/build/types/integrations/anthropic.d.ts +2 -1
- package/build/types/integrations/anthropic.d.ts.map +1 -1
- package/build/types/integrations/aws-sdk/index.d.ts +3 -3
- package/build/types/integrations/aws-sdk/index.d.ts.map +1 -1
- package/build/types/integrations/aws-sdk/services/ServiceExtension.d.ts +1 -0
- package/build/types/integrations/aws-sdk/services/ServiceExtension.d.ts.map +1 -1
- package/build/types/integrations/aws-sdk/services/ServicesExtensions.d.ts +3 -2
- package/build/types/integrations/aws-sdk/services/ServicesExtensions.d.ts.map +1 -1
- package/build/types/integrations/aws-sdk/services/bedrock-runtime.d.ts +25 -4
- package/build/types/integrations/aws-sdk/services/bedrock-runtime.d.ts.map +1 -1
- package/build/types/integrations/bullmq/contextManager.d.ts +13 -0
- package/build/types/integrations/bullmq/contextManager.d.ts.map +1 -0
- package/build/types/integrations/bullmq/index.d.ts +43 -0
- package/build/types/integrations/bullmq/index.d.ts.map +1 -0
- package/build/types/integrations/bullmq/meter.d.ts +7 -0
- package/build/types/integrations/bullmq/meter.d.ts.map +1 -0
- package/build/types/integrations/bullmq/span.d.ts +35 -0
- package/build/types/integrations/bullmq/span.d.ts.map +1 -0
- package/build/types/integrations/bullmq/tracer.d.ts +5 -0
- package/build/types/integrations/bullmq/tracer.d.ts.map +1 -0
- package/build/types/integrations/bullmq/types.d.ts +72 -0
- package/build/types/integrations/bullmq/types.d.ts.map +1 -0
- package/build/types/integrations/express/types.d.ts +1 -0
- package/build/types/integrations/express/types.d.ts.map +1 -1
- package/build/types/integrations/flue.d.ts +2 -1
- package/build/types/integrations/flue.d.ts.map +1 -1
- package/build/types/integrations/google-genai.d.ts +2 -1
- package/build/types/integrations/google-genai.d.ts.map +1 -1
- package/build/types/integrations/groq.d.ts +1 -1
- package/build/types/integrations/langchain.d.ts +2 -1
- package/build/types/integrations/langchain.d.ts.map +1 -1
- package/build/types/integrations/langgraph.d.ts +2 -1
- package/build/types/integrations/langgraph.d.ts.map +1 -1
- package/build/types/integrations/mistral.d.ts +2 -1
- package/build/types/integrations/mistral.d.ts.map +1 -1
- package/build/types/integrations/openai-compatible.d.ts.map +1 -1
- package/build/types/integrations/openai.d.ts +2 -1
- package/build/types/integrations/openai.d.ts.map +1 -1
- package/build/types/integrations/pi-ai.d.ts +6 -3
- package/build/types/integrations/pi-ai.d.ts.map +1 -1
- package/build/types/integrations/pi-durable.d.ts +2 -1
- package/build/types/integrations/pi-durable.d.ts.map +1 -1
- package/build/types/integrations/pino.d.ts +61 -0
- package/build/types/integrations/pino.d.ts.map +1 -0
- package/build/types/integrations/together-ai.d.ts +1 -1
- package/build/types/integrations/typesafe.d.ts +2 -2
- package/build/types/integrations/typesafe.d.ts.map +1 -1
- package/build/types/integrations/vercel-ai/index.d.ts +3 -3
- package/build/types/integrations/vercel-ai/index.d.ts.map +1 -1
- package/build/types/integrations/vercel-ai/util.d.ts +2 -1
- package/build/types/integrations/vercel-ai/util.d.ts.map +1 -1
- package/build/types/integrations/vercel-ai/vercel-ai-dc-subscriber.d.ts +20 -4
- package/build/types/integrations/vercel-ai/vercel-ai-dc-subscriber.d.ts.map +1 -1
- package/build/types/integrations/vercel-ai/vercel-ai-orchestrion-subscriber.d.ts.map +1 -1
- package/build/types/integrations/winston.d.ts +55 -0
- package/build/types/integrations/winston.d.ts.map +1 -0
- package/package.json +3 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pino.d.ts","sourceRoot":"","sources":["../../../src/integrations/pino.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAiDpE,KAAK,WAAW,GAAG;IACjB;;;;;;OAMG;IACH,cAAc,EAAE,OAAO,CAAC;IACxB;;OAEG;IACH,KAAK,EAAE;QACL;;;;WAIG;QACH,MAAM,EAAE,gBAAgB,EAAE,CAAC;QAC3B;;;;;WAKG;QACH,OAAO,EAAE,OAAO,CAAC;KAClB,CAAC;IACF;;OAEG;IACH,GAAG,EAAE;QACH;;;;WAIG;QACH,MAAM,EAAE,gBAAgB,EAAE,CAAC;KAC5B,CAAC;CACH,CAAC;AAQF,KAAK,WAAW,CAAC,CAAC,IAAI;KACnB,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAC5D,CAAC;AA8GF;;;;;;;;;GASG;AACH,eAAO,MAAM,eAAe;;;wBACN,OAAO,GAAG,IAAI;0BAKZ,OAAO,GAAG,IAAI;CAKpC,CAAC"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* format, so this reuses the openai span/streaming logic; see `createOpenAiCompatibleIntegration`. Requires
|
|
4
4
|
* the Sentry runtime hook or bundler plugin so the diagnostics channels get injected into `together-ai`.
|
|
5
5
|
*/
|
|
6
|
-
export declare const togetherAIIntegration: (options?: import("../ai/
|
|
6
|
+
export declare const togetherAIIntegration: (options?: import("../ai/openai/types").OpenAiOptions | undefined) => import("@sentry/core").Integration & {
|
|
7
7
|
name: string;
|
|
8
8
|
};
|
|
9
9
|
//# sourceMappingURL=together-ai.d.ts.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { TypeSafeOptions } from '../ai/typesafe';
|
|
2
2
|
/**
|
|
3
3
|
* Diagnostics-channel-based integration for the TypeSafe SDK (`@typesafe-ai/sdk` >= 0.5.0 < 1).
|
|
4
4
|
* Subscribes to the `orchestrion:@typesafe-ai/sdk:system-one` channel injected into
|
|
5
5
|
* `TypeSafeClient.systemOne`, so it requires the Sentry runtime hook or bundler plugin.
|
|
6
6
|
*/
|
|
7
|
-
export declare const typesafeIntegration: (options?:
|
|
7
|
+
export declare const typesafeIntegration: (options?: TypeSafeOptions | undefined) => import("@sentry/core").Integration & {
|
|
8
8
|
name: "TypeSafe";
|
|
9
9
|
};
|
|
10
10
|
//# sourceMappingURL=typesafe.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typesafe.d.ts","sourceRoot":"","sources":["../../../src/integrations/typesafe.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"typesafe.d.ts","sourceRoot":"","sources":["../../../src/integrations/typesafe.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAoB,eAAe,EAAE,MAAM,gBAAgB,CAAC;AA2DxE;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;;CAA0C,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type VercelAiChannelOptions } from './vercel-ai-dc-subscriber';
|
|
2
2
|
/** Options for the Vercel AI integration. */
|
|
3
|
-
export type VercelAiOptions =
|
|
3
|
+
export type VercelAiOptions = VercelAiChannelOptions;
|
|
4
4
|
/**
|
|
5
5
|
* Auto-instrument the `ai` SDK. Supported are:
|
|
6
6
|
* - v7 via native `ai:telemetry` tracing channel
|
|
7
7
|
* - v4, v5 & v6 via the injected `orchestrion:ai:*` channels
|
|
8
8
|
*/
|
|
9
|
-
export declare const vercelAIIntegration: (options?:
|
|
9
|
+
export declare const vercelAIIntegration: (options?: VercelAiChannelOptions | undefined) => import("@sentry/core").Integration & {
|
|
10
10
|
name: "VercelAI";
|
|
11
11
|
};
|
|
12
12
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAmC,KAAK,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AAOzG,6CAA6C;AAC7C,MAAM,MAAM,eAAe,GAAG,sBAAsB,CAAC;AAwBrD;;;;GAIG;AACH,eAAO,MAAM,mBAAmB;;CAA0C,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/** Shared, state-free helpers for the Vercel AI (`ai`) channel subscribers, plus the streamed model-call tap. */
|
|
2
|
+
import type { Span } from '@sentry/core';
|
|
2
3
|
/** Narrow to a string, or `undefined` for anything else. */
|
|
3
4
|
export declare function asString(value: unknown): string | undefined;
|
|
4
5
|
/** Narrow to a finite number, or `undefined` for anything else (including `NaN`). */
|
|
@@ -26,5 +27,5 @@ export { isReadableStream } from '../../ai/core/utils';
|
|
|
26
27
|
* `try/catch` around every read guarantees the owning span is always ended — a leaked open span on a
|
|
27
28
|
* mid-stream failure would be worse than a slightly-less-enriched one.
|
|
28
29
|
*/
|
|
29
|
-
export declare function tapModelCallStream(stream: ReadableStream<unknown>, onFinal: (result: StreamedModelCallResult) => void, onError: (error: unknown) => void): ReadableStream<unknown>;
|
|
30
|
+
export declare function tapModelCallStream(span: Span, stream: ReadableStream<unknown>, onFinal: (result: StreamedModelCallResult) => void, onError: (error: unknown) => void): ReadableStream<unknown>;
|
|
30
31
|
//# sourceMappingURL=util.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/util.ts"],"names":[],"mappings":"AAAA,iHAAiH;
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/util.ts"],"names":[],"mappings":"AAAA,iHAAiH;AAEjH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAIzC,4DAA4D;AAC5D,wBAAgB,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAE3D;AAED,qFAAqF;AACrF,wBAAgB,QAAQ,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAE3D;AAED,kHAAkH;AAClH,wBAAgB,GAAG,CAAC,CAAC,EAAE,MAAM,GAAG,SAAS,EAAE,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAEpF;AAoCD,6GAA6G;AAC7G,MAAM,WAAW,uBAAuB;IACtC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,KAAK,CAAC,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IAC1C,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED,iFAAiF;AACjF,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD;;;;;;;;GAQG;AACH,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,cAAc,CAAC,OAAO,CAAC,EAC/B,OAAO,EAAE,CAAC,MAAM,EAAE,uBAAuB,KAAK,IAAI,EAClD,OAAO,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,GAChC,cAAc,CAAC,OAAO,CAAC,CAsDzB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { Span } from '@sentry/core';
|
|
2
2
|
import type { TracingChannel } from 'node:diagnostics_channel';
|
|
3
|
-
import { type
|
|
3
|
+
import { type GenAiSpanHooks, type GenAiSpanResult } from '../../ai/core/span-hooks';
|
|
4
|
+
import { type GenAiCallOptions } from '../../ai/core/utils';
|
|
4
5
|
import { type StreamedModelCallResult } from './util';
|
|
5
6
|
/**
|
|
6
7
|
* The single tracing channel the `ai` package (>= 7) publishes all telemetry lifecycle events to
|
|
@@ -42,9 +43,24 @@ export interface VercelAiChannelMessage {
|
|
|
42
43
|
* any manual parent bookkeeping here.
|
|
43
44
|
*/
|
|
44
45
|
export type VercelAiTracingChannelFactory = <T extends object>(name: string) => TracingChannel<T, T>;
|
|
45
|
-
/**
|
|
46
|
-
|
|
46
|
+
/**
|
|
47
|
+
* The call that `recordInputs`/`recordOutputs` decide on, and that the span hooks get: one span, with the AI SDK
|
|
48
|
+
* telemetry event as published.
|
|
49
|
+
*/
|
|
50
|
+
export interface VercelAiCallInfo {
|
|
51
|
+
/** The channel event type, such as `generateText`, `languageModelCall` or `executeTool`. */
|
|
52
|
+
type: ChannelEventType;
|
|
53
|
+
/** The AI SDK telemetry event of the call. */
|
|
54
|
+
event: Record<string, unknown>;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Integration options, pinned at subscribe time so we never look the integration up per event. `onSpanEnd` gets the
|
|
58
|
+
* AI SDK result of the call as `response`; for streams it is `undefined`.
|
|
59
|
+
*/
|
|
60
|
+
export type VercelAiChannelOptions = GenAiCallOptions<VercelAiCallInfo> & GenAiSpanHooks<VercelAiCallInfo>;
|
|
47
61
|
export declare const fallbackChannelResults: WeakMap<Span, unknown>;
|
|
62
|
+
/** Runs the `onSpanEnd` hook of a span that `createSpanFromMessage` started. Call it right before the span ends. */
|
|
63
|
+
export declare function runVercelAiSpanEnd(span: Span, result: GenAiSpanResult<unknown>): void;
|
|
48
64
|
/**
|
|
49
65
|
* Subscribe Sentry span handlers to the `ai` SDK's native telemetry tracing channel (`ai:telemetry`,
|
|
50
66
|
* available in `ai` >= 7) and emit fully-formed `gen_ai.*` spans directly — no OpenTelemetry span
|
|
@@ -72,6 +88,6 @@ export declare function createSpanFromMessage(data: VercelAiChannelMessage, chan
|
|
|
72
88
|
* Everything here is guarded: when a field is missing or the shape differs across `ai` versions,
|
|
73
89
|
* we simply don't set the attribute rather than emit a malformed span.
|
|
74
90
|
*/
|
|
75
|
-
export declare function enrichSpanOnEnd(span: Span, data: VercelAiChannelMessage
|
|
91
|
+
export declare function enrichSpanOnEnd(span: Span, data: VercelAiChannelMessage): void;
|
|
76
92
|
export declare function captureToolError(span: Span, data: VercelAiChannelMessage, error: unknown): void;
|
|
77
93
|
//# sourceMappingURL=vercel-ai-dc-subscriber.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vercel-ai-dc-subscriber.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/vercel-ai-dc-subscriber.ts"],"names":[],"mappings":"AAwCA,OAAO,KAAK,EAAE,IAAI,EAAkB,MAAM,cAAc,CAAC;AAezD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"vercel-ai-dc-subscriber.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/vercel-ai-dc-subscriber.ts"],"names":[],"mappings":"AAwCA,OAAO,KAAK,EAAE,IAAI,EAAkB,MAAM,cAAc,CAAC;AAezD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAE/D,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,eAAe,EAGrB,MAAM,0BAA0B,CAAC;AAElC,OAAO,EACL,KAAK,gBAAgB,EAItB,MAAM,qBAAqB,CAAC;AAI7B,OAAO,EAAwC,KAAK,uBAAuB,EAA2B,MAAM,QAAQ,CAAC;AAErH;;;;GAIG;AACH,eAAO,MAAM,gCAAgC,iBAAiB,CAAC;AA0E/D,2GAA2G;AAC3G,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,sBAAsB,GAAG,IAAI,CAQnE;AAED;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAKzD;AA8FD,sEAAsE;AACtE,MAAM,MAAM,gBAAgB,GACxB,cAAc,GACd,YAAY,GACZ,cAAc,GACd,gBAAgB,GAChB,MAAM,GACN,mBAAmB,GACnB,aAAa,GACb,OAAO,GACP,WAAW,GACX,QAAQ,GACR,uBAAuB,GACvB,qBAAqB,CAAC;AAE1B;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACrC,IAAI,EAAE,gBAAgB,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC/B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;;;;;;;GASG;AACH,MAAM,MAAM,6BAA6B,GAAG,CAAC,CAAC,SAAS,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,cAAc,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;AAErG;;;GAGG;AACH,MAAM,WAAW,gBAAgB;IAC/B,4FAA4F;IAC5F,IAAI,EAAE,gBAAgB,CAAC;IACvB,8CAA8C;IAC9C,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAChC;AAED;;;GAGG;AACH,MAAM,MAAM,sBAAsB,GAAG,gBAAgB,CAAC,gBAAgB,CAAC,GAAG,cAAc,CAAC,gBAAgB,CAAC,CAAC;AAS3G,eAAO,MAAM,sBAAsB,wBAA+B,CAAC;AAInE,oHAAoH;AACpH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,eAAe,CAAC,OAAO,CAAC,GAAG,IAAI,CAErF;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,+BAA+B,CAC7C,cAAc,EAAE,6BAA6B,EAC7C,OAAO,GAAE,sBAA2B,GACnC,IAAI,CAsBN;AAiDD,yGAAyG;AACzG,wBAAgB,6BAA6B,CAAC,KAAK,EAAE,uBAAuB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAuBrG;AAsCD;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACnC,IAAI,EAAE,sBAAsB,EAC5B,cAAc,EAAE,sBAAsB,GACrC,IAAI,GAAG,SAAS,CAqBlB;AAoND;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,sBAAsB,GAAG,IAAI,CA6E9E;AAoJD,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,sBAAsB,EAAE,KAAK,EAAE,OAAO,GAAG,IAAI,CA0B/F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vercel-ai-orchestrion-subscriber.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/vercel-ai-orchestrion-subscriber.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"vercel-ai-orchestrion-subscriber.d.ts","sourceRoot":"","sources":["../../../../src/integrations/vercel-ai/vercel-ai-orchestrion-subscriber.ts"],"names":[],"mappings":"AAeA,OAAO,EASL,KAAK,sBAAsB,EAC3B,KAAK,6BAA6B,EACnC,MAAM,2BAA2B,CAAC;AA0GnC;;;;;;;;GAQG;AACH,wBAAgB,oCAAoC,CAClD,cAAc,EAAE,6BAA6B,EAC7C,OAAO,GAAE,sBAA2B,GACnC,IAAI,CAiEN"}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { LogSeverityLevel } from '@sentry/core';
|
|
2
|
+
/**
|
|
3
|
+
* Options for the Sentry Winston transport.
|
|
4
|
+
*/
|
|
5
|
+
interface WinstonTransportOptions {
|
|
6
|
+
/**
|
|
7
|
+
* Use this option to filter which levels should be captured. By default, all levels are captured.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* const SentryWinstonTransport = Sentry.createSentryWinstonTransport(Transport, {
|
|
12
|
+
* // Only capture error and warn logs
|
|
13
|
+
* levels: ['error', 'warn'],
|
|
14
|
+
* });
|
|
15
|
+
* ```
|
|
16
|
+
*/
|
|
17
|
+
levels?: Array<LogSeverityLevel>;
|
|
18
|
+
/**
|
|
19
|
+
* Use this option to map custom levels to Sentry log severity levels.
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* const SentryWinstonTransport = Sentry.createSentryWinstonTransport(Transport, {
|
|
24
|
+
* customLevelMap: {
|
|
25
|
+
* myCustomLevel: 'info',
|
|
26
|
+
* customError: 'error',
|
|
27
|
+
* },
|
|
28
|
+
* });
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
31
|
+
customLevelMap?: Record<string, LogSeverityLevel>;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Creates a new Sentry Winston transport that fowards logs to Sentry.
|
|
35
|
+
*
|
|
36
|
+
* Supports Winston 3.x.x.
|
|
37
|
+
*
|
|
38
|
+
* @param TransportClass - The Winston transport class to extend.
|
|
39
|
+
* @returns The extended transport class.
|
|
40
|
+
*
|
|
41
|
+
* @example
|
|
42
|
+
* ```ts
|
|
43
|
+
* const winston = require('winston');
|
|
44
|
+
* const Transport = require('winston-transport');
|
|
45
|
+
*
|
|
46
|
+
* const SentryWinstonTransport = Sentry.createSentryWinstonTransport(Transport);
|
|
47
|
+
*
|
|
48
|
+
* const logger = winston.createLogger({
|
|
49
|
+
* transports: [new SentryWinstonTransport()],
|
|
50
|
+
* });
|
|
51
|
+
* ```
|
|
52
|
+
*/
|
|
53
|
+
export declare function createSentryWinstonTransport<TransportStreamInstance extends object>(TransportClass: new (options?: any) => TransportStreamInstance, sentryWinstonOptions?: WinstonTransportOptions): typeof TransportClass;
|
|
54
|
+
export {};
|
|
55
|
+
//# sourceMappingURL=winston.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"winston.d.ts","sourceRoot":"","sources":["../../../src/integrations/winston.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAWrD;;GAEG;AACH,UAAU,uBAAuB;IAC/B;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,KAAK,CAAC,gBAAgB,CAAC,CAAC;IAEjC;;;;;;;;;;;;OAYG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC;CACnD;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,4BAA4B,CAAC,uBAAuB,SAAS,MAAM,EAEjF,cAAc,EAAE,KAAK,OAAO,CAAC,EAAE,GAAG,KAAK,uBAAuB,EAC9D,oBAAoB,CAAC,EAAE,uBAAuB,GAC7C,OAAO,cAAc,CAgEvB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sentry/server-utils",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.15.0",
|
|
4
4
|
"description": "Server Utilities for all Sentry JavaScript SDKs",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -106,12 +106,12 @@
|
|
|
106
106
|
"dependencies": {
|
|
107
107
|
"@opentelemetry/api": "^1.9.1",
|
|
108
108
|
"@sentry/conventions": "^0.33.0",
|
|
109
|
-
"@sentry/core": "11.
|
|
109
|
+
"@sentry/core": "11.15.0"
|
|
110
110
|
},
|
|
111
111
|
"devDependencies": {
|
|
112
112
|
"@apm-js-collab/code-transformer-bundler-plugins": "^0.7.6",
|
|
113
113
|
"@neondatabase/serverless": "1.2.0",
|
|
114
|
-
"@sentry-internal/rollup-utils": "11.
|
|
114
|
+
"@sentry-internal/rollup-utils": "11.15.0",
|
|
115
115
|
"@types/node": "^20.19.0",
|
|
116
116
|
"meriyah": "^6.1.4",
|
|
117
117
|
"vite": "^8.3.6",
|