@sentry/node 10.55.0 → 10.57.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.
Files changed (185) hide show
  1. package/build/cjs/integrations/node-fetch/vendored/undici.js +2 -3
  2. package/build/cjs/integrations/node-fetch/vendored/undici.js.map +1 -1
  3. package/build/cjs/integrations/tracing/InstrumentationNodeModuleFile.js +15 -0
  4. package/build/cjs/integrations/tracing/InstrumentationNodeModuleFile.js.map +1 -0
  5. package/build/cjs/integrations/tracing/amqplib/vendored/amqplib.js +9 -9
  6. package/build/cjs/integrations/tracing/amqplib/vendored/amqplib.js.map +1 -1
  7. package/build/cjs/integrations/tracing/amqplib/vendored/utils.js.map +1 -1
  8. package/build/cjs/integrations/tracing/anthropic-ai/index.js.map +1 -1
  9. package/build/cjs/integrations/tracing/connect/vendored/instrumentation.js +3 -5
  10. package/build/cjs/integrations/tracing/connect/vendored/instrumentation.js.map +1 -1
  11. package/build/cjs/integrations/tracing/express.js +3 -5
  12. package/build/cjs/integrations/tracing/express.js.map +1 -1
  13. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js +10 -11
  14. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js.map +1 -1
  15. package/build/cjs/integrations/tracing/fastify/vendored/instrumentation.js +3 -4
  16. package/build/cjs/integrations/tracing/fastify/vendored/instrumentation.js.map +1 -1
  17. package/build/cjs/integrations/tracing/firebase/otel/patches/firestore.js +2 -1
  18. package/build/cjs/integrations/tracing/firebase/otel/patches/firestore.js.map +1 -1
  19. package/build/cjs/integrations/tracing/firebase/otel/patches/functions.js +2 -1
  20. package/build/cjs/integrations/tracing/firebase/otel/patches/functions.js.map +1 -1
  21. package/build/cjs/integrations/tracing/google-genai/index.js.map +1 -1
  22. package/build/cjs/integrations/tracing/google-genai/instrumentation.js +2 -1
  23. package/build/cjs/integrations/tracing/google-genai/instrumentation.js.map +1 -1
  24. package/build/cjs/integrations/tracing/graphql/vendored/instrumentation.js +4 -3
  25. package/build/cjs/integrations/tracing/graphql/vendored/instrumentation.js.map +1 -1
  26. package/build/cjs/integrations/tracing/hapi/vendored/instrumentation.js +2 -5
  27. package/build/cjs/integrations/tracing/hapi/vendored/instrumentation.js.map +1 -1
  28. package/build/cjs/integrations/tracing/knex/vendored/instrumentation.js +3 -2
  29. package/build/cjs/integrations/tracing/knex/vendored/instrumentation.js.map +1 -1
  30. package/build/cjs/integrations/tracing/koa/vendored/instrumentation.js +3 -4
  31. package/build/cjs/integrations/tracing/koa/vendored/instrumentation.js.map +1 -1
  32. package/build/cjs/integrations/tracing/langchain/index.js.map +1 -1
  33. package/build/cjs/integrations/tracing/langchain/instrumentation.js +3 -2
  34. package/build/cjs/integrations/tracing/langchain/instrumentation.js.map +1 -1
  35. package/build/cjs/integrations/tracing/langgraph/index.js.map +1 -1
  36. package/build/cjs/integrations/tracing/langgraph/instrumentation.js +7 -5
  37. package/build/cjs/integrations/tracing/langgraph/instrumentation.js.map +1 -1
  38. package/build/cjs/integrations/tracing/lrumemoizer/vendored/instrumentation.js +8 -11
  39. package/build/cjs/integrations/tracing/lrumemoizer/vendored/instrumentation.js.map +1 -1
  40. package/build/cjs/integrations/tracing/mongo/vendored/instrumentation.js +7 -6
  41. package/build/cjs/integrations/tracing/mongo/vendored/instrumentation.js.map +1 -1
  42. package/build/cjs/integrations/tracing/mysql2/vendored/instrumentation.js +3 -2
  43. package/build/cjs/integrations/tracing/mysql2/vendored/instrumentation.js.map +1 -1
  44. package/build/cjs/integrations/tracing/openai/index.js.map +1 -1
  45. package/build/cjs/integrations/tracing/postgres/vendored/instrumentation.js +5 -5
  46. package/build/cjs/integrations/tracing/postgres/vendored/instrumentation.js.map +1 -1
  47. package/build/cjs/integrations/tracing/postgresjs.js +3 -2
  48. package/build/cjs/integrations/tracing/postgresjs.js.map +1 -1
  49. package/build/cjs/integrations/tracing/redis/index.js +3 -2
  50. package/build/cjs/integrations/tracing/redis/index.js.map +1 -1
  51. package/build/cjs/integrations/tracing/redis/vendored/ioredis-instrumentation.js +1 -1
  52. package/build/cjs/integrations/tracing/redis/vendored/ioredis-instrumentation.js.map +1 -1
  53. package/build/cjs/integrations/tracing/redis/vendored/redis-instrumentation.js +4 -3
  54. package/build/cjs/integrations/tracing/redis/vendored/redis-instrumentation.js.map +1 -1
  55. package/build/cjs/integrations/tracing/utils/sql-common.js.map +1 -1
  56. package/build/cjs/integrations/tracing/vercelai/instrumentation.js +6 -5
  57. package/build/cjs/integrations/tracing/vercelai/instrumentation.js.map +1 -1
  58. package/build/cjs/utils/setHttpServerSpanRouteAttribute.js +21 -0
  59. package/build/cjs/utils/setHttpServerSpanRouteAttribute.js.map +1 -0
  60. package/build/esm/integrations/node-fetch/vendored/undici.js +3 -4
  61. package/build/esm/integrations/node-fetch/vendored/undici.js.map +1 -1
  62. package/build/esm/integrations/tracing/InstrumentationNodeModuleFile.js +13 -0
  63. package/build/esm/integrations/tracing/InstrumentationNodeModuleFile.js.map +1 -0
  64. package/build/esm/integrations/tracing/amqplib/vendored/amqplib.js +7 -7
  65. package/build/esm/integrations/tracing/amqplib/vendored/amqplib.js.map +1 -1
  66. package/build/esm/integrations/tracing/amqplib/vendored/utils.js.map +1 -1
  67. package/build/esm/integrations/tracing/anthropic-ai/index.js.map +1 -1
  68. package/build/esm/integrations/tracing/connect/vendored/instrumentation.js +3 -5
  69. package/build/esm/integrations/tracing/connect/vendored/instrumentation.js.map +1 -1
  70. package/build/esm/integrations/tracing/express.js +3 -5
  71. package/build/esm/integrations/tracing/express.js.map +1 -1
  72. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js +3 -4
  73. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js.map +1 -1
  74. package/build/esm/integrations/tracing/fastify/vendored/instrumentation.js +3 -4
  75. package/build/esm/integrations/tracing/fastify/vendored/instrumentation.js.map +1 -1
  76. package/build/esm/integrations/tracing/firebase/otel/patches/firestore.js +2 -1
  77. package/build/esm/integrations/tracing/firebase/otel/patches/firestore.js.map +1 -1
  78. package/build/esm/integrations/tracing/firebase/otel/patches/functions.js +2 -1
  79. package/build/esm/integrations/tracing/firebase/otel/patches/functions.js.map +1 -1
  80. package/build/esm/integrations/tracing/google-genai/index.js.map +1 -1
  81. package/build/esm/integrations/tracing/google-genai/instrumentation.js +2 -1
  82. package/build/esm/integrations/tracing/google-genai/instrumentation.js.map +1 -1
  83. package/build/esm/integrations/tracing/graphql/vendored/instrumentation.js +2 -1
  84. package/build/esm/integrations/tracing/graphql/vendored/instrumentation.js.map +1 -1
  85. package/build/esm/integrations/tracing/hapi/vendored/instrumentation.js +2 -5
  86. package/build/esm/integrations/tracing/hapi/vendored/instrumentation.js.map +1 -1
  87. package/build/esm/integrations/tracing/knex/vendored/instrumentation.js +2 -1
  88. package/build/esm/integrations/tracing/knex/vendored/instrumentation.js.map +1 -1
  89. package/build/esm/integrations/tracing/koa/vendored/instrumentation.js +3 -4
  90. package/build/esm/integrations/tracing/koa/vendored/instrumentation.js.map +1 -1
  91. package/build/esm/integrations/tracing/langchain/index.js.map +1 -1
  92. package/build/esm/integrations/tracing/langchain/instrumentation.js +2 -1
  93. package/build/esm/integrations/tracing/langchain/instrumentation.js.map +1 -1
  94. package/build/esm/integrations/tracing/langgraph/index.js.map +1 -1
  95. package/build/esm/integrations/tracing/langgraph/instrumentation.js +5 -3
  96. package/build/esm/integrations/tracing/langgraph/instrumentation.js.map +1 -1
  97. package/build/esm/integrations/tracing/lrumemoizer/vendored/instrumentation.js +8 -11
  98. package/build/esm/integrations/tracing/lrumemoizer/vendored/instrumentation.js.map +1 -1
  99. package/build/esm/integrations/tracing/mongo/vendored/instrumentation.js +2 -1
  100. package/build/esm/integrations/tracing/mongo/vendored/instrumentation.js.map +1 -1
  101. package/build/esm/integrations/tracing/mysql2/vendored/instrumentation.js +2 -1
  102. package/build/esm/integrations/tracing/mysql2/vendored/instrumentation.js.map +1 -1
  103. package/build/esm/integrations/tracing/openai/index.js.map +1 -1
  104. package/build/esm/integrations/tracing/postgres/vendored/instrumentation.js +5 -5
  105. package/build/esm/integrations/tracing/postgres/vendored/instrumentation.js.map +1 -1
  106. package/build/esm/integrations/tracing/postgresjs.js +3 -2
  107. package/build/esm/integrations/tracing/postgresjs.js.map +1 -1
  108. package/build/esm/integrations/tracing/redis/index.js +3 -2
  109. package/build/esm/integrations/tracing/redis/index.js.map +1 -1
  110. package/build/esm/integrations/tracing/redis/vendored/ioredis-instrumentation.js +1 -1
  111. package/build/esm/integrations/tracing/redis/vendored/ioredis-instrumentation.js.map +1 -1
  112. package/build/esm/integrations/tracing/redis/vendored/redis-instrumentation.js +2 -1
  113. package/build/esm/integrations/tracing/redis/vendored/redis-instrumentation.js.map +1 -1
  114. package/build/esm/integrations/tracing/utils/sql-common.js.map +1 -1
  115. package/build/esm/integrations/tracing/vercelai/instrumentation.js +6 -5
  116. package/build/esm/integrations/tracing/vercelai/instrumentation.js.map +1 -1
  117. package/build/esm/package.json +1 -1
  118. package/build/esm/utils/setHttpServerSpanRouteAttribute.js +19 -0
  119. package/build/esm/utils/setHttpServerSpanRouteAttribute.js.map +1 -0
  120. package/build/types/integrations/node-fetch/vendored/undici.d.ts.map +1 -1
  121. package/build/types/integrations/tracing/InstrumentationNodeModuleFile.d.ts +9 -0
  122. package/build/types/integrations/tracing/InstrumentationNodeModuleFile.d.ts.map +1 -0
  123. package/build/types/integrations/tracing/amqplib/vendored/amqplib.d.ts.map +1 -1
  124. package/build/types/integrations/tracing/amqplib/vendored/utils.d.ts +2 -2
  125. package/build/types/integrations/tracing/amqplib/vendored/utils.d.ts.map +1 -1
  126. package/build/types/integrations/tracing/anthropic-ai/index.d.ts +8 -7
  127. package/build/types/integrations/tracing/anthropic-ai/index.d.ts.map +1 -1
  128. package/build/types/integrations/tracing/connect/vendored/instrumentation.d.ts.map +1 -1
  129. package/build/types/integrations/tracing/express.d.ts.map +1 -1
  130. package/build/types/integrations/tracing/fastify/v3/instrumentation.d.ts.map +1 -1
  131. package/build/types/integrations/tracing/fastify/vendored/instrumentation.d.ts.map +1 -1
  132. package/build/types/integrations/tracing/firebase/otel/patches/firestore.d.ts.map +1 -1
  133. package/build/types/integrations/tracing/firebase/otel/patches/functions.d.ts.map +1 -1
  134. package/build/types/integrations/tracing/google-genai/index.d.ts +8 -7
  135. package/build/types/integrations/tracing/google-genai/index.d.ts.map +1 -1
  136. package/build/types/integrations/tracing/google-genai/instrumentation.d.ts.map +1 -1
  137. package/build/types/integrations/tracing/graphql/vendored/instrumentation.d.ts.map +1 -1
  138. package/build/types/integrations/tracing/hapi/vendored/instrumentation.d.ts.map +1 -1
  139. package/build/types/integrations/tracing/knex/vendored/instrumentation.d.ts.map +1 -1
  140. package/build/types/integrations/tracing/koa/vendored/instrumentation.d.ts.map +1 -1
  141. package/build/types/integrations/tracing/langchain/index.d.ts +9 -8
  142. package/build/types/integrations/tracing/langchain/index.d.ts.map +1 -1
  143. package/build/types/integrations/tracing/langchain/instrumentation.d.ts.map +1 -1
  144. package/build/types/integrations/tracing/langgraph/index.d.ts +8 -7
  145. package/build/types/integrations/tracing/langgraph/index.d.ts.map +1 -1
  146. package/build/types/integrations/tracing/langgraph/instrumentation.d.ts.map +1 -1
  147. package/build/types/integrations/tracing/lrumemoizer/vendored/instrumentation.d.ts +2 -2
  148. package/build/types/integrations/tracing/lrumemoizer/vendored/instrumentation.d.ts.map +1 -1
  149. package/build/types/integrations/tracing/mongo/vendored/instrumentation.d.ts.map +1 -1
  150. package/build/types/integrations/tracing/mysql2/vendored/instrumentation.d.ts.map +1 -1
  151. package/build/types/integrations/tracing/openai/index.d.ts +8 -7
  152. package/build/types/integrations/tracing/openai/index.d.ts.map +1 -1
  153. package/build/types/integrations/tracing/postgres/vendored/instrumentation.d.ts.map +1 -1
  154. package/build/types/integrations/tracing/postgresjs.d.ts.map +1 -1
  155. package/build/types/integrations/tracing/redis/index.d.ts +4 -1
  156. package/build/types/integrations/tracing/redis/index.d.ts.map +1 -1
  157. package/build/types/integrations/tracing/redis/vendored/redis-instrumentation.d.ts.map +1 -1
  158. package/build/types/integrations/tracing/utils/sql-common.d.ts +1 -1
  159. package/build/types/integrations/tracing/utils/sql-common.d.ts.map +1 -1
  160. package/build/types/integrations/tracing/vercelai/instrumentation.d.ts +2 -2
  161. package/build/types/integrations/tracing/vercelai/instrumentation.d.ts.map +1 -1
  162. package/build/types/integrations/tracing/vercelai/types.d.ts +6 -4
  163. package/build/types/integrations/tracing/vercelai/types.d.ts.map +1 -1
  164. package/build/types/utils/setHttpServerSpanRouteAttribute.d.ts +9 -0
  165. package/build/types/utils/setHttpServerSpanRouteAttribute.d.ts.map +1 -0
  166. package/build/types-ts3.8/integrations/tracing/InstrumentationNodeModuleFile.d.ts +9 -0
  167. package/build/types-ts3.8/integrations/tracing/amqplib/vendored/utils.d.ts +2 -2
  168. package/build/types-ts3.8/integrations/tracing/anthropic-ai/index.d.ts +8 -7
  169. package/build/types-ts3.8/integrations/tracing/google-genai/index.d.ts +8 -7
  170. package/build/types-ts3.8/integrations/tracing/langchain/index.d.ts +9 -8
  171. package/build/types-ts3.8/integrations/tracing/langgraph/index.d.ts +8 -7
  172. package/build/types-ts3.8/integrations/tracing/lrumemoizer/vendored/instrumentation.d.ts +2 -2
  173. package/build/types-ts3.8/integrations/tracing/openai/index.d.ts +8 -7
  174. package/build/types-ts3.8/integrations/tracing/redis/index.d.ts +4 -1
  175. package/build/types-ts3.8/integrations/tracing/vercelai/instrumentation.d.ts +2 -2
  176. package/build/types-ts3.8/integrations/tracing/vercelai/types.d.ts +6 -4
  177. package/build/types-ts3.8/utils/setHttpServerSpanRouteAttribute.d.ts +9 -0
  178. package/package.json +5 -4
  179. package/build/cjs/integrations/tracing/redis/redis-dc-subscriber.js +0 -151
  180. package/build/cjs/integrations/tracing/redis/redis-dc-subscriber.js.map +0 -1
  181. package/build/esm/integrations/tracing/redis/redis-dc-subscriber.js +0 -149
  182. package/build/esm/integrations/tracing/redis/redis-dc-subscriber.js.map +0 -1
  183. package/build/types/integrations/tracing/redis/redis-dc-subscriber.d.ts +0 -17
  184. package/build/types/integrations/tracing/redis/redis-dc-subscriber.d.ts.map +0 -1
  185. package/build/types-ts3.8/integrations/tracing/redis/redis-dc-subscriber.d.ts +0 -17
