@depup/sentry__node 10.44.0-depup.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 (473) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +31 -0
  3. package/build/cjs/debug-build.js +11 -0
  4. package/build/cjs/debug-build.js.map +1 -0
  5. package/build/cjs/index.js +216 -0
  6. package/build/cjs/index.js.map +1 -0
  7. package/build/cjs/init.js +10 -0
  8. package/build/cjs/init.js.map +1 -0
  9. package/build/cjs/integrations/featureFlagShims/growthbook.js +12 -0
  10. package/build/cjs/integrations/featureFlagShims/growthbook.js.map +1 -0
  11. package/build/cjs/integrations/featureFlagShims/launchDarkly.js +43 -0
  12. package/build/cjs/integrations/featureFlagShims/launchDarkly.js.map +1 -0
  13. package/build/cjs/integrations/featureFlagShims/openFeature.js +55 -0
  14. package/build/cjs/integrations/featureFlagShims/openFeature.js.map +1 -0
  15. package/build/cjs/integrations/featureFlagShims/statsig.js +23 -0
  16. package/build/cjs/integrations/featureFlagShims/statsig.js.map +1 -0
  17. package/build/cjs/integrations/featureFlagShims/unleash.js +23 -0
  18. package/build/cjs/integrations/featureFlagShims/unleash.js.map +1 -0
  19. package/build/cjs/integrations/fs.js +142 -0
  20. package/build/cjs/integrations/fs.js.map +1 -0
  21. package/build/cjs/integrations/http.js +224 -0
  22. package/build/cjs/integrations/http.js.map +1 -0
  23. package/build/cjs/integrations/node-fetch.js +108 -0
  24. package/build/cjs/integrations/node-fetch.js.map +1 -0
  25. package/build/cjs/integrations/tracing/amqplib.js +47 -0
  26. package/build/cjs/integrations/tracing/amqplib.js.map +1 -0
  27. package/build/cjs/integrations/tracing/anthropic-ai/index.js +79 -0
  28. package/build/cjs/integrations/tracing/anthropic-ai/index.js.map +1 -0
  29. package/build/cjs/integrations/tracing/anthropic-ai/instrumentation.js +95 -0
  30. package/build/cjs/integrations/tracing/anthropic-ai/instrumentation.js.map +1 -0
  31. package/build/cjs/integrations/tracing/connect.js +110 -0
  32. package/build/cjs/integrations/tracing/connect.js.map +1 -0
  33. package/build/cjs/integrations/tracing/dataloader.js +72 -0
  34. package/build/cjs/integrations/tracing/dataloader.js.map +1 -0
  35. package/build/cjs/integrations/tracing/express.js +166 -0
  36. package/build/cjs/integrations/tracing/express.js.map +1 -0
  37. package/build/cjs/integrations/tracing/fastify/index.js +270 -0
  38. package/build/cjs/integrations/tracing/fastify/index.js.map +1 -0
  39. package/build/cjs/integrations/tracing/fastify/v3/constants.js +23 -0
  40. package/build/cjs/integrations/tracing/fastify/v3/constants.js.map +1 -0
  41. package/build/cjs/integrations/tracing/fastify/v3/enums/AttributeNames.js +37 -0
  42. package/build/cjs/integrations/tracing/fastify/v3/enums/AttributeNames.js.map +1 -0
  43. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js +304 -0
  44. package/build/cjs/integrations/tracing/fastify/v3/instrumentation.js.map +1 -0
  45. package/build/cjs/integrations/tracing/fastify/v3/utils.js +135 -0
  46. package/build/cjs/integrations/tracing/fastify/v3/utils.js.map +1 -0
  47. package/build/cjs/integrations/tracing/firebase/firebase.js +50 -0
  48. package/build/cjs/integrations/tracing/firebase/firebase.js.map +1 -0
  49. package/build/cjs/integrations/tracing/firebase/otel/firebaseInstrumentation.js +44 -0
  50. package/build/cjs/integrations/tracing/firebase/otel/firebaseInstrumentation.js.map +1 -0
  51. package/build/cjs/integrations/tracing/firebase/otel/patches/firestore.js +297 -0
  52. package/build/cjs/integrations/tracing/firebase/otel/patches/firestore.js.map +1 -0
  53. package/build/cjs/integrations/tracing/firebase/otel/patches/functions.js +265 -0
  54. package/build/cjs/integrations/tracing/firebase/otel/patches/functions.js.map +1 -0
  55. package/build/cjs/integrations/tracing/genericPool.js +59 -0
  56. package/build/cjs/integrations/tracing/genericPool.js.map +1 -0
  57. package/build/cjs/integrations/tracing/google-genai/index.js +78 -0
  58. package/build/cjs/integrations/tracing/google-genai/index.js.map +1 -0
  59. package/build/cjs/integrations/tracing/google-genai/instrumentation.js +88 -0
  60. package/build/cjs/integrations/tracing/google-genai/instrumentation.js.map +1 -0
  61. package/build/cjs/integrations/tracing/graphql.js +127 -0
  62. package/build/cjs/integrations/tracing/graphql.js.map +1 -0
  63. package/build/cjs/integrations/tracing/hapi/index.js +135 -0
  64. package/build/cjs/integrations/tracing/hapi/index.js.map +1 -0
  65. package/build/cjs/integrations/tracing/hono/constants.js +15 -0
  66. package/build/cjs/integrations/tracing/hono/constants.js.map +1 -0
  67. package/build/cjs/integrations/tracing/hono/index.js +137 -0
  68. package/build/cjs/integrations/tracing/hono/index.js.map +1 -0
  69. package/build/cjs/integrations/tracing/hono/instrumentation.js +236 -0
  70. package/build/cjs/integrations/tracing/hono/instrumentation.js.map +1 -0
  71. package/build/cjs/integrations/tracing/index.js +110 -0
  72. package/build/cjs/integrations/tracing/index.js.map +1 -0
  73. package/build/cjs/integrations/tracing/kafka.js +48 -0
  74. package/build/cjs/integrations/tracing/kafka.js.map +1 -0
  75. package/build/cjs/integrations/tracing/knex.js +57 -0
  76. package/build/cjs/integrations/tracing/knex.js.map +1 -0
  77. package/build/cjs/integrations/tracing/koa.js +138 -0
  78. package/build/cjs/integrations/tracing/koa.js.map +1 -0
  79. package/build/cjs/integrations/tracing/langchain/index.js +116 -0
  80. package/build/cjs/integrations/tracing/langchain/index.js.map +1 -0
  81. package/build/cjs/integrations/tracing/langchain/instrumentation.js +220 -0
  82. package/build/cjs/integrations/tracing/langchain/instrumentation.js.map +1 -0
  83. package/build/cjs/integrations/tracing/langgraph/index.js +93 -0
  84. package/build/cjs/integrations/tracing/langgraph/index.js.map +1 -0
  85. package/build/cjs/integrations/tracing/langgraph/instrumentation.js +60 -0
  86. package/build/cjs/integrations/tracing/langgraph/instrumentation.js.map +1 -0
  87. package/build/cjs/integrations/tracing/lrumemoizer.js +37 -0
  88. package/build/cjs/integrations/tracing/lrumemoizer.js.map +1 -0
  89. package/build/cjs/integrations/tracing/mongo.js +93 -0
  90. package/build/cjs/integrations/tracing/mongo.js.map +1 -0
  91. package/build/cjs/integrations/tracing/mongoose.js +46 -0
  92. package/build/cjs/integrations/tracing/mongoose.js.map +1 -0
  93. package/build/cjs/integrations/tracing/mysql.js +38 -0
  94. package/build/cjs/integrations/tracing/mysql.js.map +1 -0
  95. package/build/cjs/integrations/tracing/mysql2.js +46 -0
  96. package/build/cjs/integrations/tracing/mysql2.js.map +1 -0
  97. package/build/cjs/integrations/tracing/openai/index.js +78 -0
  98. package/build/cjs/integrations/tracing/openai/index.js.map +1 -0
  99. package/build/cjs/integrations/tracing/openai/instrumentation.js +104 -0
  100. package/build/cjs/integrations/tracing/openai/instrumentation.js.map +1 -0
  101. package/build/cjs/integrations/tracing/postgres.js +48 -0
  102. package/build/cjs/integrations/tracing/postgres.js.map +1 -0
  103. package/build/cjs/integrations/tracing/postgresjs.js +378 -0
  104. package/build/cjs/integrations/tracing/postgresjs.js.map +1 -0
  105. package/build/cjs/integrations/tracing/prisma.js +203 -0
  106. package/build/cjs/integrations/tracing/prisma.js.map +1 -0
  107. package/build/cjs/integrations/tracing/redis.js +121 -0
  108. package/build/cjs/integrations/tracing/redis.js.map +1 -0
  109. package/build/cjs/integrations/tracing/tedious.js +67 -0
  110. package/build/cjs/integrations/tracing/tedious.js.map +1 -0
  111. package/build/cjs/integrations/tracing/vercelai/constants.js +6 -0
  112. package/build/cjs/integrations/tracing/vercelai/constants.js.map +1 -0
  113. package/build/cjs/integrations/tracing/vercelai/index.js +82 -0
  114. package/build/cjs/integrations/tracing/vercelai/index.js.map +1 -0
  115. package/build/cjs/integrations/tracing/vercelai/instrumentation.js +274 -0
  116. package/build/cjs/integrations/tracing/vercelai/instrumentation.js.map +1 -0
  117. package/build/cjs/preload.js +21 -0
  118. package/build/cjs/preload.js.map +1 -0
  119. package/build/cjs/sdk/index.js +78 -0
  120. package/build/cjs/sdk/index.js.map +1 -0
  121. package/build/cjs/sdk/initOtel.js +126 -0
  122. package/build/cjs/sdk/initOtel.js.map +1 -0
  123. package/build/cjs/utils/redisCache.js +122 -0
  124. package/build/cjs/utils/redisCache.js.map +1 -0
  125. package/build/esm/debug-build.js +9 -0
  126. package/build/esm/debug-build.js.map +1 -0
  127. package/build/esm/index.js +44 -0
  128. package/build/esm/index.js.map +1 -0
  129. package/build/esm/init.js +10 -0
  130. package/build/esm/init.js.map +1 -0
  131. package/build/esm/integrations/featureFlagShims/growthbook.js +10 -0
  132. package/build/esm/integrations/featureFlagShims/growthbook.js.map +1 -0
  133. package/build/esm/integrations/featureFlagShims/launchDarkly.js +40 -0
  134. package/build/esm/integrations/featureFlagShims/launchDarkly.js.map +1 -0
  135. package/build/esm/integrations/featureFlagShims/openFeature.js +52 -0
  136. package/build/esm/integrations/featureFlagShims/openFeature.js.map +1 -0
  137. package/build/esm/integrations/featureFlagShims/statsig.js +21 -0
  138. package/build/esm/integrations/featureFlagShims/statsig.js.map +1 -0
  139. package/build/esm/integrations/featureFlagShims/unleash.js +21 -0
  140. package/build/esm/integrations/featureFlagShims/unleash.js.map +1 -0
  141. package/build/esm/integrations/fs.js +140 -0
  142. package/build/esm/integrations/fs.js.map +1 -0
  143. package/build/esm/integrations/http.js +219 -0
  144. package/build/esm/integrations/http.js.map +1 -0
  145. package/build/esm/integrations/node-fetch.js +105 -0
  146. package/build/esm/integrations/node-fetch.js.map +1 -0
  147. package/build/esm/integrations/tracing/amqplib.js +44 -0
  148. package/build/esm/integrations/tracing/amqplib.js.map +1 -0
  149. package/build/esm/integrations/tracing/anthropic-ai/index.js +76 -0
  150. package/build/esm/integrations/tracing/anthropic-ai/index.js.map +1 -0
  151. package/build/esm/integrations/tracing/anthropic-ai/instrumentation.js +93 -0
  152. package/build/esm/integrations/tracing/anthropic-ai/instrumentation.js.map +1 -0
  153. package/build/esm/integrations/tracing/connect.js +106 -0
  154. package/build/esm/integrations/tracing/connect.js.map +1 -0
  155. package/build/esm/integrations/tracing/dataloader.js +69 -0
  156. package/build/esm/integrations/tracing/dataloader.js.map +1 -0
  157. package/build/esm/integrations/tracing/express.js +161 -0
  158. package/build/esm/integrations/tracing/express.js.map +1 -0
  159. package/build/esm/integrations/tracing/fastify/index.js +265 -0
  160. package/build/esm/integrations/tracing/fastify/index.js.map +1 -0
  161. package/build/esm/integrations/tracing/fastify/v3/constants.js +21 -0
  162. package/build/esm/integrations/tracing/fastify/v3/constants.js.map +1 -0
  163. package/build/esm/integrations/tracing/fastify/v3/enums/AttributeNames.js +37 -0
  164. package/build/esm/integrations/tracing/fastify/v3/enums/AttributeNames.js.map +1 -0
  165. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js +302 -0
  166. package/build/esm/integrations/tracing/fastify/v3/instrumentation.js.map +1 -0
  167. package/build/esm/integrations/tracing/fastify/v3/utils.js +131 -0
  168. package/build/esm/integrations/tracing/fastify/v3/utils.js.map +1 -0
  169. package/build/esm/integrations/tracing/firebase/firebase.js +47 -0
  170. package/build/esm/integrations/tracing/firebase/firebase.js.map +1 -0
  171. package/build/esm/integrations/tracing/firebase/otel/firebaseInstrumentation.js +42 -0
  172. package/build/esm/integrations/tracing/firebase/otel/firebaseInstrumentation.js.map +1 -0
  173. package/build/esm/integrations/tracing/firebase/otel/patches/firestore.js +294 -0
  174. package/build/esm/integrations/tracing/firebase/otel/patches/firestore.js.map +1 -0
  175. package/build/esm/integrations/tracing/firebase/otel/patches/functions.js +262 -0
  176. package/build/esm/integrations/tracing/firebase/otel/patches/functions.js.map +1 -0
  177. package/build/esm/integrations/tracing/genericPool.js +56 -0
  178. package/build/esm/integrations/tracing/genericPool.js.map +1 -0
  179. package/build/esm/integrations/tracing/google-genai/index.js +75 -0
  180. package/build/esm/integrations/tracing/google-genai/index.js.map +1 -0
  181. package/build/esm/integrations/tracing/google-genai/instrumentation.js +86 -0
  182. package/build/esm/integrations/tracing/google-genai/instrumentation.js.map +1 -0
  183. package/build/esm/integrations/tracing/graphql.js +124 -0
  184. package/build/esm/integrations/tracing/graphql.js.map +1 -0
  185. package/build/esm/integrations/tracing/hapi/index.js +130 -0
  186. package/build/esm/integrations/tracing/hapi/index.js.map +1 -0
  187. package/build/esm/integrations/tracing/hono/constants.js +12 -0
  188. package/build/esm/integrations/tracing/hono/constants.js.map +1 -0
  189. package/build/esm/integrations/tracing/hono/index.js +133 -0
  190. package/build/esm/integrations/tracing/hono/index.js.map +1 -0
  191. package/build/esm/integrations/tracing/hono/instrumentation.js +234 -0
  192. package/build/esm/integrations/tracing/hono/instrumentation.js.map +1 -0
  193. package/build/esm/integrations/tracing/index.js +107 -0
  194. package/build/esm/integrations/tracing/index.js.map +1 -0
  195. package/build/esm/integrations/tracing/kafka.js +45 -0
  196. package/build/esm/integrations/tracing/kafka.js.map +1 -0
  197. package/build/esm/integrations/tracing/knex.js +54 -0
  198. package/build/esm/integrations/tracing/knex.js.map +1 -0
  199. package/build/esm/integrations/tracing/koa.js +134 -0
  200. package/build/esm/integrations/tracing/koa.js.map +1 -0
  201. package/build/esm/integrations/tracing/langchain/index.js +113 -0
  202. package/build/esm/integrations/tracing/langchain/index.js.map +1 -0
  203. package/build/esm/integrations/tracing/langchain/instrumentation.js +218 -0
  204. package/build/esm/integrations/tracing/langchain/instrumentation.js.map +1 -0
  205. package/build/esm/integrations/tracing/langgraph/index.js +90 -0
  206. package/build/esm/integrations/tracing/langgraph/index.js.map +1 -0
  207. package/build/esm/integrations/tracing/langgraph/instrumentation.js +58 -0
  208. package/build/esm/integrations/tracing/langgraph/instrumentation.js.map +1 -0
  209. package/build/esm/integrations/tracing/lrumemoizer.js +34 -0
  210. package/build/esm/integrations/tracing/lrumemoizer.js.map +1 -0
  211. package/build/esm/integrations/tracing/mongo.js +89 -0
  212. package/build/esm/integrations/tracing/mongo.js.map +1 -0
  213. package/build/esm/integrations/tracing/mongoose.js +43 -0
  214. package/build/esm/integrations/tracing/mongoose.js.map +1 -0
  215. package/build/esm/integrations/tracing/mysql.js +35 -0
  216. package/build/esm/integrations/tracing/mysql.js.map +1 -0
  217. package/build/esm/integrations/tracing/mysql2.js +43 -0
  218. package/build/esm/integrations/tracing/mysql2.js.map +1 -0
  219. package/build/esm/integrations/tracing/openai/index.js +75 -0
  220. package/build/esm/integrations/tracing/openai/index.js.map +1 -0
  221. package/build/esm/integrations/tracing/openai/instrumentation.js +102 -0
  222. package/build/esm/integrations/tracing/openai/instrumentation.js.map +1 -0
  223. package/build/esm/integrations/tracing/postgres.js +45 -0
  224. package/build/esm/integrations/tracing/postgres.js.map +1 -0
  225. package/build/esm/integrations/tracing/postgresjs.js +374 -0
  226. package/build/esm/integrations/tracing/postgresjs.js.map +1 -0
  227. package/build/esm/integrations/tracing/prisma.js +200 -0
  228. package/build/esm/integrations/tracing/prisma.js.map +1 -0
  229. package/build/esm/integrations/tracing/redis.js +117 -0
  230. package/build/esm/integrations/tracing/redis.js.map +1 -0
  231. package/build/esm/integrations/tracing/tedious.js +64 -0
  232. package/build/esm/integrations/tracing/tedious.js.map +1 -0
  233. package/build/esm/integrations/tracing/vercelai/constants.js +4 -0
  234. package/build/esm/integrations/tracing/vercelai/constants.js.map +1 -0
  235. package/build/esm/integrations/tracing/vercelai/index.js +79 -0
  236. package/build/esm/integrations/tracing/vercelai/index.js.map +1 -0
  237. package/build/esm/integrations/tracing/vercelai/instrumentation.js +269 -0
  238. package/build/esm/integrations/tracing/vercelai/instrumentation.js.map +1 -0
  239. package/build/esm/package.json +1 -0
  240. package/build/esm/preload.js +21 -0
  241. package/build/esm/preload.js.map +1 -0
  242. package/build/esm/sdk/index.js +73 -0
  243. package/build/esm/sdk/index.js.map +1 -0
  244. package/build/esm/sdk/initOtel.js +121 -0
  245. package/build/esm/sdk/initOtel.js.map +1 -0
  246. package/build/esm/utils/redisCache.js +114 -0
  247. package/build/esm/utils/redisCache.js.map +1 -0
  248. package/build/import-hook.mjs +5 -0
  249. package/build/loader-hook.mjs +1 -0
  250. package/build/types/debug-build.d.ts +7 -0
  251. package/build/types/debug-build.d.ts.map +1 -0
  252. package/build/types/index.d.ts +42 -0
  253. package/build/types/index.d.ts.map +1 -0
  254. package/build/types/init.d.ts +2 -0
  255. package/build/types/init.d.ts.map +1 -0
  256. package/build/types/integrations/featureFlagShims/growthbook.d.ts +6 -0
  257. package/build/types/integrations/featureFlagShims/growthbook.d.ts.map +1 -0
  258. package/build/types/integrations/featureFlagShims/index.d.ts +6 -0
  259. package/build/types/integrations/featureFlagShims/index.d.ts.map +1 -0
  260. package/build/types/integrations/featureFlagShims/launchDarkly.d.ts +10 -0
  261. package/build/types/integrations/featureFlagShims/launchDarkly.d.ts.map +1 -0
  262. package/build/types/integrations/featureFlagShims/openFeature.d.ts +23 -0
  263. package/build/types/integrations/featureFlagShims/openFeature.d.ts.map +1 -0
  264. package/build/types/integrations/featureFlagShims/statsig.d.ts +6 -0
  265. package/build/types/integrations/featureFlagShims/statsig.d.ts.map +1 -0
  266. package/build/types/integrations/featureFlagShims/unleash.d.ts +6 -0
  267. package/build/types/integrations/featureFlagShims/unleash.d.ts.map +1 -0
  268. package/build/types/integrations/fs.d.ts +24 -0
  269. package/build/types/integrations/fs.d.ts.map +1 -0
  270. package/build/types/integrations/http.d.ts +136 -0
  271. package/build/types/integrations/http.d.ts.map +1 -0
  272. package/build/types/integrations/node-fetch.d.ts +36 -0
  273. package/build/types/integrations/node-fetch.d.ts.map +1 -0
  274. package/build/types/integrations/tracing/amqplib.d.ts +20 -0
  275. package/build/types/integrations/tracing/amqplib.d.ts.map +1 -0
  276. package/build/types/integrations/tracing/anthropic-ai/index.d.ts +59 -0
  277. package/build/types/integrations/tracing/anthropic-ai/index.d.ts.map +1 -0
  278. package/build/types/integrations/tracing/anthropic-ai/instrumentation.d.ts +19 -0
  279. package/build/types/integrations/tracing/anthropic-ai/instrumentation.d.ts.map +1 -0
  280. package/build/types/integrations/tracing/connect.d.ts +46 -0
  281. package/build/types/integrations/tracing/connect.d.ts.map +1 -0
  282. package/build/types/integrations/tracing/dataloader.d.ts +20 -0
  283. package/build/types/integrations/tracing/dataloader.d.ts.map +1 -0
  284. package/build/types/integrations/tracing/express.d.ts +72 -0
  285. package/build/types/integrations/tracing/express.d.ts.map +1 -0
  286. package/build/types/integrations/tracing/fastify/index.d.ts +119 -0
  287. package/build/types/integrations/tracing/fastify/index.d.ts.map +1 -0
  288. package/build/types/integrations/tracing/fastify/types.d.ts +33 -0
  289. package/build/types/integrations/tracing/fastify/types.d.ts.map +1 -0
  290. package/build/types/integrations/tracing/fastify/v3/constants.d.ts +3 -0
  291. package/build/types/integrations/tracing/fastify/v3/constants.d.ts.map +1 -0
  292. package/build/types/integrations/tracing/fastify/v3/enums/AttributeNames.d.ts +15 -0
  293. package/build/types/integrations/tracing/fastify/v3/enums/AttributeNames.d.ts.map +1 -0
  294. package/build/types/integrations/tracing/fastify/v3/instrumentation.d.ts +16 -0
  295. package/build/types/integrations/tracing/fastify/v3/instrumentation.d.ts.map +1 -0
  296. package/build/types/integrations/tracing/fastify/v3/internal-types.d.ts +7 -0
  297. package/build/types/integrations/tracing/fastify/v3/internal-types.d.ts.map +1 -0
  298. package/build/types/integrations/tracing/fastify/v3/types.d.ts +21 -0
  299. package/build/types/integrations/tracing/fastify/v3/types.d.ts.map +1 -0
  300. package/build/types/integrations/tracing/fastify/v3/utils.d.ts +28 -0
  301. package/build/types/integrations/tracing/fastify/v3/utils.d.ts.map +1 -0
  302. package/build/types/integrations/tracing/firebase/firebase.d.ts +6 -0
  303. package/build/types/integrations/tracing/firebase/firebase.d.ts.map +1 -0
  304. package/build/types/integrations/tracing/firebase/index.d.ts +2 -0
  305. package/build/types/integrations/tracing/firebase/index.d.ts.map +1 -0
  306. package/build/types/integrations/tracing/firebase/otel/firebaseInstrumentation.d.ts +19 -0
  307. package/build/types/integrations/tracing/firebase/otel/firebaseInstrumentation.d.ts.map +1 -0
  308. package/build/types/integrations/tracing/firebase/otel/index.d.ts +3 -0
  309. package/build/types/integrations/tracing/firebase/otel/index.d.ts.map +1 -0
  310. package/build/types/integrations/tracing/firebase/otel/patches/firestore.d.ts +25 -0
  311. package/build/types/integrations/tracing/firebase/otel/patches/firestore.d.ts.map +1 -0
  312. package/build/types/integrations/tracing/firebase/otel/patches/functions.d.ts +23 -0
  313. package/build/types/integrations/tracing/firebase/otel/patches/functions.d.ts.map +1 -0
  314. package/build/types/integrations/tracing/firebase/otel/types.d.ts +120 -0
  315. package/build/types/integrations/tracing/firebase/otel/types.d.ts.map +1 -0
  316. package/build/types/integrations/tracing/genericPool.d.ts +20 -0
  317. package/build/types/integrations/tracing/genericPool.d.ts.map +1 -0
  318. package/build/types/integrations/tracing/google-genai/index.d.ts +59 -0
  319. package/build/types/integrations/tracing/google-genai/index.d.ts.map +1 -0
  320. package/build/types/integrations/tracing/google-genai/instrumentation.d.ts +20 -0
  321. package/build/types/integrations/tracing/google-genai/instrumentation.d.ts.map +1 -0
  322. package/build/types/integrations/tracing/graphql.d.ts +48 -0
  323. package/build/types/integrations/tracing/graphql.d.ts.map +1 -0
  324. package/build/types/integrations/tracing/hapi/index.d.ts +50 -0
  325. package/build/types/integrations/tracing/hapi/index.d.ts.map +1 -0
  326. package/build/types/integrations/tracing/hapi/types.d.ts +166 -0
  327. package/build/types/integrations/tracing/hapi/types.d.ts.map +1 -0
  328. package/build/types/integrations/tracing/hono/constants.d.ts +11 -0
  329. package/build/types/integrations/tracing/hono/constants.d.ts.map +1 -0
  330. package/build/types/integrations/tracing/hono/index.d.ts +52 -0
  331. package/build/types/integrations/tracing/hono/index.d.ts.map +1 -0
  332. package/build/types/integrations/tracing/hono/instrumentation.d.ts +55 -0
  333. package/build/types/integrations/tracing/hono/instrumentation.d.ts.map +1 -0
  334. package/build/types/integrations/tracing/hono/types.d.ts +36 -0
  335. package/build/types/integrations/tracing/hono/types.d.ts.map +1 -0
  336. package/build/types/integrations/tracing/index.d.ts +12 -0
  337. package/build/types/integrations/tracing/index.d.ts.map +1 -0
  338. package/build/types/integrations/tracing/kafka.d.ts +19 -0
  339. package/build/types/integrations/tracing/kafka.d.ts.map +1 -0
  340. package/build/types/integrations/tracing/knex.d.ts +20 -0
  341. package/build/types/integrations/tracing/knex.d.ts.map +1 -0
  342. package/build/types/integrations/tracing/koa.d.ts +70 -0
  343. package/build/types/integrations/tracing/koa.d.ts.map +1 -0
  344. package/build/types/integrations/tracing/langchain/index.d.ts +97 -0
  345. package/build/types/integrations/tracing/langchain/index.d.ts.map +1 -0
  346. package/build/types/integrations/tracing/langchain/instrumentation.d.ts +29 -0
  347. package/build/types/integrations/tracing/langchain/instrumentation.d.ts.map +1 -0
  348. package/build/types/integrations/tracing/langgraph/index.d.ts +74 -0
  349. package/build/types/integrations/tracing/langgraph/index.d.ts.map +1 -0
  350. package/build/types/integrations/tracing/langgraph/instrumentation.d.ts +19 -0
  351. package/build/types/integrations/tracing/langgraph/instrumentation.d.ts.map +1 -0
  352. package/build/types/integrations/tracing/lrumemoizer.d.ts +19 -0
  353. package/build/types/integrations/tracing/lrumemoizer.d.ts.map +1 -0
  354. package/build/types/integrations/tracing/mongo.d.ts +24 -0
  355. package/build/types/integrations/tracing/mongo.d.ts.map +1 -0
  356. package/build/types/integrations/tracing/mongoose.d.ts +20 -0
  357. package/build/types/integrations/tracing/mongoose.d.ts.map +1 -0
  358. package/build/types/integrations/tracing/mysql.d.ts +20 -0
  359. package/build/types/integrations/tracing/mysql.d.ts.map +1 -0
  360. package/build/types/integrations/tracing/mysql2.d.ts +20 -0
  361. package/build/types/integrations/tracing/mysql2.d.ts.map +1 -0
  362. package/build/types/integrations/tracing/openai/index.d.ts +59 -0
  363. package/build/types/integrations/tracing/openai/index.d.ts.map +1 -0
  364. package/build/types/integrations/tracing/openai/instrumentation.d.ts +26 -0
  365. package/build/types/integrations/tracing/openai/instrumentation.d.ts.map +1 -0
  366. package/build/types/integrations/tracing/postgres.d.ts +24 -0
  367. package/build/types/integrations/tracing/postgres.d.ts.map +1 -0
  368. package/build/types/integrations/tracing/postgresjs.d.ts +101 -0
  369. package/build/types/integrations/tracing/postgresjs.d.ts.map +1 -0
  370. package/build/types/integrations/tracing/prisma/vendor/v5-tracing-helper.d.ts +38 -0
  371. package/build/types/integrations/tracing/prisma/vendor/v5-tracing-helper.d.ts.map +1 -0
  372. package/build/types/integrations/tracing/prisma/vendor/v6-tracing-helper.d.ts +31 -0
  373. package/build/types/integrations/tracing/prisma/vendor/v6-tracing-helper.d.ts.map +1 -0
  374. package/build/types/integrations/tracing/prisma.d.ts +50 -0
  375. package/build/types/integrations/tracing/prisma.d.ts.map +1 -0
  376. package/build/types/integrations/tracing/redis.d.ts +41 -0
  377. package/build/types/integrations/tracing/redis.d.ts.map +1 -0
  378. package/build/types/integrations/tracing/tedious.d.ts +20 -0
  379. package/build/types/integrations/tracing/tedious.d.ts.map +1 -0
  380. package/build/types/integrations/tracing/vercelai/constants.d.ts +2 -0
  381. package/build/types/integrations/tracing/vercelai/constants.d.ts.map +1 -0
  382. package/build/types/integrations/tracing/vercelai/index.d.ts +43 -0
  383. package/build/types/integrations/tracing/vercelai/index.d.ts.map +1 -0
  384. package/build/types/integrations/tracing/vercelai/instrumentation.d.ts +56 -0
  385. package/build/types/integrations/tracing/vercelai/instrumentation.d.ts.map +1 -0
  386. package/build/types/integrations/tracing/vercelai/types.d.ts +59 -0
  387. package/build/types/integrations/tracing/vercelai/types.d.ts.map +1 -0
  388. package/build/types/preload.d.ts +2 -0
  389. package/build/types/preload.d.ts.map +1 -0
  390. package/build/types/sdk/index.d.ts +18 -0
  391. package/build/types/sdk/index.d.ts.map +1 -0
  392. package/build/types/sdk/initOtel.d.ts +28 -0
  393. package/build/types/sdk/initOtel.d.ts.map +1 -0
  394. package/build/types/types.d.ts +89 -0
  395. package/build/types/types.d.ts.map +1 -0
  396. package/build/types/utils/redisCache.d.ts +16 -0
  397. package/build/types/utils/redisCache.d.ts.map +1 -0
  398. package/build/types-ts3.8/debug-build.d.ts +7 -0
  399. package/build/types-ts3.8/index.d.ts +42 -0
  400. package/build/types-ts3.8/init.d.ts +2 -0
  401. package/build/types-ts3.8/integrations/featureFlagShims/growthbook.d.ts +6 -0
  402. package/build/types-ts3.8/integrations/featureFlagShims/index.d.ts +6 -0
  403. package/build/types-ts3.8/integrations/featureFlagShims/launchDarkly.d.ts +10 -0
  404. package/build/types-ts3.8/integrations/featureFlagShims/openFeature.d.ts +23 -0
  405. package/build/types-ts3.8/integrations/featureFlagShims/statsig.d.ts +6 -0
  406. package/build/types-ts3.8/integrations/featureFlagShims/unleash.d.ts +6 -0
  407. package/build/types-ts3.8/integrations/fs.d.ts +24 -0
  408. package/build/types-ts3.8/integrations/http.d.ts +139 -0
  409. package/build/types-ts3.8/integrations/node-fetch.d.ts +36 -0
  410. package/build/types-ts3.8/integrations/tracing/amqplib.d.ts +20 -0
  411. package/build/types-ts3.8/integrations/tracing/anthropic-ai/index.d.ts +59 -0
  412. package/build/types-ts3.8/integrations/tracing/anthropic-ai/instrumentation.d.ts +19 -0
  413. package/build/types-ts3.8/integrations/tracing/connect.d.ts +46 -0
  414. package/build/types-ts3.8/integrations/tracing/dataloader.d.ts +20 -0
  415. package/build/types-ts3.8/integrations/tracing/express.d.ts +72 -0
  416. package/build/types-ts3.8/integrations/tracing/fastify/index.d.ts +119 -0
  417. package/build/types-ts3.8/integrations/tracing/fastify/types.d.ts +33 -0
  418. package/build/types-ts3.8/integrations/tracing/fastify/v3/constants.d.ts +3 -0
  419. package/build/types-ts3.8/integrations/tracing/fastify/v3/enums/AttributeNames.d.ts +15 -0
  420. package/build/types-ts3.8/integrations/tracing/fastify/v3/instrumentation.d.ts +16 -0
  421. package/build/types-ts3.8/integrations/tracing/fastify/v3/internal-types.d.ts +7 -0
  422. package/build/types-ts3.8/integrations/tracing/fastify/v3/types.d.ts +21 -0
  423. package/build/types-ts3.8/integrations/tracing/fastify/v3/utils.d.ts +28 -0
  424. package/build/types-ts3.8/integrations/tracing/firebase/firebase.d.ts +6 -0
  425. package/build/types-ts3.8/integrations/tracing/firebase/index.d.ts +2 -0
  426. package/build/types-ts3.8/integrations/tracing/firebase/otel/firebaseInstrumentation.d.ts +19 -0
  427. package/build/types-ts3.8/integrations/tracing/firebase/otel/index.d.ts +3 -0
  428. package/build/types-ts3.8/integrations/tracing/firebase/otel/patches/firestore.d.ts +25 -0
  429. package/build/types-ts3.8/integrations/tracing/firebase/otel/patches/functions.d.ts +23 -0
  430. package/build/types-ts3.8/integrations/tracing/firebase/otel/types.d.ts +120 -0
  431. package/build/types-ts3.8/integrations/tracing/genericPool.d.ts +20 -0
  432. package/build/types-ts3.8/integrations/tracing/google-genai/index.d.ts +59 -0
  433. package/build/types-ts3.8/integrations/tracing/google-genai/instrumentation.d.ts +20 -0
  434. package/build/types-ts3.8/integrations/tracing/graphql.d.ts +48 -0
  435. package/build/types-ts3.8/integrations/tracing/hapi/index.d.ts +50 -0
  436. package/build/types-ts3.8/integrations/tracing/hapi/types.d.ts +166 -0
  437. package/build/types-ts3.8/integrations/tracing/hono/constants.d.ts +11 -0
  438. package/build/types-ts3.8/integrations/tracing/hono/index.d.ts +52 -0
  439. package/build/types-ts3.8/integrations/tracing/hono/instrumentation.d.ts +55 -0
  440. package/build/types-ts3.8/integrations/tracing/hono/types.d.ts +36 -0
  441. package/build/types-ts3.8/integrations/tracing/index.d.ts +12 -0
  442. package/build/types-ts3.8/integrations/tracing/kafka.d.ts +19 -0
  443. package/build/types-ts3.8/integrations/tracing/knex.d.ts +20 -0
  444. package/build/types-ts3.8/integrations/tracing/koa.d.ts +70 -0
  445. package/build/types-ts3.8/integrations/tracing/langchain/index.d.ts +97 -0
  446. package/build/types-ts3.8/integrations/tracing/langchain/instrumentation.d.ts +29 -0
  447. package/build/types-ts3.8/integrations/tracing/langgraph/index.d.ts +74 -0
  448. package/build/types-ts3.8/integrations/tracing/langgraph/instrumentation.d.ts +19 -0
  449. package/build/types-ts3.8/integrations/tracing/lrumemoizer.d.ts +19 -0
  450. package/build/types-ts3.8/integrations/tracing/mongo.d.ts +24 -0
  451. package/build/types-ts3.8/integrations/tracing/mongoose.d.ts +20 -0
  452. package/build/types-ts3.8/integrations/tracing/mysql.d.ts +20 -0
  453. package/build/types-ts3.8/integrations/tracing/mysql2.d.ts +20 -0
  454. package/build/types-ts3.8/integrations/tracing/openai/index.d.ts +59 -0
  455. package/build/types-ts3.8/integrations/tracing/openai/instrumentation.d.ts +26 -0
  456. package/build/types-ts3.8/integrations/tracing/postgres.d.ts +24 -0
  457. package/build/types-ts3.8/integrations/tracing/postgresjs.d.ts +101 -0
  458. package/build/types-ts3.8/integrations/tracing/prisma/vendor/v5-tracing-helper.d.ts +44 -0
  459. package/build/types-ts3.8/integrations/tracing/prisma/vendor/v6-tracing-helper.d.ts +34 -0
  460. package/build/types-ts3.8/integrations/tracing/prisma.d.ts +50 -0
  461. package/build/types-ts3.8/integrations/tracing/redis.d.ts +41 -0
  462. package/build/types-ts3.8/integrations/tracing/tedious.d.ts +20 -0
  463. package/build/types-ts3.8/integrations/tracing/vercelai/constants.d.ts +2 -0
  464. package/build/types-ts3.8/integrations/tracing/vercelai/index.d.ts +43 -0
  465. package/build/types-ts3.8/integrations/tracing/vercelai/instrumentation.d.ts +56 -0
  466. package/build/types-ts3.8/integrations/tracing/vercelai/types.d.ts +59 -0
  467. package/build/types-ts3.8/preload.d.ts +2 -0
  468. package/build/types-ts3.8/sdk/index.d.ts +18 -0
  469. package/build/types-ts3.8/sdk/initOtel.d.ts +31 -0
  470. package/build/types-ts3.8/types.d.ts +89 -0
  471. package/build/types-ts3.8/utils/redisCache.d.ts +16 -0
  472. package/changes.json +10 -0
  473. package/package.json +150 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"instrumentation.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/anthropic-ai/instrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EAErC,MAAM,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAU1E,KAAK,iCAAiC,GAAG,qBAAqB,GAAG,kBAAkB,CAAC;AAUpF;;GAEG;AACH,qBAAa,gCAAiC,SAAQ,mBAAmB,CAAC,iCAAiC,CAAC;gBACvF,MAAM,GAAE,iCAAsC;IAIjE;;OAEG;IACI,IAAI,IAAI,+BAA+B;IAS9C;;OAEG;IACH,OAAO,CAAC,MAAM;CA6Df"}
@@ -0,0 +1,46 @@
1
+ import { ConnectInstrumentation } from '@opentelemetry/instrumentation-connect';
2
+ type ConnectApp = {
3
+ use: (middleware: any) => void;
4
+ };
5
+ export declare const instrumentConnect: ((options?: unknown) => ConnectInstrumentation) & {
6
+ id: string;
7
+ };
8
+ /**
9
+ * Adds Sentry tracing instrumentation for [Connect](https://github.com/senchalabs/connect/).
10
+ *
11
+ * If you also want to capture errors, you need to call `setupConnectErrorHandler(app)` after you initialize your connect app.
12
+ *
13
+ * For more information, see the [connect documentation](https://docs.sentry.io/platforms/javascript/guides/connect/).
14
+ *
15
+ * @example
16
+ * ```javascript
17
+ * const Sentry = require('@sentry/node');
18
+ *
19
+ * Sentry.init({
20
+ * integrations: [Sentry.connectIntegration()],
21
+ * })
22
+ * ```
23
+ */
24
+ export declare const connectIntegration: () => import("@sentry/core").Integration;
25
+ /**
26
+ * Add a Connect middleware to capture errors to Sentry.
27
+ *
28
+ * @param app The Connect app to attach the error handler to
29
+ *
30
+ * @example
31
+ * ```javascript
32
+ * const Sentry = require('@sentry/node');
33
+ * const connect = require("connect");
34
+ *
35
+ * const app = connect();
36
+ *
37
+ * Sentry.setupConnectErrorHandler(app);
38
+ *
39
+ * // Add you connect routes here
40
+ *
41
+ * app.listen(3000);
42
+ * ```
43
+ */
44
+ export declare const setupConnectErrorHandler: (app: ConnectApp) => void;
45
+ export {};
46
+ //# sourceMappingURL=connect.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"connect.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/connect.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAYhF,KAAK,UAAU,GAAG;IAEhB,GAAG,EAAE,CAAC,UAAU,EAAE,GAAG,KAAK,IAAI,CAAC;CAChC,CAAC;AAIF,eAAO,MAAM,iBAAiB;;CAA+E,CAAC;AAW9G;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,0CAAyC,CAAC;AAazE;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,wBAAwB,GAAI,KAAK,UAAU,KAAG,IAc1D,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { DataloaderInstrumentation } from '@opentelemetry/instrumentation-dataloader';
2
+ export declare const instrumentDataloader: ((options?: unknown) => DataloaderInstrumentation) & {
3
+ id: string;
4
+ };
5
+ /**
6
+ * Adds Sentry tracing instrumentation for the [dataloader](https://www.npmjs.com/package/dataloader) library.
7
+ *
8
+ * For more information, see the [`dataloaderIntegration` documentation](https://docs.sentry.io/platforms/javascript/guides/node/configuration/integrations/dataloader/).
9
+ *
10
+ * @example
11
+ * ```javascript
12
+ * const Sentry = require('@sentry/node');
13
+ *
14
+ * Sentry.init({
15
+ * integrations: [Sentry.dataloaderIntegration()],
16
+ * });
17
+ * ```
18
+ */
19
+ export declare const dataloaderIntegration: () => import("@sentry/core").Integration;
20
+ //# sourceMappingURL=dataloader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dataloader.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/dataloader.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,yBAAyB,EAAE,MAAM,2CAA2C,CAAC;AAYtF,eAAO,MAAM,oBAAoB;;CAMhC,CAAC;AAuCF;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,qBAAqB,0CAA4C,CAAC"}
@@ -0,0 +1,72 @@
1
+ import type * as http from 'node:http';
2
+ import { ExpressInstrumentation } from '@opentelemetry/instrumentation-express';
3
+ export declare const instrumentExpress: ((options?: unknown) => ExpressInstrumentation) & {
4
+ id: string;
5
+ };
6
+ /**
7
+ * Adds Sentry tracing instrumentation for [Express](https://expressjs.com/).
8
+ *
9
+ * If you also want to capture errors, you need to call `setupExpressErrorHandler(app)` after you set up your Express server.
10
+ *
11
+ * For more information, see the [express documentation](https://docs.sentry.io/platforms/javascript/guides/express/).
12
+ *
13
+ * @example
14
+ * ```javascript
15
+ * const Sentry = require('@sentry/node');
16
+ *
17
+ * Sentry.init({
18
+ * integrations: [Sentry.expressIntegration()],
19
+ * })
20
+ * ```
21
+ */
22
+ export declare const expressIntegration: () => import("@sentry/core").Integration;
23
+ interface MiddlewareError extends Error {
24
+ status?: number | string;
25
+ statusCode?: number | string;
26
+ status_code?: number | string;
27
+ output?: {
28
+ statusCode?: number | string;
29
+ };
30
+ }
31
+ type ExpressMiddleware = (req: http.IncomingMessage, res: http.ServerResponse, next: () => void) => void;
32
+ type ExpressErrorMiddleware = (error: MiddlewareError, req: http.IncomingMessage, res: http.ServerResponse, next: (error: MiddlewareError) => void) => void;
33
+ interface ExpressHandlerOptions {
34
+ /**
35
+ * Callback method deciding whether error should be captured and sent to Sentry
36
+ * @param error Captured middleware error
37
+ */
38
+ shouldHandleError?(this: void, error: MiddlewareError): boolean;
39
+ }
40
+ /**
41
+ * An Express-compatible error handler.
42
+ */
43
+ export declare function expressErrorHandler(options?: ExpressHandlerOptions): ExpressErrorMiddleware;
44
+ /**
45
+ * Add an Express error handler to capture errors to Sentry.
46
+ *
47
+ * The error handler must be before any other middleware and after all controllers.
48
+ *
49
+ * @param app The Express instances
50
+ * @param options {ExpressHandlerOptions} Configuration options for the handler
51
+ *
52
+ * @example
53
+ * ```javascript
54
+ * const Sentry = require('@sentry/node');
55
+ * const express = require("express");
56
+ *
57
+ * const app = express();
58
+ *
59
+ * // Add your routes, etc.
60
+ *
61
+ * // Add this after all routes,
62
+ * // but before any and other error-handling middlewares are defined
63
+ * Sentry.setupExpressErrorHandler(app);
64
+ *
65
+ * app.listen(3000);
66
+ * ```
67
+ */
68
+ export declare function setupExpressErrorHandler(app: {
69
+ use: (middleware: ExpressMiddleware | ExpressErrorMiddleware) => unknown;
70
+ }, options?: ExpressHandlerOptions): void;
71
+ export {};
72
+ //# sourceMappingURL=express.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"express.d.ts","sourceRoot":"","sources":["../../../../src/integrations/tracing/express.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,IAAI,MAAM,WAAW,CAAC;AAGvC,OAAO,EAAE,sBAAsB,EAAE,MAAM,wCAAwC,CAAC;AAiDhF,eAAO,MAAM,iBAAiB;;CAO7B,CAAC;AAWF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,0CAAyC,CAAC;AAEzE,UAAU,eAAgB,SAAQ,KAAK;IACrC,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC7B,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC9B,MAAM,CAAC,EAAE;QACP,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;KAC9B,CAAC;CACH;AAED,KAAK,iBAAiB,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,eAAe,EAAE,GAAG,EAAE,IAAI,CAAC,cAAc,EAAE,IAAI,EAAE,MAAM,IAAI,KAAK,IAAI,CAAC;AAEzG,KAAK,sBAAsB,GAAG,CAC5B,KAAK,EAAE,eAAe,EACtB,GAAG,EAAE,IAAI,CAAC,eAAe,EACzB,GAAG,EAAE,IAAI,CAAC,cAAc,EACxB,IAAI,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,IAAI,KACnC,IAAI,CAAC;AAEV,UAAU,qBAAqB;IAC7B;;;OAGG;IACH,iBAAiB,CAAC,CAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,eAAe,GAAG,OAAO,CAAC;CACjE;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,OAAO,CAAC,EAAE,qBAAqB,GAAG,sBAAsB,CAqB3F;AAgBD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,wBAAgB,wBAAwB,CACtC,GAAG,EAAE;IAAE,GAAG,EAAE,CAAC,UAAU,EAAE,iBAAiB,GAAG,sBAAsB,KAAK,OAAO,CAAA;CAAE,EACjF,OAAO,CAAC,EAAE,qBAAqB,GAC9B,IAAI,CAIN"}
@@ -0,0 +1,119 @@
1
+ import type { Instrumentation, InstrumentationConfig } from '@opentelemetry/instrumentation';
2
+ import type { FastifyMinimal, FastifyReply, FastifyRequest } from './types';
3
+ import { FastifyInstrumentationV3 } from './v3/instrumentation';
4
+ /**
5
+ * Options for the Fastify integration.
6
+ *
7
+ * `shouldHandleError` - Callback method deciding whether error should be captured and sent to Sentry
8
+ * This is used on Fastify v5 where Sentry handles errors in the diagnostics channel.
9
+ * Fastify v3 and v4 use `setupFastifyErrorHandler` instead.
10
+ *
11
+ * @example
12
+ *
13
+ * ```javascript
14
+ * Sentry.init({
15
+ * integrations: [
16
+ * Sentry.fastifyIntegration({
17
+ * shouldHandleError(_error, _request, reply) {
18
+ * return reply.statusCode >= 500;
19
+ * },
20
+ * });
21
+ * },
22
+ * });
23
+ * ```
24
+ *
25
+ */
26
+ interface FastifyIntegrationOptions {
27
+ /**
28
+ * Callback method deciding whether error should be captured and sent to Sentry
29
+ * This is used on Fastify v5 where Sentry handles errors in the diagnostics channel.
30
+ * Fastify v3 and v4 use `setupFastifyErrorHandler` instead.
31
+ *
32
+ * @param error Captured Fastify error
33
+ * @param request Fastify request (or any object containing at least method, routeOptions.url, and routerPath)
34
+ * @param reply Fastify reply (or any object containing at least statusCode)
35
+ */
36
+ shouldHandleError: (error: Error, request: FastifyRequest, reply: FastifyReply) => boolean;
37
+ }
38
+ interface FastifyHandlerOptions {
39
+ /**
40
+ * Callback method deciding whether error should be captured and sent to Sentry
41
+ *
42
+ * @param error Captured Fastify error
43
+ * @param request Fastify request (or any object containing at least method, routeOptions.url, and routerPath)
44
+ * @param reply Fastify reply (or any object containing at least statusCode)
45
+ *
46
+ * @example
47
+ *
48
+ *
49
+ * ```javascript
50
+ * setupFastifyErrorHandler(app, {
51
+ * shouldHandleError(_error, _request, reply) {
52
+ * return reply.statusCode >= 400;
53
+ * },
54
+ * });
55
+ * ```
56
+ *
57
+ *
58
+ * If using TypeScript, you can cast the request and reply to get full type safety.
59
+ *
60
+ * ```typescript
61
+ * import type { FastifyRequest, FastifyReply } from 'fastify';
62
+ *
63
+ * setupFastifyErrorHandler(app, {
64
+ * shouldHandleError(error, minimalRequest, minimalReply) {
65
+ * const request = minimalRequest as FastifyRequest;
66
+ * const reply = minimalReply as FastifyReply;
67
+ * return reply.statusCode >= 500;
68
+ * },
69
+ * });
70
+ * ```
71
+ */
72
+ shouldHandleError: (error: Error, request: FastifyRequest, reply: FastifyReply) => boolean;
73
+ }
74
+ export declare const instrumentFastifyV3: ((options?: unknown) => FastifyInstrumentationV3) & {
75
+ id: string;
76
+ };
77
+ export declare const instrumentFastify: ((options?: unknown) => Instrumentation<InstrumentationConfig>) & {
78
+ id: string;
79
+ };
80
+ /**
81
+ * Adds Sentry tracing instrumentation for [Fastify](https://fastify.dev/).
82
+ *
83
+ * If you also want to capture errors, you need to call `setupFastifyErrorHandler(app)` after you set up your Fastify server.
84
+ *
85
+ * For more information, see the [fastify documentation](https://docs.sentry.io/platforms/javascript/guides/fastify/).
86
+ *
87
+ * @example
88
+ * ```javascript
89
+ * const Sentry = require('@sentry/node');
90
+ *
91
+ * Sentry.init({
92
+ * integrations: [Sentry.fastifyIntegration()],
93
+ * })
94
+ * ```
95
+ */
96
+ export declare const fastifyIntegration: (options?: Partial<FastifyIntegrationOptions> | undefined) => import("@sentry/core").Integration;
97
+ /**
98
+ * Add an Fastify error handler to capture errors to Sentry.
99
+ *
100
+ * @param fastify The Fastify instance to which to add the error handler
101
+ * @param options Configuration options for the handler
102
+ *
103
+ * @example
104
+ * ```javascript
105
+ * const Sentry = require('@sentry/node');
106
+ * const Fastify = require("fastify");
107
+ *
108
+ * const app = Fastify();
109
+ *
110
+ * Sentry.setupFastifyErrorHandler(app);
111
+ *
112
+ * // Add your routes, etc.
113
+ *
114
+ * app.listen({ port: 3000 });
115
+ * ```
116
+ */
117
+ export declare function setupFastifyErrorHandler(fastify: FastifyMinimal, options?: Partial<FastifyHandlerOptions>): void;
118
+ export {};
119
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/fastify/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAc7F,OAAO,KAAK,EAAmB,cAAc,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAC7F,OAAO,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAEhE;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,UAAU,yBAAyB;IACjC;;;;;;;;OAQG;IACH,iBAAiB,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,KAAK,OAAO,CAAC;CAC5F;AAED,UAAU,qBAAqB;IAC7B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACH,iBAAiB,EAAE,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,KAAK,OAAO,CAAC;CAC5F;AAID,eAAO,MAAM,mBAAmB;;CAG/B,CAAC;AA0CF,eAAO,MAAM,iBAAiB;;CAmC5B,CAAC;AAsBH;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,kGAE9B,CAAC;AAaF;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,wBAAwB,CAAC,OAAO,EAAE,cAAc,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,qBAAqB,CAAC,GAAG,IAAI,CAmBhH"}
@@ -0,0 +1,33 @@
1
+ export type HandlerOriginal = ((request: FastifyRequest, reply: FastifyReply, done: HookHandlerDoneFunction) => Promise<void>) | ((request: FastifyRequest, reply: FastifyReply, done: HookHandlerDoneFunction) => void);
2
+ export type FastifyError = any;
3
+ export type HookHandlerDoneFunction = <TError extends Error = FastifyError>(err?: TError) => void;
4
+ export type FastifyErrorCodes = any;
5
+ export type FastifyPlugin = (instance: FastifyInstance, opts: any, done: HookHandlerDoneFunction) => unknown | Promise<unknown>;
6
+ export interface FastifyInstance {
7
+ version: string;
8
+ register: (plugin: any) => FastifyInstance;
9
+ after: (listener?: (err: Error) => void) => FastifyInstance;
10
+ addHook(hook: string, handler: HandlerOriginal): FastifyInstance;
11
+ addHook(hook: 'onError', handler: (request: FastifyRequest, reply: FastifyReply, error: Error) => void): FastifyInstance;
12
+ addHook(hook: 'onRequest', handler: (request: FastifyRequest, reply: FastifyReply) => void): FastifyInstance;
13
+ }
14
+ /**
15
+ * Minimal type for `setupFastifyErrorHandler` parameter.
16
+ * Uses structural typing without overloads to avoid exactOptionalPropertyTypes issues.
17
+ * https://github.com/getsentry/sentry-javascript/issues/18619
18
+ */
19
+ export type FastifyMinimal = {
20
+ register: (plugin: (instance: any, opts: any, done: () => void) => void) => unknown;
21
+ };
22
+ export interface FastifyReply {
23
+ send: () => FastifyReply;
24
+ statusCode: number;
25
+ }
26
+ export interface FastifyRequest {
27
+ method?: string;
28
+ routeOptions?: {
29
+ url?: string;
30
+ };
31
+ routerPath?: string;
32
+ }
33
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/fastify/types.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,eAAe,GACvB,CAAC,CAAC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,EAAE,IAAI,EAAE,uBAAuB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC,GAChG,CAAC,CAAC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,EAAE,IAAI,EAAE,uBAAuB,KAAK,IAAI,CAAC,CAAC;AAE5F,MAAM,MAAM,YAAY,GAAG,GAAG,CAAC;AAE/B,MAAM,MAAM,uBAAuB,GAAG,CAAC,MAAM,SAAS,KAAK,GAAG,YAAY,EAAE,GAAG,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;AAElG,MAAM,MAAM,iBAAiB,GAAG,GAAG,CAAC;AAEpC,MAAM,MAAM,aAAa,GAAG,CAC1B,QAAQ,EAAE,eAAe,EACzB,IAAI,EAAE,GAAG,EACT,IAAI,EAAE,uBAAuB,KAC1B,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;AAEhC,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,CAAC,MAAM,EAAE,GAAG,KAAK,eAAe,CAAC;IAC3C,KAAK,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,KAAK,KAAK,IAAI,KAAK,eAAe,CAAC;IAC5D,OAAO,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,eAAe,GAAG,eAAe,CAAC;IACjE,OAAO,CACL,IAAI,EAAE,SAAS,EACf,OAAO,EAAE,CAAC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,EAAE,KAAK,EAAE,KAAK,KAAK,IAAI,GAC5E,eAAe,CAAC;IACnB,OAAO,CAAC,IAAI,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC,OAAO,EAAE,cAAc,EAAE,KAAK,EAAE,YAAY,KAAK,IAAI,GAAG,eAAe,CAAC;CAC9G;AAED;;;;GAIG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B,QAAQ,EAAE,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE,IAAI,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,IAAI,KAAK,IAAI,KAAK,OAAO,CAAC;CACrF,CAAC;AAEF,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,YAAY,CAAC;IACzB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,YAAY,CAAC,EAAE;QACb,GAAG,CAAC,EAAE,MAAM,CAAC;KACd,CAAC;IACF,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB"}
@@ -0,0 +1,3 @@
1
+ export declare const spanRequestSymbol: unique symbol;
2
+ export declare const hooksNamesToWrap: Set<string>;
3
+ //# sourceMappingURL=constants.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/constants.ts"],"names":[],"mappings":"AAiBA,eAAO,MAAM,iBAAiB,eAAsE,CAAC;AAMrG,eAAO,MAAM,gBAAgB,aAU3B,CAAC"}
@@ -0,0 +1,15 @@
1
+ export declare enum AttributeNames {
2
+ FASTIFY_NAME = "fastify.name",
3
+ FASTIFY_TYPE = "fastify.type",
4
+ HOOK_NAME = "hook.name",
5
+ PLUGIN_NAME = "plugin.name"
6
+ }
7
+ export declare enum FastifyTypes {
8
+ MIDDLEWARE = "middleware",
9
+ REQUEST_HANDLER = "request_handler"
10
+ }
11
+ export declare enum FastifyNames {
12
+ MIDDLEWARE = "middleware",
13
+ REQUEST_HANDLER = "request handler"
14
+ }
15
+ //# sourceMappingURL=AttributeNames.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AttributeNames.d.ts","sourceRoot":"","sources":["../../../../../../../src/integrations/tracing/fastify/v3/enums/AttributeNames.ts"],"names":[],"mappings":"AAkBA,oBAAY,cAAc;IACxB,YAAY,iBAAiB;IAC7B,YAAY,iBAAiB;IAC7B,SAAS,cAAc;IACvB,WAAW,gBAAgB;CAC5B;AAED,oBAAY,YAAY;IACtB,UAAU,eAAe;IACzB,eAAe,oBAAoB;CACpC;AAED,oBAAY,YAAY;IACtB,UAAU,eAAe;IACzB,eAAe,oBAAoB;CACpC"}
@@ -0,0 +1,16 @@
1
+ import { InstrumentationBase, InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
2
+ import type { FastifyInstrumentationConfig } from './types';
3
+ /**
4
+ * Fastify instrumentation for OpenTelemetry
5
+ */
6
+ export declare class FastifyInstrumentationV3 extends InstrumentationBase<FastifyInstrumentationConfig> {
7
+ constructor(config?: FastifyInstrumentationConfig);
8
+ init(): InstrumentationNodeModuleDefinition[];
9
+ private _hookOnRequest;
10
+ private _wrapHandler;
11
+ private _wrapAddHook;
12
+ private _patchConstructor;
13
+ private _patchSend;
14
+ private _hookPreHandler;
15
+ }
16
+ //# sourceMappingURL=instrumentation.d.ts.map
@@ -0,0 +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"}
@@ -0,0 +1,7 @@
1
+ import type { Span } from '@opentelemetry/api';
2
+ import type { FastifyReply } from '../types';
3
+ import type { spanRequestSymbol } from './constants';
4
+ export type PluginFastifyReply = FastifyReply & {
5
+ [spanRequestSymbol]?: Span[];
6
+ };
7
+ //# sourceMappingURL=internal-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"internal-types.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/internal-types.ts"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAErD,MAAM,MAAM,kBAAkB,GAAG,YAAY,GAAG;IAC9C,CAAC,iBAAiB,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC;CAC9B,CAAC"}
@@ -0,0 +1,21 @@
1
+ import type { Span } from '@opentelemetry/api';
2
+ import type { InstrumentationConfig } from '@opentelemetry/instrumentation';
3
+ export interface FastifyRequestInfo {
4
+ request: any;
5
+ }
6
+ /**
7
+ * Function that can be used to add custom attributes to the current span
8
+ * @param span - The Fastify handler span.
9
+ * @param info - The Fastify request info object.
10
+ */
11
+ export interface FastifyCustomAttributeFunction {
12
+ (span: Span, info: FastifyRequestInfo): void;
13
+ }
14
+ /**
15
+ * Options available for the Fastify Instrumentation
16
+ */
17
+ export interface FastifyInstrumentationConfig extends InstrumentationConfig {
18
+ /** Function for adding custom attributes to each handler span */
19
+ requestHook?: FastifyCustomAttributeFunction;
20
+ }
21
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/types.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAE5E,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,GAAG,CAAC;CACd;AAED;;;;GAIG;AACH,MAAM,WAAW,8BAA8B;IAC7C,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,kBAAkB,GAAG,IAAI,CAAC;CAC9C;AAED;;GAEG;AACH,MAAM,WAAW,4BAA6B,SAAQ,qBAAqB;IACzE,iEAAiE;IACjE,WAAW,CAAC,EAAE,8BAA8B,CAAC;CAC9C"}
@@ -0,0 +1,28 @@
1
+ import { type Attributes, type Span, type Tracer } from '@opentelemetry/api';
2
+ import type { PluginFastifyReply } from './internal-types';
3
+ /**
4
+ * Starts Span
5
+ * @param reply - reply function
6
+ * @param tracer - tracer
7
+ * @param spanName - span name
8
+ * @param spanAttributes - span attributes
9
+ */
10
+ export declare function startSpan(reply: PluginFastifyReply, tracer: Tracer, spanName: string, spanAttributes?: Attributes): Span;
11
+ /**
12
+ * Ends span
13
+ * @param reply - reply function
14
+ * @param err - error
15
+ */
16
+ export declare function endSpan(reply: PluginFastifyReply, err?: any): void;
17
+ /**
18
+ * This function handles the missing case from instrumentation package when
19
+ * execute can either return a promise or void. And using async is not an
20
+ * option as it is producing unwanted side effects.
21
+ * @param execute - function to be executed
22
+ * @param onFinish - function called when function executed
23
+ * @param preventThrowingError - prevent to throw error when execute
24
+ * function fails
25
+ */
26
+ export declare function safeExecuteInTheMiddleMaybePromise<T>(execute: () => Promise<T>, onFinish: (e: unknown, result?: T) => void, preventThrowingError?: boolean): Promise<T>;
27
+ export declare function safeExecuteInTheMiddleMaybePromise<T>(execute: () => T, onFinish: (e: unknown, result?: T) => void, preventThrowingError?: boolean): T;
28
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/fastify/v3/utils.ts"],"names":[],"mappings":"AAsBA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,IAAI,EAAkB,KAAK,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAE7F,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAE3D;;;;;;GAMG;AACH,wBAAgB,SAAS,CACvB,KAAK,EAAE,kBAAkB,EACzB,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,EAChB,cAAc,GAAE,UAAe,QAchC;AAED;;;;GAIG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,kBAAkB,EAAE,GAAG,CAAC,EAAE,GAAG,QAkB3D;AAKD;;;;;;;;GAQG;AACH,wBAAgB,kCAAkC,CAAC,CAAC,EAClD,OAAO,EAAE,MAAM,OAAO,CAAC,CAAC,CAAC,EACzB,QAAQ,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC,KAAK,IAAI,EAC1C,oBAAoB,CAAC,EAAE,OAAO,GAC7B,OAAO,CAAC,CAAC,CAAC,CAAC;AACd,wBAAgB,kCAAkC,CAAC,CAAC,EAClD,OAAO,EAAE,MAAM,CAAC,EAChB,QAAQ,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC,KAAK,IAAI,EAC1C,oBAAoB,CAAC,EAAE,OAAO,GAC7B,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { FirebaseInstrumentation } from './otel';
2
+ export declare const instrumentFirebase: ((options?: unknown) => FirebaseInstrumentation) & {
3
+ id: string;
4
+ };
5
+ export declare const firebaseIntegration: () => import("@sentry/core").Integration;
6
+ //# sourceMappingURL=firebase.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"firebase.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/firebase/firebase.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,uBAAuB,EAAsC,MAAM,QAAQ,CAAC;AA8BrF,eAAO,MAAM,kBAAkB;;CAAsF,CAAC;AAWtH,eAAO,MAAM,mBAAmB,0CAA0C,CAAC"}
@@ -0,0 +1,2 @@
1
+ export * from './firebase';
2
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/integrations/tracing/firebase/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { InstrumentationBase, type InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
2
+ import type { FirebaseInstrumentationConfig } from './types';
3
+ /**
4
+ * Instrumentation for Firebase services, specifically Firestore.
5
+ */
6
+ export declare class FirebaseInstrumentation extends InstrumentationBase<FirebaseInstrumentationConfig> {
7
+ constructor(config?: FirebaseInstrumentationConfig);
8
+ /**
9
+ * sets config
10
+ * @param config
11
+ */
12
+ setConfig(config?: FirebaseInstrumentationConfig): void;
13
+ /**
14
+ *
15
+ * @protected
16
+ */
17
+ protected init(): InstrumentationNodeModuleDefinition | InstrumentationNodeModuleDefinition[] | void;
18
+ }
19
+ //# sourceMappingURL=firebaseInstrumentation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"firebaseInstrumentation.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/firebase/otel/firebaseInstrumentation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,KAAK,mCAAmC,EAAE,MAAM,gCAAgC,CAAC;AAI/G,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,SAAS,CAAC;AAM7D;;GAEG;AACH,qBAAa,uBAAwB,SAAQ,mBAAmB,CAAC,6BAA6B,CAAC;gBAC1E,MAAM,GAAE,6BAAoE;IAI/F;;;OAGG;IACa,SAAS,CAAC,MAAM,GAAE,6BAAkC,GAAG,IAAI;IAI3E;;;OAGG;IAEH,SAAS,CAAC,IAAI,IAAI,mCAAmC,GAAG,mCAAmC,EAAE,GAAG,IAAI;CAQrG"}
@@ -0,0 +1,3 @@
1
+ export * from './firebaseInstrumentation';
2
+ export * from './types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/integrations/tracing/firebase/otel/index.ts"],"names":[],"mappings":"AACA,cAAc,2BAA2B,CAAC;AAC1C,cAAc,SAAS,CAAC"}
@@ -0,0 +1,25 @@
1
+ import type { Tracer } from '@opentelemetry/api';
2
+ import { InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
3
+ import type { FirebaseInstrumentationConfig, FirestoreSettings } from '../types';
4
+ type ShimmerWrap = (target: any, name: string, wrapper: (...args: any[]) => any) => void;
5
+ type ShimmerUnwrap = (target: any, name: string) => void;
6
+ /**
7
+ *
8
+ * @param tracer - Opentelemetry Tracer
9
+ * @param firestoreSupportedVersions - supported version of firebase/firestore
10
+ * @param wrap - reference to native instrumentation wrap function
11
+ * @param unwrap - reference to native instrumentation wrap function
12
+ */
13
+ export declare function patchFirestore(tracer: Tracer, firestoreSupportedVersions: string[], wrap: ShimmerWrap, unwrap: ShimmerUnwrap, config: FirebaseInstrumentationConfig): InstrumentationNodeModuleDefinition;
14
+ /**
15
+ * Gets the server address and port attributes from the Firestore settings.
16
+ * It's best effort to extract the address and port from the settings, especially for IPv6.
17
+ * @param span - The span to set attributes on.
18
+ * @param settings - The Firestore settings containing host information.
19
+ */
20
+ export declare function getPortAndAddress(settings: FirestoreSettings): {
21
+ address?: string;
22
+ port?: number;
23
+ };
24
+ export {};
25
+ //# sourceMappingURL=firestore.d.ts.map
@@ -0,0 +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"}
@@ -0,0 +1,23 @@
1
+ import type { Tracer } from '@opentelemetry/api';
2
+ import type { InstrumentationBase } from '@opentelemetry/instrumentation';
3
+ import { InstrumentationNodeModuleDefinition } from '@opentelemetry/instrumentation';
4
+ import type { FirebaseFunctions, FirebaseInstrumentationConfig, OverloadedParameters } from '../types';
5
+ /**
6
+ * Patches Firebase Functions v2 to add OpenTelemetry instrumentation
7
+ * @param tracer - Opentelemetry Tracer
8
+ * @param functionsSupportedVersions - supported versions of firebase-functions
9
+ * @param wrap - reference to native instrumentation wrap function
10
+ * @param unwrap - reference to native instrumentation unwrap function
11
+ * @param config - Firebase instrumentation config
12
+ */
13
+ export declare function patchFunctions(tracer: Tracer, functionsSupportedVersions: string[], wrap: InstrumentationBase['_wrap'], unwrap: InstrumentationBase['_unwrap'], config: FirebaseInstrumentationConfig): InstrumentationNodeModuleDefinition;
14
+ /**
15
+ * Patches Cloud Functions for Firebase (v2) to add OpenTelemetry instrumentation
16
+ *
17
+ * @param tracer - Opentelemetry Tracer
18
+ * @param functionsConfig - Firebase instrumentation config
19
+ * @param triggerType - Type of trigger
20
+ * @returns A function that patches the function
21
+ */
22
+ export declare function patchV2Functions<T extends FirebaseFunctions = FirebaseFunctions>(tracer: Tracer, functionsConfig: FirebaseInstrumentationConfig['functions'], triggerType: string): (original: T) => (...args: OverloadedParameters<T>) => ReturnType<T>;
23
+ //# sourceMappingURL=functions.d.ts.map
@@ -0,0 +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"}