@@ -74,9 +74,9 @@ function cleanupToolCallSpanContexts(content) {
74
74
  }
75
75
  }
76
76
  }
77
- function determineRecordingSettings(integrationRecordingOptions, methodTelemetryOptions, telemetryExplicitlyEnabled, defaultRecordingEnabled) {
78
- const recordInputs = integrationRecordingOptions?.recordInputs !== void 0 ? integrationRecordingOptions.recordInputs : methodTelemetryOptions.recordInputs !== void 0 ? methodTelemetryOptions.recordInputs : telemetryExplicitlyEnabled === true ? true : defaultRecordingEnabled;
79
- const recordOutputs = integrationRecordingOptions?.recordOutputs !== void 0 ? integrationRecordingOptions.recordOutputs : methodTelemetryOptions.recordOutputs !== void 0 ? methodTelemetryOptions.recordOutputs : telemetryExplicitlyEnabled === true ? true : defaultRecordingEnabled;
77
+ function determineRecordingSettings(integrationRecordingOptions, methodTelemetryOptions, telemetryExplicitlyEnabled, defaultInputsEnabled, defaultOutputsEnabled) {
78
+ const recordInputs = integrationRecordingOptions?.recordInputs !== void 0 ? integrationRecordingOptions.recordInputs : methodTelemetryOptions.recordInputs !== void 0 ? methodTelemetryOptions.recordInputs : telemetryExplicitlyEnabled === true ? true : defaultInputsEnabled;
79
+ const recordOutputs = integrationRecordingOptions?.recordOutputs !== void 0 ? integrationRecordingOptions.recordOutputs : methodTelemetryOptions.recordOutputs !== void 0 ? methodTelemetryOptions.recordOutputs : telemetryExplicitlyEnabled === true ? true : defaultOutputsEnabled;
80
80
  return { recordInputs, recordOutputs };
81
81
  }
82
82
  class SentryVercelAiInstrumentation extends InstrumentationBase {
@@ -118,12 +118,13 @@ class SentryVercelAiInstrumentation extends InstrumentationBase {
118
118
  const client = getClient();
119
119
  const integration = client?.getIntegrationByName(INTEGRATION_NAME);
120
120
  const integrationOptions = integration?.options;
121
- const shouldRecordInputsAndOutputs = integration ? Boolean(client?.getOptions().sendDefaultPii) : false;
121
+ const genAI = integration ? client?.getDataCollectionOptions().genAI : void 0;
122
122
  const { recordInputs, recordOutputs } = determineRecordingSettings(
123
123
  integrationOptions,
124
124
  existingExperimentalTelemetry,
125
125
  isEnabled,
126
- shouldRecordInputsAndOutputs
126
+ Boolean(genAI?.inputs),
127
+ Boolean(genAI?.outputs)
127
128
  );
128
129
  args[0].experimental_telemetry = {
129
130
  ...existingExperimentalTelemetry,
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.js","sources":["../../../../../src/integrations/tracing/vercelai/instrumentation.ts"],"sourcesContent":["import type { InstrumentationConfig, InstrumentationModuleDefinition } from '@opentelemetry/instrumentation';\nimport { InstrumentationBase, InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';\nimport {\n _INTERNAL_cleanupToolCallSpanContext,\n _INTERNAL_getSpanContextForToolCallId,\n addNonEnumerableProperty,\n captureException,\n getActiveSpan,\n getClient,\n handleCallbackErrors,\n SDK_VERSION,\n withScope,\n} from '@sentry/core';\nimport { INTEGRATION_NAME } from './constants';\nimport type { TelemetrySettings, VercelAiIntegration } from './types';\n\nconst SUPPORTED_VERSIONS = ['>=3.0.0 <7'];\n\n// List of patched methods\n// From: https://sdk.vercel.ai/docs/ai-sdk-core/telemetry#collected-data\nconst INSTRUMENTED_METHODS = [\n 'generateText',\n 'streamText',\n 'generateObject',\n 'streamObject',\n 'embed',\n 'embedMany',\n 'rerank',\n] as const;\n\ninterface MethodFirstArg extends Record<string, unknown> {\n experimental_telemetry?: TelemetrySettings;\n}\n\ntype MethodArgs = [MethodFirstArg, ...unknown[]];\n\ntype PatchedModuleExports = Record<(typeof INSTRUMENTED_METHODS)[number], (...args: MethodArgs) => unknown> &\n Record<string, unknown>;\n\ninterface RecordingOptions {\n recordInputs?: boolean;\n recordOutputs?: boolean;\n}\n\ninterface ToolError {\n type: 'tool-error' | 'tool-result' | 'tool-call';\n toolCallId: string;\n toolName: string;\n input?: {\n [key: string]: unknown;\n };\n error: Error;\n dynamic?: boolean;\n}\n\nfunction isToolError(obj: unknown): obj is ToolError {\n if (typeof obj !== 'object' || obj === null) {\n return false;\n }\n\n const candidate = obj as Record<string, unknown>;\n return (\n 'type' in candidate &&\n 'error' in candidate &&\n 'toolName' in candidate &&\n 'toolCallId' in candidate &&\n candidate.type === 'tool-error' &&\n candidate.error instanceof Error\n );\n}\n\n/**\n * Process tool call results: capture tool errors and clean up span context mappings.\n *\n * Error checking runs first (needs span context for linking), then cleanup removes all entries.\n * Tool errors are not rejected in Vercel AI V5 — they appear as metadata in the result content.\n */\nexport function processToolCallResults(result: unknown): void {\n if (typeof result !== 'object' || result === null || !('content' in result)) {\n return;\n }\n\n const resultObj = result as { content: Array<object> };\n if (!Array.isArray(resultObj.content)) {\n return;\n }\n\n captureToolErrors(resultObj.content);\n cleanupToolCallSpanContexts(resultObj.content);\n}\n\nfunction captureToolErrors(content: Array<object>): void {\n for (const item of content) {\n if (!isToolError(item)) {\n continue;\n }\n\n // Try to get the span context associated with this tool call ID\n const spanContext = _INTERNAL_getSpanContextForToolCallId(item.toolCallId);\n\n if (spanContext) {\n // We have the span context, so link the error using span and trace IDs\n withScope(scope => {\n scope.setContext('trace', {\n trace_id: spanContext.traceId,\n span_id: spanContext.spanId,\n });\n\n scope.setTag('vercel.ai.tool.name', item.toolName);\n scope.setTag('vercel.ai.tool.callId', item.toolCallId);\n scope.setLevel('error');\n\n captureException(item.error, {\n mechanism: {\n type: 'auto.vercelai.otel',\n handled: false,\n },\n });\n });\n } else {\n // Fallback: capture without span linking\n withScope(scope => {\n scope.setTag('vercel.ai.tool.name', item.toolName);\n scope.setTag('vercel.ai.tool.callId', item.toolCallId);\n scope.setLevel('error');\n\n captureException(item.error, {\n mechanism: {\n type: 'auto.vercelai.otel',\n handled: false,\n },\n });\n });\n }\n }\n}\n\n/**\n * Remove span context entries for all completed tool calls in the content array.\n */\nexport function cleanupToolCallSpanContexts(content: Array<object>): void {\n for (const item of content) {\n if (\n typeof item === 'object' &&\n item !== null &&\n 'toolCallId' in item &&\n typeof (item as Record<string, unknown>).toolCallId === 'string'\n ) {\n _INTERNAL_cleanupToolCallSpanContext((item as Record<string, unknown>).toolCallId as string);\n }\n }\n}\n\n/**\n * Determines whether to record inputs and outputs for Vercel AI telemetry based on the configuration hierarchy.\n *\n * The order of precedence is:\n * 1. The vercel ai integration options\n * 2. The experimental_telemetry options in the vercel ai method calls\n * 3. When telemetry is explicitly enabled (isEnabled: true), default to recording\n * 4. Otherwise, use the sendDefaultPii option from client options\n */\nexport function determineRecordingSettings(\n integrationRecordingOptions: RecordingOptions | undefined,\n methodTelemetryOptions: RecordingOptions,\n telemetryExplicitlyEnabled: boolean | undefined,\n defaultRecordingEnabled: boolean,\n): { recordInputs: boolean; recordOutputs: boolean } {\n const recordInputs =\n integrationRecordingOptions?.recordInputs !== undefined\n ? integrationRecordingOptions.recordInputs\n : methodTelemetryOptions.recordInputs !== undefined\n ? methodTelemetryOptions.recordInputs\n : telemetryExplicitlyEnabled === true\n ? true // When telemetry is explicitly enabled, default to recording inputs\n : defaultRecordingEnabled;\n\n const recordOutputs =\n integrationRecordingOptions?.recordOutputs !== undefined\n ? integrationRecordingOptions.recordOutputs\n : methodTelemetryOptions.recordOutputs !== undefined\n ? methodTelemetryOptions.recordOutputs\n : telemetryExplicitlyEnabled === true\n ? true // When telemetry is explicitly enabled, default to recording inputs\n : defaultRecordingEnabled;\n\n return { recordInputs, recordOutputs };\n}\n\n/**\n * This detects is added by the Sentry Vercel AI Integration to detect if the integration should\n * be enabled.\n *\n * It also patches the `ai` module to enable Vercel AI telemetry automatically for all methods.\n */\nexport class SentryVercelAiInstrumentation extends InstrumentationBase {\n private _isPatched = false;\n private _callbacks: (() => void)[] = [];\n\n public constructor(config: InstrumentationConfig = {}) {\n super('@sentry/instrumentation-vercel-ai', SDK_VERSION, config);\n }\n\n /**\n * Initializes the instrumentation by defining the modules to be patched.\n */\n public init(): InstrumentationModuleDefinition {\n const module = new InstrumentationNodeModuleDefinition('ai', SUPPORTED_VERSIONS, this._patch.bind(this));\n return module;\n }\n\n /**\n * Call the provided callback when the module is patched.\n * If it has already been patched, the callback will be called immediately.\n */\n public callWhenPatched(callback: () => void): void {\n if (this._isPatched) {\n callback();\n } else {\n this._callbacks.push(callback);\n }\n }\n\n /**\n * Patches module exports to enable Vercel AI telemetry.\n */\n private _patch(moduleExports: PatchedModuleExports): unknown {\n this._isPatched = true;\n\n this._callbacks.forEach(callback => callback());\n this._callbacks = [];\n\n const generatePatch = <T extends (...args: MethodArgs) => unknown>(originalMethod: T): T => {\n return new Proxy(originalMethod, {\n apply: (target, thisArg, args: MethodArgs) => {\n const existingExperimentalTelemetry = args[0].experimental_telemetry || {};\n const isEnabled = existingExperimentalTelemetry.isEnabled;\n\n const client = getClient();\n const integration = client?.getIntegrationByName<VercelAiIntegration>(INTEGRATION_NAME);\n const integrationOptions = integration?.options;\n const shouldRecordInputsAndOutputs = integration ? Boolean(client?.getOptions().sendDefaultPii) : false;\n\n const { recordInputs, recordOutputs } = determineRecordingSettings(\n integrationOptions,\n existingExperimentalTelemetry,\n isEnabled,\n shouldRecordInputsAndOutputs,\n );\n\n args[0].experimental_telemetry = {\n ...existingExperimentalTelemetry,\n isEnabled: isEnabled !== undefined ? isEnabled : true,\n recordInputs,\n recordOutputs,\n };\n\n return handleCallbackErrors(\n () => Reflect.apply(target, thisArg, args),\n error => {\n // This error bubbles up to unhandledrejection handler (if not handled before),\n // where we do not know the active span anymore\n // So to circumvent this, we set the active span on the error object\n // which is picked up by the unhandledrejection handler\n if (error && typeof error === 'object') {\n addNonEnumerableProperty(error, '_sentry_active_span', getActiveSpan());\n }\n },\n () => {},\n result => {\n processToolCallResults(result);\n },\n );\n },\n });\n };\n\n // Is this an ESM module?\n // https://tc39.es/ecma262/#sec-module-namespace-objects\n if (Object.prototype.toString.call(moduleExports) === '[object Module]') {\n // In ESM we take the usual route and just replace the exports we want to instrument\n for (const method of INSTRUMENTED_METHODS) {\n // Skip methods that don't exist in this version of the AI SDK (e.g., rerank was added in v6)\n if (moduleExports[method] != null) {\n moduleExports[method] = generatePatch(moduleExports[method]);\n }\n }\n\n return moduleExports;\n } else {\n // In CJS we can't replace the exports in the original module because they\n // don't have setters, so we create a new object with the same properties\n const patchedModuleExports = INSTRUMENTED_METHODS.reduce((acc, curr) => {\n // Skip methods that don't exist in this version of the AI SDK (e.g., rerank was added in v6)\n if (moduleExports[curr] != null) {\n acc[curr] = generatePatch(moduleExports[curr]);\n }\n return acc;\n }, {} as PatchedModuleExports);\n\n return { ...moduleExports, ...patchedModuleExports };\n }\n }\n}\n"],"names":[],"mappings":";;;;AAgBA,MAAM,kBAAA,GAAqB,CAAC,YAAY,CAAA;AAIxC,MAAM,oBAAA,GAAuB;AAAA,EAC3B,cAAA;AAAA,EACA,YAAA;AAAA,EACA,gBAAA;AAAA,EACA,cAAA;AAAA,EACA,OAAA;AAAA,EACA,WAAA;AAAA,EACA;AACF,CAAA;AA2BA,SAAS,YAAY,GAAA,EAAgC;AACnD,EAAA,IAAI,OAAO,GAAA,KAAQ,QAAA,IAAY,GAAA,KAAQ,IAAA,EAAM;AAC3C,IAAA,OAAO,KAAA;AAAA,EACT;AAEA,EAAA,MAAM,SAAA,GAAY,GAAA;AAClB,EAAA,OACE,MAAA,IAAU,SAAA,IACV,OAAA,IAAW,SAAA,IACX,UAAA,IAAc,SAAA,IACd,YAAA,IAAgB,SAAA,IAChB,SAAA,CAAU,IAAA,KAAS,YAAA,IACnB,SAAA,CAAU,KAAA,YAAiB,KAAA;AAE/B;AAQO,SAAS,uBAAuB,MAAA,EAAuB;AAC5D,EAAA,IAAI,OAAO,MAAA,KAAW,QAAA,IAAY,WAAW,IAAA,IAAQ,EAAE,aAAa,MAAA,CAAA,EAAS;AAC3E,IAAA;AAAA,EACF;AAEA,EAAA,MAAM,SAAA,GAAY,MAAA;AAClB,EAAA,IAAI,CAAC,KAAA,CAAM,OAAA,CAAQ,SAAA,CAAU,OAAO,CAAA,EAAG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,CAAc,IAAI,CAAC,CAAA;AAAA,QAC/C;AACA,QAAA,OAAO,GAAA;AAAA,MACT,CAAA,EAAG,EAA0B,CAAA;AAE7B,MAAA,OAAO,EAAE,GAAG,aAAA,EAAe,GAAG,oBAAA,EAAqB;AAAA,IACrD;AAAA,EACF;AACF;;;;"}
1
+ {"version":3,"file":"instrumentation.js","sources":["../../../../../src/integrations/tracing/vercelai/instrumentation.ts"],"sourcesContent":["import type { InstrumentationConfig, InstrumentationModuleDefinition } from '@opentelemetry/instrumentation';\nimport { InstrumentationBase, InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';\nimport {\n _INTERNAL_cleanupToolCallSpanContext,\n _INTERNAL_getSpanContextForToolCallId,\n addNonEnumerableProperty,\n captureException,\n getActiveSpan,\n getClient,\n handleCallbackErrors,\n SDK_VERSION,\n withScope,\n} from '@sentry/core';\nimport { INTEGRATION_NAME } from './constants';\nimport type { TelemetrySettings, VercelAiIntegration } from './types';\n\nconst SUPPORTED_VERSIONS = ['>=3.0.0 <7'];\n\n// List of patched methods\n// From: https://sdk.vercel.ai/docs/ai-sdk-core/telemetry#collected-data\nconst INSTRUMENTED_METHODS = [\n 'generateText',\n 'streamText',\n 'generateObject',\n 'streamObject',\n 'embed',\n 'embedMany',\n 'rerank',\n] as const;\n\ninterface MethodFirstArg extends Record<string, unknown> {\n experimental_telemetry?: TelemetrySettings;\n}\n\ntype MethodArgs = [MethodFirstArg, ...unknown[]];\n\ntype PatchedModuleExports = Record<(typeof INSTRUMENTED_METHODS)[number], (...args: MethodArgs) => unknown> &\n Record<string, unknown>;\n\ninterface RecordingOptions {\n recordInputs?: boolean;\n recordOutputs?: boolean;\n}\n\ninterface ToolError {\n type: 'tool-error' | 'tool-result' | 'tool-call';\n toolCallId: string;\n toolName: string;\n input?: {\n [key: string]: unknown;\n };\n error: Error;\n dynamic?: boolean;\n}\n\nfunction isToolError(obj: unknown): obj is ToolError {\n if (typeof obj !== 'object' || obj === null) {\n return false;\n }\n\n const candidate = obj as Record<string, unknown>;\n return (\n 'type' in candidate &&\n 'error' in candidate &&\n 'toolName' in candidate &&\n 'toolCallId' in candidate &&\n candidate.type === 'tool-error' &&\n candidate.error instanceof Error\n );\n}\n\n/**\n * Process tool call results: capture tool errors and clean up span context mappings.\n *\n * Error checking runs first (needs span context for linking), then cleanup removes all entries.\n * Tool errors are not rejected in Vercel AI V5 — they appear as metadata in the result content.\n */\nexport function processToolCallResults(result: unknown): void {\n if (typeof result !== 'object' || result === null || !('content' in result)) {\n return;\n }\n\n const resultObj = result as { content: Array<object> };\n if (!Array.isArray(resultObj.content)) {\n return;\n }\n\n captureToolErrors(resultObj.content);\n cleanupToolCallSpanContexts(resultObj.content);\n}\n\nfunction captureToolErrors(content: Array<object>): void {\n for (const item of content) {\n if (!isToolError(item)) {\n continue;\n }\n\n // Try to get the span context associated with this tool call ID\n const spanContext = _INTERNAL_getSpanContextForToolCallId(item.toolCallId);\n\n if (spanContext) {\n // We have the span context, so link the error using span and trace IDs\n withScope(scope => {\n scope.setContext('trace', {\n trace_id: spanContext.traceId,\n span_id: spanContext.spanId,\n });\n\n scope.setTag('vercel.ai.tool.name', item.toolName);\n scope.setTag('vercel.ai.tool.callId', item.toolCallId);\n scope.setLevel('error');\n\n captureException(item.error, {\n mechanism: {\n type: 'auto.vercelai.otel',\n handled: false,\n },\n });\n });\n } else {\n // Fallback: capture without span linking\n withScope(scope => {\n scope.setTag('vercel.ai.tool.name', item.toolName);\n scope.setTag('vercel.ai.tool.callId', item.toolCallId);\n scope.setLevel('error');\n\n captureException(item.error, {\n mechanism: {\n type: 'auto.vercelai.otel',\n handled: false,\n },\n });\n });\n }\n }\n}\n\n/**\n * Remove span context entries for all completed tool calls in the content array.\n */\nexport function cleanupToolCallSpanContexts(content: Array<object>): void {\n for (const item of content) {\n if (\n typeof item === 'object' &&\n item !== null &&\n 'toolCallId' in item &&\n typeof (item as Record<string, unknown>).toolCallId === 'string'\n ) {\n _INTERNAL_cleanupToolCallSpanContext((item as Record<string, unknown>).toolCallId as string);\n }\n }\n}\n\n/**\n * Determines whether to record inputs and outputs for Vercel AI telemetry based on the configuration hierarchy.\n *\n * The order of precedence is:\n * 1. The vercel ai integration options\n * 2. The experimental_telemetry options in the vercel ai method calls\n * 3. When telemetry is explicitly enabled (isEnabled: true), default to recording\n * 4. Otherwise, use the dataCollection.genAI settings from client options\n */\nexport function determineRecordingSettings(\n integrationRecordingOptions: RecordingOptions | undefined,\n methodTelemetryOptions: RecordingOptions,\n telemetryExplicitlyEnabled: boolean | undefined,\n defaultInputsEnabled: boolean,\n defaultOutputsEnabled: boolean,\n): { recordInputs: boolean; recordOutputs: boolean } {\n const recordInputs =\n integrationRecordingOptions?.recordInputs !== undefined\n ? integrationRecordingOptions.recordInputs\n : methodTelemetryOptions.recordInputs !== undefined\n ? methodTelemetryOptions.recordInputs\n : telemetryExplicitlyEnabled === true\n ? true // When telemetry is explicitly enabled, default to recording inputs\n : defaultInputsEnabled;\n\n const recordOutputs =\n integrationRecordingOptions?.recordOutputs !== undefined\n ? integrationRecordingOptions.recordOutputs\n : methodTelemetryOptions.recordOutputs !== undefined\n ? methodTelemetryOptions.recordOutputs\n : telemetryExplicitlyEnabled === true\n ? true // When telemetry is explicitly enabled, default to recording outputs\n : defaultOutputsEnabled;\n\n return { recordInputs, recordOutputs };\n}\n\n/**\n * This detects is added by the Sentry Vercel AI Integration to detect if the integration should\n * be enabled.\n *\n * It also patches the `ai` module to enable Vercel AI telemetry automatically for all methods.\n */\nexport class SentryVercelAiInstrumentation extends InstrumentationBase {\n private _isPatched = false;\n private _callbacks: (() => void)[] = [];\n\n public constructor(config: InstrumentationConfig = {}) {\n super('@sentry/instrumentation-vercel-ai', SDK_VERSION, config);\n }\n\n /**\n * Initializes the instrumentation by defining the modules to be patched.\n */\n public init(): InstrumentationModuleDefinition {\n const module = new InstrumentationNodeModuleDefinition('ai', SUPPORTED_VERSIONS, this._patch.bind(this));\n return module;\n }\n\n /**\n * Call the provided callback when the module is patched.\n * If it has already been patched, the callback will be called immediately.\n */\n public callWhenPatched(callback: () => void): void {\n if (this._isPatched) {\n callback();\n } else {\n this._callbacks.push(callback);\n }\n }\n\n /**\n * Patches module exports to enable Vercel AI telemetry.\n */\n private _patch(moduleExports: PatchedModuleExports): unknown {\n this._isPatched = true;\n\n this._callbacks.forEach(callback => callback());\n this._callbacks = [];\n\n const generatePatch = <T extends (...args: MethodArgs) => unknown>(originalMethod: T): T => {\n return new Proxy(originalMethod, {\n apply: (target, thisArg, args: MethodArgs) => {\n const existingExperimentalTelemetry = args[0].experimental_telemetry || {};\n const isEnabled = existingExperimentalTelemetry.isEnabled;\n\n const client = getClient();\n const integration = client?.getIntegrationByName<VercelAiIntegration>(INTEGRATION_NAME);\n const integrationOptions = integration?.options;\n const genAI = integration ? client?.getDataCollectionOptions().genAI : undefined;\n\n const { recordInputs, recordOutputs } = determineRecordingSettings(\n integrationOptions,\n existingExperimentalTelemetry,\n isEnabled,\n Boolean(genAI?.inputs),\n Boolean(genAI?.outputs),\n );\n\n args[0].experimental_telemetry = {\n ...existingExperimentalTelemetry,\n isEnabled: isEnabled !== undefined ? isEnabled : true,\n recordInputs,\n recordOutputs,\n };\n\n return handleCallbackErrors(\n () => Reflect.apply(target, thisArg, args),\n error => {\n // This error bubbles up to unhandledrejection handler (if not handled before),\n // where we do not know the active span anymore\n // So to circumvent this, we set the active span on the error object\n // which is picked up by the unhandledrejection handler\n if (error && typeof error === 'object') {\n addNonEnumerableProperty(error, '_sentry_active_span', getActiveSpan());\n }\n },\n () => {},\n result => {\n processToolCallResults(result);\n },\n );\n },\n });\n };\n\n // Is this an ESM module?\n // https://tc39.es/ecma262/#sec-module-namespace-objects\n if (Object.prototype.toString.call(moduleExports) === '[object Module]') {\n // In ESM we take the usual route and just replace the exports we want to instrument\n for (const method of INSTRUMENTED_METHODS) {\n // Skip methods that don't exist in this version of the AI SDK (e.g., rerank was added in v6)\n if (moduleExports[method] != null) {\n moduleExports[method] = generatePatch(moduleExports[method]);\n }\n }\n\n return moduleExports;\n } else {\n // In CJS we can't replace the exports in the original module because they\n // don't have setters, so we create a new object with the same properties\n const patchedModuleExports = INSTRUMENTED_METHODS.reduce((acc, curr) => {\n // Skip methods that don't exist in this version of the AI SDK (e.g., rerank was added in v6)\n if (moduleExports[curr] != null) {\n acc[curr] = generatePatch(moduleExports[curr]);\n }\n return acc;\n }, {} as PatchedModuleExports);\n\n return { ...moduleExports, ...patchedModuleExports };\n }\n }\n}\n"],"names":[],"mappings":";;;;AAgBA,MAAM,kBAAA,GAAqB,CAAC,YAAY,CAAA;AAIxC,MAAM,oBAAA,GAAuB;AAAA,EAC3B,cAAA;AAAA,EACA,YAAA;AAAA,EACA,gBAAA;AAAA,EACA,cAAA;AAAA,EACA,OAAA;AAAA,EACA,WAAA;AAAA,EACA;AACF,CAAA;AA2BA,SAAS,YAAY,GAAA,EAAgC;AACnD,EAAA,IAAI,OAAO,GAAA,KAAQ,QAAA,IAAY,GAAA,KAAQ,IAAA,EAAM;AAC3C,IAAA,OAAO,KAAA;AAAA,EACT;AAEA,EAAA,MAAM,SAAA,GAAY,GAAA;AAClB,EAAA,OACE,MAAA,IAAU,SAAA,IACV,OAAA,IAAW,SAAA,IACX,UAAA,IAAc,SAAA,IACd,YAAA,IAAgB,SAAA,IAChB,SAAA,CAAU,IAAA,KAAS,YAAA,IACnB,SAAA,CAAU,KAAA,YAAiB,KAAA;AAE/B;AAQO,SAAS,uBAAuB,MAAA,EAAuB;AAC5D,EAAA,IAAI,OAAO,MAAA,KAAW,QAAA,IAAY,WAAW,IAAA,IAAQ,EAAE,aAAa,MAAA,CAAA,EAAS;AAC3E,IAAA;AAAA,EACF;AAEA,EAAA,MAAM,SAAA,GAAY,MAAA;AAClB,EAAA,IAAI,CAAC,KAAA,CAAM,OAAA,CAAQ,SAAA,CAAU,OAAO,CAAA,EAAG;AACrC,IAAA;AAAA,EACF;AAEA,EAAA,iBAAA,CAAkB,UAAU,OAAO,CAAA;AACnC,EA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I,CAAC,CAAA;AAAA,QAC/C;AACA,QAAA,OAAO,GAAA;AAAA,MACT,CAAA,EAAG,EAA0B,CAAA;AAE7B,MAAA,OAAO,EAAE,GAAG,aAAA,EAAe,GAAG,oBAAA,EAAqB;AAAA,IACrD;AAAA,EACF;AACF;;;;"}
@@ -1 +1 @@
1
- {"type":"module","version":"10.55.0","sideEffects":false}
1
+ {"type":"module","version":"10.57.0","sideEffects":false}
@@ -0,0 +1,19 @@
1
+ import { getActiveSpan, getRootSpan, spanToJSON, SEMANTIC_ATTRIBUTE_SENTRY_OP } from '@sentry/core';
2
+
3
+ function setHttpServerSpanRouteAttribute(route) {
4
+ const activeSpan = getActiveSpan();
5
+ if (!activeSpan) {
6
+ return;
7
+ }
8
+ const rootSpan = getRootSpan(activeSpan);
9
+ if (!rootSpan) {
10
+ return;
11
+ }
12
+ if (spanToJSON(rootSpan).data[SEMANTIC_ATTRIBUTE_SENTRY_OP] !== "http.server") {
13
+ return;
14
+ }
15
+ rootSpan.setAttribute("http.route", route);
16
+ }
17
+
18
+ export { setHttpServerSpanRouteAttribute };
19
+ //# sourceMappingURL=setHttpServerSpanRouteAttribute.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setHttpServerSpanRouteAttribute.js","sources":["../../../src/utils/setHttpServerSpanRouteAttribute.ts"],"sourcesContent":["import { getActiveSpan, getRootSpan, SEMANTIC_ATTRIBUTE_SENTRY_OP, spanToJSON } from '@sentry/core';\n\n/**\n * Set the `http.route` attribute on the root HTTP server span for the current trace.\n *\n * No-op when there is no active span, no root span, or the root span is not an\n * `http.server` span — so framework instrumentations can call this unconditionally\n * without risking attribute pollution on non-HTTP root spans.\n */\nexport function setHttpServerSpanRouteAttribute(route: string): void {\n const activeSpan = getActiveSpan();\n if (!activeSpan) {\n return;\n }\n const rootSpan = getRootSpan(activeSpan);\n if (!rootSpan) {\n return;\n }\n if (spanToJSON(rootSpan).data[SEMANTIC_ATTRIBUTE_SENTRY_OP] !== 'http.server') {\n return;\n }\n rootSpan.setAttribute('http.route', route);\n}\n"],"names":[],"mappings":";;AASO,SAAS,gCAAgC,KAAA,EAAqB;AACnE,EAAA,MAAM,aAAa,aAAA,EAAc;AACjC,EAAA,IAAI,CAAC,UAAA,EAAY;AACf,IAAA;AAAA,EACF;AACA,EAAA,MAAM,QAAA,GAAW,YAAY,UAAU,CAAA;AACvC,EAAA,IAAI,CAAC,QAAA,EAAU;AACb,IAAA;AAAA,EACF;AACA,EAAA,IAAI,WAAW,QAAQ,CAAA,CAAE,IAAA,CAAK,4BAA4B,MAAM,aAAA,EAAe;AAC7E,IAAA;AAAA,EACF;AACA,EAAA,QAAA,CAAS,YAAA,CAAa,cAAc,KAAK,CAAA;AAC3C;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"undici.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/node-fetch/vendored/undici.ts"],"names":[],"mappings":"AA0BA,OAAO,EAAE,mBAAmB,EAA0B,MAAM,gCAAgC,CAAC;AAoC7F,OAAO,KAAK,EAAE,2BAA2B,EAAiB,MAAM,SAAS,CAAC;AAc1E,qBAAa,qBAAsB,SAAQ,mBAAmB,CAAC,2BAA2B,CAAC;IAGzF,QAAgB,YAAY,CAAwB;IACpD,OAAO,CAAC,cAAc,CAAuD;IAE7E,QAAgB,4BAA4B,CAAY;gBAE5C,MAAM,GAAE,2BAAgC;cAKjC,IAAI;IAId,OAAO,IAAI,IAAI;IAMf,MAAM,IAAI,IAAI;cA4BJ,wBAAwB;IAW3C,OAAO,CAAC,kBAAkB;IAyB1B,OAAO,CAAC,mBAAmB;IA+C3B,OAAO,CAAC,gBAAgB;IAgIxB,OAAO,CAAC,gBAAgB;IAmCxB,OAAO,CAAC,iBAAiB;IAqDzB,OAAO,CAAC,MAAM;IAuBd,OAAO,CAAC,OAAO;IA4Bf,OAAO,CAAC,qBAAqB;IAuB7B,OAAO,CAAC,gBAAgB;CAqBzB"}
1
+ {"version":3,"file":"undici.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/node-fetch/vendored/undici.ts"],"names":[],"mappings":"AA0BA,OAAO,EAAE,mBAAmB,EAA0B,MAAM,gCAAgC,CAAC;AAmC7F,OAAO,KAAK,EAAE,2BAA2B,EAAiB,MAAM,SAAS,CAAC;AAc1E,qBAAa,qBAAsB,SAAQ,mBAAmB,CAAC,2BAA2B,CAAC;IAGzF,QAAgB,YAAY,CAAwB;IACpD,OAAO,CAAC,cAAc,CAAuD;IAE7E,QAAgB,4BAA4B,CAAY;gBAE5C,MAAM,GAAE,2BAAgC;cAKjC,IAAI;IAId,OAAO,IAAI,IAAI;IAMf,MAAM,IAAI,IAAI;cA4BJ,wBAAwB;IAW3C,OAAO,CAAC,kBAAkB;IAyB1B,OAAO,CAAC,mBAAmB;IA+C3B,OAAO,CAAC,gBAAgB;IAgIxB,OAAO,CAAC,gBAAgB;IAmCxB,OAAO,CAAC,iBAAiB;IAqDzB,OAAO,CAAC,MAAM;IAuBd,OAAO,CAAC,OAAO;IA4Bf,OAAO,CAAC,qBAAqB;IAuB7B,OAAO,CAAC,gBAAgB;CAqBzB"}
@@ -0,0 +1,9 @@
1
+ import type { InstrumentationModuleFile } from '@opentelemetry/instrumentation';
2
+ export declare class InstrumentationNodeModuleFile implements InstrumentationModuleFile {
3
+ name: string;
4
+ supportedVersions: string[];
5
+ patch: (moduleExports: any, moduleVersion?: string) => any;
6
+ unpatch: (moduleExports?: any, moduleVersion?: string) => void;
7
+ constructor(name: string, supportedVersions: string[], patch: (moduleExports: any, moduleVersion?: string) => any, unpatch: (moduleExports?: any, moduleVersion?: string) => void);
8
+ }
9
+ //# sourceMappingURL=InstrumentationNodeModuleFile.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InstrumentationNodeModuleFile.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/InstrumentationNodeModuleFile.ts"],"names":[],"mappings":"AAyBA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,gCAAgC,CAAC;AAEhF,qBAAa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CAAC,wBAAwB;IAmFhC,OAAO,CAAC,eAAe;IAgDvB,OAAO,CAAC,iBAAiB;IA6BzB,OAAO,CAAC,eAAe;IAwBvB,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,kBAAkB;IAoB1B,OAAO,CAAC,4BAA4B;CAerC"}
1
+ {"version":3,"file":"amqplib.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/amqplib/vendored/amqplib.ts"],"names":[],"mappings":"AAkCA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAKpC,MAAM,gCAAgC,CAAC;AAaxC,OAAO,EAAE,4BAA4B,EAAmE,MAAM,SAAS,CAAC;AAwBxH,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;IAC3F,OAAO,CAAC,oBAAoB,CAAoB;gBAEpC,MAAM,GAAE,4BAAiC;IAMrD,OAAO,CAAC,2BAA2B;IAI1B,SAAS,CAAC,MAAM,GAAE,4BAAiC;IAI5D,SAAS,CAAC,IAAI;IA8Bd,OAAO,CAAC,YAAY;IAQpB,OAAO,CAAC,cAAc;IAOtB,OAAO,CAAC,iBAAiB;IAuCzB,OAAO,CAAC,mBAAmB;IA+B3B,OAAO,CAAC,eAAe;IAiCvB,OAAO,CAAC,mBAAmB;IAiB3B,OAAO,CAAC,cAAc;IAQtB,OAAO,CAAC,WAAW;IA+BnB,OAAO,CAAC,eAAe;IAoGvB,OAAO,CAAC,wBAAwB;IAmFhC,OAAO,CAAC,eAAe;IAgDvB,OAAO,CAAC,iBAAiB;IA6BzB,OAAO,CAAC,eAAe;IAwBvB,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,kBAAkB;IAoB1B,OAAO,CAAC,4BAA4B;CAerC"}
@@ -1,4 +1,4 @@
1
- import { Context, HrTime, Span, Attributes } from '@opentelemetry/api';
1
+ import { Context, Span, Attributes } from '@opentelemetry/api';
2
2
  import { SemconvStability } from '@opentelemetry/instrumentation';
3
3
  import type { Connection, Channel, ConfirmChannel, Options } from './amqplib-types';
4
4
  import type { ConsumeMessage, Message } from './types';
@@ -16,7 +16,7 @@ export type InstrumentationConsumeChannel = Channel & {
16
16
  connection: InstrumentationConnection;
17
17
  [CHANNEL_SPANS_NOT_ENDED]?: {
18
18
  msg: ConsumeMessage;
19
- timeOfConsume: HrTime;
19
+ timeOfConsume: number;
20
20
  }[];
21
21
  [CHANNEL_CONSUME_TIMEOUT_TIMER]?: NodeJS.Timeout;
22
22
  };
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/amqplib/vendored/utils.ts"],"names":[],"mappings":"AAsBA,OAAO,EAAE,OAAO,EAA0B,MAAM,EAAE,IAAI,EAAE,UAAU,EAAkB,MAAM,oBAAoB,CAAC;AAC/G,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAIlE,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AACpF,OAAO,KAAK,EAAE,cAAc,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAEvD,eAAO,MAAM,mBAAmB,EAAE,OAAO,MAA4D,CAAC;AACtG,eAAO,MAAM,uBAAuB,EAAE,OAAO,MAAgE,CAAC;AAC9G,eAAO,MAAM,6BAA6B,EAAE,OAAO,MAElD,CAAC;AACF,eAAO,MAAM,qBAAqB,EAAE,OAAO,MAA8D,CAAC;AAE1G,MAAM,MAAM,yBAAyB,GAAG,UAAU,GAAG;IACnD,CAAC,qBAAqB,CAAC,CAAC,EAAE,UAAU,CAAC;CACtC,CAAC;AACF,MAAM,MAAM,6BAA6B,GAAG,CAAC,OAAO,GAAG,cAAc,CAAC,GAAG;IACvE,UAAU,EAAE,yBAAyB,CAAC;CACvC,CAAC;AACF,MAAM,MAAM,6BAA6B,GAAG,OAAO,GAAG;IACpD,UAAU,EAAE,yBAAyB,CAAC;IACtC,CAAC,uBAAuB,CAAC,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B,GAAI,SAAS,OAAO,YAEvD,CAAC"}
@@ -21,18 +21,19 @@ export declare const instrumentAnthropicAi: ((options?: AnthropicAiOptions | und
21
21
  *
22
22
  * ## Options
23
23
  *
24
- * - `recordInputs`: Whether to record prompt messages (default: respects `sendDefaultPii` client option)
25
- * - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
24
+ * - `recordInputs`: Whether to record prompt messages (default: follows `dataCollection.genAI.inputs`, or the deprecated `sendDefaultPii` option)
25
+ * - `recordOutputs`: Whether to record response text (default: follows `dataCollection.genAI.outputs`, or the deprecated `sendDefaultPii` option)
26
26
  *
27
27
  * ### Default Behavior
28
28
  *
29
29
  * By default, the integration will:
30
- * - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
31
- * - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
30
+ * - Record inputs and outputs based on `dataCollection.genAI` in your Sentry client options
31
+ * (or the deprecated `sendDefaultPii` option, for backwards compatibility)
32
+ * - Integration-level `recordInputs`/`recordOutputs` options take precedence over global config
32
33
  *
33
34
  * @example
34
35
  * ```javascript
35
- * // Record inputs and outputs when sendDefaultPii is false
36
+ * // Always record inputs and outputs regardless of global dataCollection config
36
37
  * Sentry.init({
37
38
  * integrations: [
38
39
  * Sentry.anthropicAIIntegration({
@@ -42,9 +43,9 @@ export declare const instrumentAnthropicAi: ((options?: AnthropicAiOptions | und
42
43
  * ],
43
44
  * });
44
45
  *
45
- * // Never record inputs/outputs regardless of sendDefaultPii
46
+ * // Never record inputs/outputs regardless of global dataCollection config
46
47
  * Sentry.init({
47
- * sendDefaultPii: true,
48
+ * dataCollection: { genAI: { inputs: true, outputs: true } },
48
49
  * integrations: [
49
50
  * Sentry.anthropicAIIntegration({
50
51
  * recordInputs: false,
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/anthropic-ai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAiB,MAAM,cAAc,CAAC;AAKtE,eAAO,MAAM,qBAAqB;;CAGjC,CAAC;AAYF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,eAAO,MAAM,sBAAsB,kFAA6C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/anthropic-ai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAiB,MAAM,cAAc,CAAC;AAKtE,eAAO,MAAM,qBAAqB;;CAGjC,CAAC;AAYF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDG;AACH,eAAO,MAAM,sBAAsB,kFAA6C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/connect/vendored/instrumentation.ts"],"names":[],"mappings":"AAsBA,OAAO,EAAW,IAAI,EAAe,MAAM,oBAAoB,CAAC;AAIhE,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,EAAkB,GAAG,EAAqB,MAAM,kBAAkB,CAAC;AAEhH,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AAMxC,eAAO,MAAM,cAAc,cAAc,CAAC;AAE1C,gDAAgD;AAChD,qBAAa,sBAAuB,SAAQ,mBAAmB;gBACjD,MAAM,GAAE,qBAA0B;IAI9C,IAAI;IAQJ,OAAO,CAAC,SAAS;IASjB,OAAO,CAAC,iBAAiB;IASlB,UAAU,CAAC,IAAI,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,IAAI,GAAG,YAAY;IAQpE,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE,UAAU,EAAE,cAAc,GAAG,IAAI;IAyB/D,gBAAgB,CAAC,SAAS,EAAE,MAAM,EAAE,UAAU,EAAE,cAAc,G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Y;CAM7E"}
@@ -1 +1 @@
1
- {"version":3,"file":"express.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/express.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,mCAAmC,EAAE,MAAM,gCAAgC,CAAC;AAK1G,OAAO,EACL,KAAK,yBAAyB,EAO9B,KAAK,qBAAqB,EAC3B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAMnD,wBAAgB,wBAAwB,CAEtC,GAAG,EAAE;IAAE,GAAG,EAAE,CAAC,UAAU,EAAE,GAAG,KAAK,OAAO,CAAA;CAAE,EAC1C,OAAO,CAAC,EAAE,qBAAqB,GAC9B,IAAI,CAGN;AAED,MAAM,MAAM,4BAA4B,GAAG,qBAAqB,GAC9D,IAAI,CAAC,yBAAyB,EAAE,SAAS,GAAG,iBAAiB,CAAC,CAAC;AAEjE,eAAO,MAAM,iBAAiB;;CAG7B,CAAC;AAEF,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;gBACxE,MAAM,GAAE,4BAAiC;IAGrD,IAAI,IAAI,mCAAmC;CAyBnD;AAUD,eAAO,MAAM,kBAAkB,4FAAyC,CAAC"}
1
+ {"version":3,"file":"express.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/express.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAC5E,OAAO,EAAE,mBAAmB,EAAE,mCAAmC,EAAE,MAAM,gCAAgC,CAAC;AAG1G,OAAO,EACL,KAAK,yBAAyB,EAO9B,KAAK,qBAAqB,EAC3B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAOnD,wBAAgB,wBAAwB,CAEtC,GAAG,EAAE;IAAE,GAAG,EAAE,CAAC,UAAU,EAAE,GAAG,KAAK,OAAO,CAAA;CAAE,EAC1C,OAAO,CAAC,EAAE,qBAAqB,GAC9B,IAAI,CAGN;AAED,MAAM,MAAM,4BAA4B,GAAG,qBAAqB,GAC9D,IAAI,CAAC,yBAAyB,EAAE,SAAS,GAAG,iBAAiB,CAAC,CAAC;AAEjE,eAAO,MAAM,iBAAiB;;CAG7B,CAAC;AAEF,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;gBACxE,MAAM,GAAE,4BAAiC;IAGrD,IAAI,IAAI,mCAAmC;CAwBnD;AAUD,eAAO,MAAM,kBAAkB,4FAAyC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AAoBxC,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,SAAS,CAAC;AAyB5D;;GAEG;AACH,qBAAa,wBAAyB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;gBAC1E,MAAM,GAAE,4BAAiC;IAIrD,IAAI,IAAI,mCAAmC,EAAE;IAQpD,OAAO,CAAC,cAAc;IA0BtB,OAAO,CAAC,YAAY;IAwDpB,OAAO,CAAC,YAAY;IAyBpB,OAAO,CAAC,iBAAiB;IA0BzB,OAAO,CAAC,UAAU;IA4BlB,OAAO,CAAC,eAAe;CA+CxB"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/instrumentation.ts"],"names":[],"mappings":"AAwBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AAqBxC,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,SAAS,CAAC;AAyB5D;;GAEG;AACH,qBAAa,wBAAyB,SAAQ,mBAA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,GAAG,KAAK,IAAI,CAAC,GAAG,IAAI,CAAQ;IAChE,qBAAqB,EAAE,CAAC,CAAC,OAAO,EAAE,GAAG,KAAK,IAAI,CAAC,GAAG,SAAS,CAAa;IAExE,CAAC,iBAAiB,CAAC,EAAE,OAAO,CAAQ;gBAExB,MAAM,GAAE,8BAAmC;IAoBvD,MAAM,IAAI,GAAG;IAgBb,OAAO,IAAI,GAAG;IAQd,IAAI;IAIJ,MAAM,IAAI,GAAG;CA2Wd"}
@@ -1 +1 @@
1
- {"version":3,"file":"firestore.d.ts","sourceRoot":"","sources":["../../../../../../../src/integrations/tracing/firebase/otel/patches/firestore.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAEvD,OAAO,EACL,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AAWxC,OAAO,KAAK,EAOV,6BAA6B,EAE7B,iBAAiB,EAQlB,MAAM,UAAU,CAAC;AAKlB,KAAK,WAAW,GAAG,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,KAAK,IAAI,CAAC;AAEzF,KAAK,aAAa,GAAG,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAEzD;;;;;;GAMG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,0BAA0B,EAAE,MAAM,EAAE,EACpC,IAAI,EAAE,WAAW,EACjB,MAAM,EAAE,aAAa,EACrB,MAAM,EAAE,6BAA6B,GACpC,mCAAmC,CA8CrC;AA0JD;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,iBAAiB,GAAG;IAC9D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAwCA"}
1
+ {"version":3,"file":"firestore.d.ts","sourceRoot":"","sources":["../../../../../../../src/integrations/tracing/firebase/otel/patches/firestore.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAEvD,OAAO,EAAE,mCAAmC,EAAqC,MAAM,gCAAgC,CAAC;AAYxH,OAAO,KAAK,EAOV,6BAA6B,EAE7B,iBAAiB,EAQlB,MAAM,UAAU,CAAC;AAKlB,KAAK,WAAW,GAAG,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,GAAG,KAAK,IAAI,CAAC;AAEzF,KAAK,aAAa,GAAG,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAEzD;;;;;;GAMG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,0BAA0B,EAAE,MAAM,EAAE,EACpC,IAAI,EAAE,WAAW,EACjB,MAAM,EAAE,aAAa,EACrB,MAAM,EAAE,6BAA6B,GACpC,mCAAmC,CA8CrC;AA0JD;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,iBAAiB,GAAG;IAC9D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAwCA"}
@@ -1 +1 @@
1
- {"version":3,"file":"functions.d.ts","sourceRoot":"","sources":["../../../../../../../src/integrations/tracing/firebase/otel/patches/functions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAQ,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAEvD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAC1E,OAAO,EACL,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AAGxC,OAAO,KAAK,EAEV,iBAAiB,EACjB,6BAA6B,EAC7B,oBAAoB,EAGrB,MAAM,UAAU,CAAC;AAElB;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,0BAA0B,EAAE,MAAM,EAAE,EACpC,IAAI,EAAE,mBAAmB,CAAC,OAAO,CAAC,EAClC,MAAM,EAAE,mBAAmB,CAAC,SAAS,CAAC,EACtC,MAAM,EAAE,6BAA6B,GACpC,mCAAmC,CAgErC;AAED;;;;;;;GAOG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,iBAAiB,GAAG,iBAAiB,EAC9E,MAAM,EAAE,MAAM,EACd,eAAe,EAAE,6BAA6B,CAAC,WAAW,CAAC,EAC3D,WAAW,EAAE,MAAM,GAClB,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,GAAG,IAAI,EAAE,oBAAoB,CAAC,CAAC,CAAC,KAAK,UAAU,CAAC,CAAC,CAAC,CAqEtE"}
1
+ {"version":3,"file":"functions.d.ts","sourceRoot":"","sources":["../../../../../../../src/integrations/tracing/firebase/otel/patches/functions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAQ,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAEvD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAC1E,OAAO,EAAE,mCAAmC,EAAqC,MAAM,gCAAgC,CAAC;AAIxH,OAAO,KAAK,EAEV,iBAAiB,EACjB,6BAA6B,EAC7B,oBAAoB,EAGrB,MAAM,UAAU,CAAC;AAElB;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAC5B,MAAM,EAAE,MAAM,EACd,0BAA0B,EAAE,MAAM,EAAE,EACpC,IAAI,EAAE,mBAAmB,CAAC,OAAO,CAAC,EAClC,MAAM,EAAE,mBAAmB,CAAC,SAAS,CAAC,EACtC,MAAM,EAAE,6BAA6B,GACpC,mCAAmC,CAgErC;AAED;;;;;;;GAOG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,iBAAiB,GAAG,iBAAiB,EAC9E,MAAM,EAAE,MAAM,EACd,eAAe,EAAE,6BAA6B,CAAC,WAAW,CAAC,EAC3D,WAAW,EAAE,MAAM,GAClB,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,GAAG,IAAI,EAAE,oBAAoB,CAAC,CAAC,CAAC,KAAK,UAAU,CAAC,CAAC,CAAC,CAqEtE"}
@@ -21,18 +21,19 @@ export declare const instrumentGoogleGenAI: ((options?: GoogleGenAIOptions | und
21
21
  *
22
22
  * ## Options
23
23
  *
24
- * - `recordInputs`: Whether to record prompt messages (default: respects `sendDefaultPii` client option)
25
- * - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
24
+ * - `recordInputs`: Whether to record prompt messages (default: follows `dataCollection.genAI.inputs`)
25
+ * - `recordOutputs`: Whether to record response text (default: follows `dataCollection.genAI.outputs`)
26
26
  *
27
27
  * ### Default Behavior
28
28
  *
29
29
  * By default, the integration will:
30
- * - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
31
- * - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
30
+ * - Record inputs and outputs based on `dataCollection.genAI` in your Sentry client options
31
+ * (or the deprecated `sendDefaultPii` option, for backwards compatibility)
32
+ * - Integration-level `recordInputs`/`recordOutputs` options take precedence over global config
32
33
  *
33
34
  * @example
34
35
  * ```javascript
35
- * // Record inputs and outputs when sendDefaultPii is false
36
+ * // Always record inputs and outputs regardless of global dataCollection config
36
37
  * Sentry.init({
37
38
  * integrations: [
38
39
  * Sentry.googleGenAiIntegration({
@@ -42,9 +43,9 @@ export declare const instrumentGoogleGenAI: ((options?: GoogleGenAIOptions | und
42
43
  * ],
43
44
  * });
44
45
  *
45
- * // Never record inputs/outputs regardless of sendDefaultPii
46
+ * // Never record inputs/outputs regardless of global dataCollection config
46
47
  * Sentry.init({
47
- * sendDefaultPii: true,
48
+ * dataCollection: { genAI: { inputs: true, outputs: true } },
48
49
  * integrations: [
49
50
  * Sentry.googleGenAiIntegration({
50
51
  * recordInputs: false,
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/google-genai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAiB,MAAM,cAAc,CAAC;AAKtE,eAAO,MAAM,qBAAqB;;CAGjC,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,eAAO,MAAM,sBAAsB,kFAA6C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/google-genai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAiB,MAAM,cAAc,CAAC;AAKtE,eAAO,MAAM,qBAAqB;;CAGjC,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDG;AACH,eAAO,MAAM,sBAAsB,kFAA6C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/google-genai/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,+BAA+B,EAAE,MAAM,gCAAgC,CAAC;AAC7G,OAAO,EACL,mBAAmB,EAGpB,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAmB1E,KAAK,iCAAiC,GAAG,kBAAkB,GAAG,qBAAqB,CAAC;AAEpF;;GAEG;AACH,qBAAa,gCAAiC,SAAQ,mBAAmB,CAAC,iCAAiC,CAAC;gBACvF,MAAM,GAAE,iCAAsC;IAIjE;;OAEG;IACI,IAAI,IAAI,+BAA+B;IAsB9C;;OAEG;IACH,OAAO,CAAC,MAAM;CAqCf"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/google-genai/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,+BAA+B,EAAE,MAAM,gCAAgC,CAAC;AAC7G,OAAO,EAAE,mBAAmB,EAAuC,MAAM,gCAAgC,CAAC;AAE1G,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAmB1E,KAAK,iCAAiC,GAAG,kBAAkB,GAAG,qBAAqB,CAAC;AAEpF;;GAEG;AACH,qBAAa,gCAAiC,SAAQ,mBAAmB,CAAC,iCAAiC,CAAC;gBACvF,MAAM,GAAE,iCAAsC;IAIjE;;OAEG;IACI,IAAI,IAAI,+BAA+B;IAsB9C;;OAEG;IACH,OAAO,CAAC,MAAM;CAqCf"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/graphql/vendored/instrumentation.ts"],"names":[],"mappings":"AAwBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAGpC,MAAM,gCAAgC,CAAC;AA4CxC,OAAO,EAAE,4BAA4B,EAAE,kCAAkC,EAAE,MAAM,SAAS,CAAC;AAa3F,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,kCAAkC,CAAC;gBACrF,MAAM,GAAE,4BAAiC;IAI5C,SAAS,CAAC,MAAM,GAAE,4BAAiC;IAI5D,SAAS,CAAC,IAAI;IASd,OAAO,CAAC,mBAAmB;IAqB3B,OAAO,CAAC,kBAAkB;IAmB1B,OAAO,CAAC,oBAAoB;IAmB5B,OAAO,CAAC,aAAa;IA6DrB,OAAO,CAAC,sBAAsB;IA6B9B,OAAO,CAAC,oBAAoB;IAqB5B,OAAO,CAAC,WAAW;IASnB,OAAO,CAAC,cAAc;IAgBtB,OAAO,CAAC,MAAM;IAwBd,OAAO,CAAC,SAAS;IAgCjB,OAAO,CAAC,kBAAkB;IAwC1B,OAAO,CAAC,gBAAgB;CAuDzB"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/graphql/vendored/instrumentation.ts"],"names":[],"mappings":"AAwBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AA6CxC,OAAO,EAAE,4BAA4B,EAAE,kCAAkC,EAAE,MAAM,SAAS,CAAC;AAa3F,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,kCAAkC,CAAC;gBACrF,MAAM,GAAE,4BAAiC;IAI5C,SAAS,CAAC,MAAM,GAAE,4BAAiC;IAI5D,SAAS,CAAC,IAAI;IASd,OAAO,CAAC,mBAAmB;IAqB3B,OAAO,CAAC,kBAAkB;IAmB1B,OAAO,CAAC,oBAAoB;IAmB5B,OAAO,CAAC,aAAa;IA6DrB,OAAO,CAAC,sBAAsB;IA6B9B,OAAO,CAAC,oBAAoB;IAqB5B,OAAO,CAAC,WAAW;IASnB,OAAO,CAAC,cAAc;IAgBtB,OAAO,CAAC,MAAM;IAwBd,OAAO,CAAC,SAAS;IAgCjB,OAAO,CAAC,kBAAkB;IAwC1B,OAAO,CAAC,gBAAgB;CAuDzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/hapi/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AA4BxC,6CAA6C;AAC7C,qBAAa,mBAAoB,SAAQ,mBAAmB;IAC1D,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,qBAA0B;IAK9C,SAAS,CAAC,IAAI;IAsBd;;;;;;OAMG;IACH,OAAO,CAAC,eAAe;IAwBvB;;;;;;OAMG;IACH,OAAO,CAAC,uBAAuB;IAgB/B;;;;;;;;;OASG;IACH,OAAO,CAAC,kBAAkB;IA+B1B;;;;;;;;OAQG;IACH,OAAO,CAAC,oBAAoB;IAe5B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAqB5B;;;;;;;;;;OAUG;IACH,OAAO,CAAC,eAAe;IA8CvB;;;;;;OAMG;IACH,OAAO,CAAC,iBAAiB;CAmD1B"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/hapi/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AA4BxC,6CAA6C;AAC7C,qBAAa,mBAAoB,SAAQ,mBAAmB;IAC1D,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,qBAA0B;IAK9C,SAAS,CAAC,IAAI;IAsBd;;;;;;OAMG;IACH,OAAO,CAAC,eAAe;IAwBvB;;;;;;OAMG;IACH,OAAO,CAAC,uBAAuB;IAgB/B;;;;;;;;;OASG;IACH,OAAO,CAAC,kBAAkB;IA+B1B;;;;;;;;OAQG;IACH,OAAO,CAAC,oBAAoB;IAe5B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAqB5B;;;;;;;;;;OAUG;IACH,OAAO,CAAC,eAAe;IA8CvB;;;;;;OAMG;IACH,OAAO,CAAC,iBAAiB;CAgD1B"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/knex/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAKpC,MAAM,gCAAgC,CAAC;AAExC,OAAO,EAAE,yBAAyB,EAAE,MAAM,SAAS,CAAC;AA8BpD,qBAAa,mBAAoB,SAAQ,mBAAmB,CAAC,yBAAyB,CAAC;IACrF,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,yBAA8B;IAMzC,SAAS,CAAC,MAAM,GAAE,yBAA8B;IAIzD,IAAI;IAcJ,OAAO,CAAC,sCAAsC;IAe9C,OAAO,CAAC,sCAAsC;IAmB9C,OAAO,CAAC,kBAAkB;IA0F1B,OAAO,CAAC,YAAY;IAUpB,aAAa,CAAC,GAAG,EAAE,GAAG,EAAE,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,QAAQ,EAAE,GAAG,KAAK,GAAG;CAM5E"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/knex/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AAGxC,OAAO,EAAE,yBAAyB,EAAE,MAAM,SAAS,CAAC;AA8BpD,qBAAa,mBAAoB,SAAQ,mBAAmB,CAAC,yBAAyB,CAAC;IACrF,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,yBAA8B;IAMzC,SAAS,CAAC,MAAM,GAAE,yBAA8B;IAIzD,IAAI;IAcJ,OAAO,CAAC,sCAAsC;IAe9C,OAAO,CAAC,sCAAsC;IAmB9C,OAAO,CAAC,kBAAkB;IA0F1B,OAAO,CAAC,YAAY;IAUpB,aAAa,CAAC,GAAG,EAAE,GAAG,EAAE,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,QAAQ,EAAE,GAAG,KAAK,GAAG;CAM5E"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/koa/vendored/instrumentation.ts"],"names":[],"mappings":"AAuBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AAExC,OAAO,EAAgB,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAQjE,4CAA4C;AAC5C,qBAAa,kBAAmB,SAAQ,mBAAmB,CAAC,wBAAwB,CAAC;gBACvE,MAAM,GAAE,wBAA6B;IAIjD,SAAS,CAAC,IAAI;IA8Bd;;;;OAIG;IACH,OAAO,CAAC,eAAe;IAavB;;;;;;OAMG;IACH,OAAO,CAAC,oBAAoB;IAoB5B;;;;;;;;OAQG;IACH,OAAO,CAAC,WAAW;CAmEpB"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/koa/vendored/instrumentation.ts"],"names":[],"mappings":"AAuBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAEpC,MAAM,gCAAgC,CAAC;AAExC,OAAO,EAAgB,wBAAwB,EAAE,MAAM,SAAS,CAAC;AAQjE,4CAA4C;AAC5C,qBAAa,kBAAmB,SAAQ,mBAAmB,CAAC,wBAAwB,CAAC;gBACvE,MAAM,GAAE,wBAA6B;IAIjD,SAAS,CAAC,IAAI;IA8Bd;;;;OAIG;IACH,OAAO,CAAC,eAAe;IAavB;;;;;;OAMG;IACH,OAAO,CAAC,oBAAoB;IAoB5B;;;;;;;;OAQG;IACH,OAAO,CAAC,WAAW;CAiEpB"}
@@ -21,7 +21,7 @@ export declare const instrumentLangChain: ((options?: LangChainOptions | undefin
21
21
  *
22
22
  * Sentry.init({
23
23
  * integrations: [Sentry.langChainIntegration()],
24
- * sendDefaultPii: true, // Enable to record inputs/outputs
24
+ * dataCollection: { genAI: { inputs: true, outputs: true } }, // Enable to record inputs/outputs
25
25
  * });
26
26
  *
27
27
  * // LangChain calls are automatically instrumented
@@ -52,18 +52,19 @@ export declare const instrumentLangChain: ((options?: LangChainOptions | undefin
52
52
  *
53
53
  * ## Options
54
54
  *
55
- * - `recordInputs`: Whether to record input messages/prompts (default: respects `sendDefaultPii` client option)
56
- * - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
55
+ * - `recordInputs`: Whether to record input messages/prompts (default: follows `dataCollection.genAI.inputs`, or the deprecated `sendDefaultPii` option)
56
+ * - `recordOutputs`: Whether to record response text (default: follows `dataCollection.genAI.outputs`, or the deprecated `sendDefaultPii` option)
57
57
  *
58
58
  * ### Default Behavior
59
59
  *
60
60
  * By default, the integration will:
61
- * - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
62
- * - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
61
+ * - Record inputs and outputs based on `dataCollection.genAI` in your Sentry client options
62
+ * (or the deprecated `sendDefaultPii` option, for backwards compatibility)
63
+ * - Integration-level `recordInputs`/`recordOutputs` options take precedence over global config
63
64
  *
64
65
  * @example
65
66
  * ```javascript
66
- * // Record inputs and outputs when sendDefaultPii is false
67
+ * // Always record inputs and outputs regardless of global dataCollection config
67
68
  * Sentry.init({
68
69
  * integrations: [
69
70
  * Sentry.langChainIntegration({
@@ -73,9 +74,9 @@ export declare const instrumentLangChain: ((options?: LangChainOptions | undefin
73
74
  * ],
74
75
  * });
75
76
  *
76
- * // Never record inputs/outputs regardless of sendDefaultPii
77
+ * // Never record inputs/outputs regardless of global dataCollection config
77
78
  * Sentry.init({
78
- * sendDefaultPii: true,
79
+ * dataCollection: { genAI: { inputs: true, outputs: true } },
79
80
  * integrations: [
80
81
  * Sentry.langChainIntegration({
81
82
  * recordInputs: false,
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langchain/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,eAAO,MAAM,mBAAmB;;CAG/B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2FG;AACH,eAAO,MAAM,oBAAoB,gFAA2C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langchain/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,eAAO,MAAM,mBAAmB;;CAG/B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4FG;AACH,eAAO,MAAM,oBAAoB,gFAA2C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langchain/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EAGrC,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAcrD,KAAK,+BAA+B,GAAG,qBAAqB,GAAG,gBAAgB,CAAC;AA4ChF;;GAEG;AACH,qBAAa,8BAA+B,SAAQ,mBAAmB,CAAC,+BAA+B,CAAC;gBACnF,MAAM,GAAE,+BAAoC;IAI/D;;;;;;OAMG;IACI,IAAI,IAAI,+BAA+B,GAAG,+BAA+B,EAAE;IA0DlF;;;OAGG;IACH,OAAO,CAAC,MAAM;IAyBd;;;OAGG;IACH,OAAO,CAAC,qBAAqB;IA+C7B;;;;;;;OAOG;IACH,OAAO,CAAC,uBAAuB;CAmBhC"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langchain/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EAErC,MAAM,gCAAgC,CAAC;AAExC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAcrD,KAAK,+BAA+B,GAAG,qBAAqB,GAAG,gBAAgB,CAAC;AA4ChF;;GAEG;AACH,qBAAa,8BAA+B,SAAQ,mBAAmB,CAAC,+BAA+B,CAAC;gBACnF,MAAM,GAAE,+BAAoC;IAI/D;;;;;;OAMG;IACI,IAAI,IAAI,+BAA+B,GAAG,+BAA+B,EAAE;IA0DlF;;;OAGG;IACH,OAAO,CAAC,MAAM;IAyBd;;;OAGG;IACH,OAAO,CAAC,qBAAqB;IA+C7B;;;;;;;OAOG;IACH,OAAO,CAAC,uBAAuB;CAmBhC"}
@@ -21,18 +21,19 @@ export declare const instrumentLangGraph: ((options?: LangGraphOptions | undefin
21
21
  *
22
22
  * ## Options
23
23
  *
24
- * - `recordInputs`: Whether to record input messages (default: respects `sendDefaultPii` client option)
25
- * - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
24
+ * - `recordInputs`: Whether to record prompt messages (default: follows `dataCollection.genAI.inputs`, or the deprecated `sendDefaultPii` option)
25
+ * - `recordOutputs`: Whether to record response text (default: follows `dataCollection.genAI.outputs`, or the deprecated `sendDefaultPii` option)
26
26
  *
27
27
  * ### Default Behavior
28
28
  *
29
29
  * By default, the integration will:
30
- * - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
31
- * - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
30
+ * - Record inputs and outputs based on `dataCollection.genAI` in your Sentry client options
31
+ * (or the deprecated `sendDefaultPii` option, for backwards compatibility)
32
+ * - Integration-level `recordInputs`/`recordOutputs` options take precedence over global config
32
33
  *
33
34
  * @example
34
35
  * ```javascript
35
- * // Record inputs and outputs when sendDefaultPii is false
36
+ * // Always record inputs and outputs regardless of global dataCollection config
36
37
  * Sentry.init({
37
38
  * integrations: [
38
39
  * Sentry.langGraphIntegration({
@@ -42,9 +43,9 @@ export declare const instrumentLangGraph: ((options?: LangGraphOptions | undefin
42
43
  * ],
43
44
  * });
44
45
  *
45
- * // Never record inputs/outputs regardless of sendDefaultPii
46
+ * // Never record inputs/outputs regardless of global dataCollection config
46
47
  * Sentry.init({
47
- * sendDefaultPii: true,
48
+ * dataCollection: { genAI: { inputs: true, outputs: true } },
48
49
  * integrations: [
49
50
  * Sentry.langGraphIntegration({
50
51
  * recordInputs: false,
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langgraph/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,eAAO,MAAM,mBAAmB;;CAG/B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,eAAO,MAAM,oBAAoB,gFAA2C,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langgraph/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,eAAO,MAAM,mBAAmB;;CAG/B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoEG;AACH,eAAO,MAAM,oBAAoB,gFAA2C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langgraph/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EAGrC,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,KAAK,+BAA+B,GAAG,qBAAqB,GAAG,gBAAgB,CAAC;AAWhF;;GAEG;AACH,qBAAa,8BAA+B,SAAQ,mBAAmB,CAAC,+BAA+B,CAAC;gBACnF,MAAM,GAAE,+BAAoC;IAI/D;;OAEG;IACI,IAAI,IAAI,+BAA+B,EAAE;IAsDhD;;OAEG;IACH,OAAO,CAAC,MAAM;CA0Bf"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/langgraph/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EAErC,MAAM,gCAAgC,CAAC;AAExC,OAAO,KAAK,EAAiB,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAKpE,KAAK,+BAA+B,GAAG,qBAAqB,GAAG,gBAAgB,CAAC;AAWhF;;GAEG;AACH,qBAAa,8BAA+B,SAAQ,mBAAmB,CAAC,+BAA+B,CAAC;gBACnF,MAAM,GAAE,+BAAoC;IAI/D;;OAEG;IACI,IAAI,IAAI,+BAA+B,EAAE;IAsDhD;;OAEG;IACH,OAAO,CAAC,MAAM;CA2Bf"}
@@ -1,6 +1,6 @@
1
- import { InstrumentationBase, InstrumentationConfig, InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
1
+ import { InstrumentationBase, InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
2
2
  export declare class LruMemoizerInstrumentation extends InstrumentationBase {
3
- constructor(config?: InstrumentationConfig);
3
+ constructor();
4
4
  init(): InstrumentationNodeModuleDefinition[];
5
5
  }
6
6
  //# sourceMappingURL=instrumentation.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/lrumemoizer/vendored/instrumentation.ts"],"names":[],"mappings":"AAsBA,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,mCAAmC,EACpC,MAAM,gCAAgC,CAAC;AAKxC,qBAAa,0BAA2B,SAAQ,mBAAmB;gBACrD,MAAM,GAAE,qBAA0B;IAI9C,IAAI,IAAI,mCAAmC,EAAE;CAiC9C"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/lrumemoizer/vendored/instrumentation.ts"],"names":[],"mappings":"AAqBA,OAAO,EAAE,mBAAmB,EAAE,mCAAmC,EAAE,MAAM,gCAAgC,CAAC;AAQ1G,qBAAa,0BAA2B,SAAQ,mBAAmB;;IAKjE,IAAI,IAAI,mCAAmC,EAAE;CA8B9C"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/mongo/vendored/instrumentation.ts"],"names":[],"mappings":"AAsBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAMpC,MAAM,gCAAgC,CAAC;AAuBxC,OAAO,EAAE,4BAA4B,EAAiB,MAAM,SAAS,CAAC;AAsBtE,uDAAuD;AACvD,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;IAC3F,OAAO,CAAC,oBAAoB,CAAoB;IAChD,OAAO,CAAC,mBAAmB,CAAoB;IAC/C,QAAgB,iBAAiB,CAAgB;IACjD,QAAgB,SAAS,CAAS;gBAEtB,MAAM,GAAE,4BAAiC;IAMrD,OAAO,CAAC,2BAA2B;IAK1B,SAAS,CAAC,MAAM,GAAE,4BAAiC;IAInD,wBAAwB;IAOjC;;;;OAIG;IACH,OAAO,CAAC,aAAa;IAIrB,IAAI;IAqDJ,OAAO,CAAC,uBAAuB;IA+C/B,OAAO,CAAC,qBAAqB;IA0B7B,OAAO,CAAC,oBAAoB;IAqB5B,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,2BAA2B;IAoBnC,OAAO,CAAC,oBAAoB;IAoB5B,OAAO,CAAC,4BAA4B;IASpC,OAAO,CAAC,oBAAoB;IAmC5B,OAAO,CAAC,uBAAuB;IA2B/B,0CAA0C;IAC1C,OAAO,CAAC,oBAAoB;IA+C5B,0CAA0C;IAC1C,OAAO,CAAC,kBAAkB;IA4C1B,0CAA0C;IAC1C,OAAO,CAAC,0BAA0B;IAmClC,OAAO,CAAC,yBAAyB;IAsCjC,uCAAuC;IACvC,OAAO,CAAC,eAAe;IA0CvB,uCAAuC;IACvC,OAAO,CAAC,iBAAiB;IA2CzB;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,eAAe;IAgB9B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IA2B5B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAiC5B,OAAO,CAAC,kBAAkB;IAuE1B,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,8BAA8B;IAatC,OAAO,CAAC,6BAA6B;IAUrC;;;;OAIG;IACH,OAAO,CAAC,sBAAsB;IAiB9B;;;;;OAKG;IACH,OAAO,CAAC,SAAS;IAuCjB,OAAO,CAAC,WAAW;IAQnB,OAAO,CAAC,yBAAyB;CAKlC"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/mongo/vendored/instrumentation.ts"],"names":[],"mappings":"AAsBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAKpC,MAAM,gCAAgC,CAAC;AAwBxC,OAAO,EAAE,4BAA4B,EAAiB,MAAM,SAAS,CAAC;AAsBtE,uDAAuD;AACvD,qBAAa,sBAAuB,SAAQ,mBAAmB,CAAC,4BAA4B,CAAC;IAC3F,OAAO,CAAC,oBAAoB,CAAoB;IAChD,OAAO,CAAC,mBAAmB,CAAoB;IAC/C,QAAgB,iBAAiB,CAAgB;IACjD,QAAgB,SAAS,CAAS;gBAEtB,MAAM,GAAE,4BAAiC;IAMrD,OAAO,CAAC,2BAA2B;IAK1B,SAAS,CAAC,MAAM,GAAE,4BAAiC;IAInD,wBAAwB;IAOjC;;;;OAIG;IACH,OAAO,CAAC,aAAa;IAIrB,IAAI;IAqDJ,OAAO,CAAC,uBAAuB;IA+C/B,OAAO,CAAC,qBAAqB;IA0B7B,OAAO,CAAC,oBAAoB;IAqB5B,OAAO,CAAC,oBAAoB;IAa5B,OAAO,CAAC,2BAA2B;IAoBnC,OAAO,CAAC,oBAAoB;IAoB5B,OAAO,CAAC,4BAA4B;IASpC,OAAO,CAAC,oBAAoB;IAmC5B,OAAO,CAAC,uBAAuB;IA2B/B,0CAA0C;IAC1C,OAAO,CAAC,oBAAoB;IA+C5B,0CAA0C;IAC1C,OAAO,CAAC,kBAAkB;IA4C1B,0CAA0C;IAC1C,OAAO,CAAC,0BAA0B;IAmClC,OAAO,CAAC,yBAAyB;IAsCjC,uCAAuC;IACvC,OAAO,CAAC,eAAe;IA0CvB,uCAAuC;IACvC,OAAO,CAAC,iBAAiB;IA2CzB;;;OAGG;IACH,OAAO,CAAC,MAAM,CAAC,eAAe;IAgB9B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IA2B5B;;;;;OAKG;IACH,OAAO,CAAC,oBAAoB;IAiC5B,OAAO,CAAC,kBAAkB;IAuE1B,OAAO,CAAC,kBAAkB;IAa1B,OAAO,CAAC,8BAA8B;IAatC,OAAO,CAAC,6BAA6B;IAUrC;;;;OAIG;IACH,OAAO,CAAC,sBAAsB;IAiB9B;;;;;OAKG;IACH,OAAO,CAAC,SAAS;IAuCjB,OAAO,CAAC,WAAW;IAQnB,OAAO,CAAC,yBAAyB;CAKlC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/mysql2/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAMpC,MAAM,gCAAgC,CAAC;AAIxC,OAAO,EAAE,2BAA2B,EAAE,MAAM,SAAS,CAAC;AAYtD,qBAAa,qBAAsB,SAAQ,mBAAmB,CAAC,2BAA2B,CAAC;IACzF,OAAO,CAAC,oBAAoB,CAAoB;IAChD,OAAO,CAAC,mBAAmB,CAAoB;gBAEnC,MAAM,GAAE,2BAAgC;IAKpD,OAAO,CAAC,2BAA2B;IAKnC,SAAS,CAAC,IAAI;IA2Dd,OAAO,CAAC,WAAW;IAsGnB,OAAO,CAAC,mBAAmB;CAQ5B"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/mysql2/vendored/instrumentation.ts"],"names":[],"mappings":"AAyBA,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAKpC,MAAM,gCAAgC,CAAC;AAKxC,OAAO,EAAE,2BAA2B,EAAE,MAAM,SAAS,CAAC;AAYtD,qBAAa,qBAAsB,SAAQ,mBAAmB,CAAC,2BAA2B,CAAC;IACzF,OAAO,CAAC,oBAAoB,CAAoB;IAChD,OAAO,CAAC,mBAAmB,CAAoB;gBAEnC,MAAM,GAAE,2BAAgC;IAKpD,OAAO,CAAC,2BAA2B;IAKnC,SAAS,CAAC,IAAI;IA2Dd,OAAO,CAAC,WAAW;IAsGnB,OAAO,CAAC,mBAAmB;CAQ5B"}
@@ -21,18 +21,19 @@ export declare const instrumentOpenAi: ((options?: OpenAiOptions | undefined) =>
21
21
  *
22
22
  * ## Options
23
23
  *
24
- * - `recordInputs`: Whether to record prompt messages (default: respects `sendDefaultPii` client option)
25
- * - `recordOutputs`: Whether to record response text (default: respects `sendDefaultPii` client option)
24
+ * - `recordInputs`: Whether to record input messages/prompts (default: follows `dataCollection.genAI.inputs`, or the deprecated `sendDefaultPii` option)
25
+ * - `recordOutputs`: Whether to record response text (default: follows `dataCollection.genAI.outputs`, or the deprecated `sendDefaultPii` option)
26
26
  *
27
27
  * ### Default Behavior
28
28
  *
29
29
  * By default, the integration will:
30
- * - Record inputs and outputs ONLY if `sendDefaultPii` is set to `true` in your Sentry client options
31
- * - Otherwise, inputs and outputs are NOT recorded unless explicitly enabled
30
+ * - Record inputs and outputs based on `dataCollection.genAI` in your Sentry client options
31
+ * (or the deprecated `sendDefaultPii` option, for backwards compatibility)
32
+ * - Integration-level `recordInputs`/`recordOutputs` options take precedence over global config
32
33
  *
33
34
  * @example
34
35
  * ```javascript
35
- * // Record inputs and outputs when sendDefaultPii is false
36
+ * // Always record inputs and outputs regardless of global dataCollection config
36
37
  * Sentry.init({
37
38
  * integrations: [
38
39
  * Sentry.openAIIntegration({
@@ -42,9 +43,9 @@ export declare const instrumentOpenAi: ((options?: OpenAiOptions | undefined) =>
42
43
  * ],
43
44
  * });
44
45
  *
45
- * // Never record inputs/outputs regardless of sendDefaultPii
46
+ * // Never record inputs/outputs regardless of global dataCollection config
46
47
  * Sentry.init({
47
- * sendDefaultPii: true,
48
+ * dataCollection: { genAI: { inputs: true, outputs: true } },
48
49
  * integrations: [
49
50
  * Sentry.openAIIntegration({
50
51
  * recordInputs: false,
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/openai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,aAAa,EAAE,MAAM,cAAc,CAAC;AAKjE,eAAO,MAAM,gBAAgB;;CAG5B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,eAAO,MAAM,iBAAiB,6EAAwC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/openai/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAiB,aAAa,EAAE,MAAM,cAAc,CAAC;AAKjE,eAAO,MAAM,gBAAgB;;CAG5B,CAAC;AAWF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDG;AACH,eAAO,MAAM,iBAAiB,6EAAwC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/postgres/vendored/instrumentation.ts"],"names":[],"mappings":"AAuBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAKpC,MAAM,gCAAgC,CAAC;AAsBxC,OAAO,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AA6BlD,qBAAa,iBAAkB,SAAQ,mBAAmB,CAAC,uBAAuB,CAAC;IACjF,QAAgB,kBAAkB,CAAY;IAC9C,QAAgB,iBAAiB,CAAgB;IACjD,QAAgB,0BAA0B,CAAgB;IAM1D,OAAO,CAAC,mBAAmB,CAIzB;IACF,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,uBAA4B;IAKvC,wBAAwB;IAyBjC,SAAS,CAAC,IAAI;IA0Dd,OAAO,CAAC,cAAc;IAsBtB,OAAO,CAAC,gBAAgB;IAcxB,OAAO,CAAC,sBAAsB;IAgC9B,OAAO,CAAC,uBAAuB;IA0B/B,OAAO,CAAC,oBAAoB;IA8M5B,OAAO,CAAC,6BAA6B;IA8CrC,OAAO,CAAC,oBAAoB;CAwC7B"}
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/postgres/vendored/instrumentation.ts"],"names":[],"mappings":"AAuBA,OAAO,EAEL,mBAAmB,EACnB,mCAAmC,EAIpC,MAAM,gCAAgC,CAAC;AAsBxC,OAAO,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AA4BlD,qBAAa,iBAAkB,SAAQ,mBAAmB,CAAC,uBAAuB,CAAC;IACjF,QAAgB,kBAAkB,CAAY;IAC9C,QAAgB,iBAAiB,CAAgB;IACjD,QAAgB,0BAA0B,CAAgB;IAM1D,OAAO,CAAC,mBAAmB,CAIzB;IACF,OAAO,CAAC,iBAAiB,CAAmB;gBAEhC,MAAM,GAAE,uBAA4B;IAKvC,wBAAwB;IAyBjC,SAAS,CAAC,IAAI;IA0Dd,OAAO,CAAC,cAAc;IAsBtB,OAAO,CAAC,gBAAgB;IAcxB,OAAO,CAAC,sBAAsB;IAgC9B,OAAO,CAAC,uBAAuB;IA0B/B,OAAO,CAAC,oBAAoB;IA8M5B,OAAO,CAAC,6BAA6B;IA8CrC,OAAO,CAAC,oBAAoB;CAwC7B"}
@@ -1 +1 @@
1
- {"version":3,"file":"postgresjs.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/postgresjs.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAC5E,OAAO,EACL,mBAAmB,EACnB,mCAAmC,EAGpC,MAAM,gCAAgC,CAAC;AAQxC,OAAO,KAAK,EAAiB,IAAI,EAAE,MAAM,cAAc,C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AAM,cAAc,CAAC;AAiBxD,KAAK,yBAAyB,GAAG;IAC/B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B,CAAC;AAMF,KAAK,+BAA+B,GAAG,qBAAqB,GAAG;IAC7D;;;;;OAKG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B;;;OAGG;IACH,WAAW,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,iBAAiB,EAAE,MAAM,EAAE,yBAAyB,CAAC,EAAE,yBAAyB,KAAK,IAAI,CAAC;CACtH,CAAC;AAEF,eAAO,MAAM,oBAAoB;;CAOhC,CAAC;AAEF;;;;;GAKG;AACH,qBAAa,yBAA0B,SAAQ,mBAAmB,CAAC,+BAA+B,CAAC;gBAC9E,MAAM,EAAE,+BAA+B;IAI1D;;;;;OAKG;IACI,IAAI,IAAI,mCAAmC;IA+BlD;;;OAGG;IACH,OAAO,CAAC,cAAc;IAqDtB;;;;OAIG;IACH,OAAO,CAAC,kBAAkB;IAM1B;;OAEG;IACH,OAAO,CAAC,iBAAiB;IAYzB;;;;;;OAMG;IACH,OAAO,CAAC,iBAAiB;IAWzB;;;;;;OAMG;IACH,OAAO,CAAC,iBAAiB;IAkCzB;;;;;;OAMG;IACH,OAAO,CAAC,oBAAoB;IA0H5B;;OAEG;IACH,OAAO,CAAC,sBAAsB;CAc/B;AAWD;;;;;;;;;;;;;GAaG;AAEH,eAAO,MAAM,qBAAqB,+FAA4C,CAAC"}
@@ -17,7 +17,10 @@ interface RedisOptions {
17
17
  }
18
18
  export declare let _redisOptions: RedisOptions;
19
19
  export declare const cacheResponseHook: IORedisResponseCustomAttributeFunction;
20
- /** To be able to preload all Redis OTel instrumentations with just one ID ("Redis"), all the instrumentations are generated in this one function */
20
+ /**
21
+ * To be able to preload all Redis OTel instrumentations with just one ID
22
+ * ("Redis"), all the instrumentations are generated in this one function
23
+ */
21
24
  export declare const instrumentRedis: (() => void) & {
22
25
  id: string;
23
26
  };