@sentry/mcp-server 0.23.0 → 0.24.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 (813) hide show
  1. package/dist/{chunk-CUT6urMc.cjs → chunk-DoeelZqw.cjs} +21 -0
  2. package/dist/cli/parse.cjs +1 -1
  3. package/dist/cli/parse.d.cts +1 -3
  4. package/dist/cli/parse.d.cts.map +1 -1
  5. package/dist/cli/parse.d.ts +1 -3
  6. package/dist/cli/parse.d.ts.map +1 -1
  7. package/dist/cli/parse.js +1 -1
  8. package/dist/cli/resolve.cjs +1 -5
  9. package/dist/cli/resolve.d.cts +1 -3
  10. package/dist/cli/resolve.d.cts.map +1 -1
  11. package/dist/cli/resolve.d.ts +1 -3
  12. package/dist/cli/resolve.d.ts.map +1 -1
  13. package/dist/cli/resolve.js +1 -5
  14. package/dist/cli/types.d.cts +1 -3
  15. package/dist/cli/types.d.ts +1 -3
  16. package/dist/cli/usage.cjs +1 -1
  17. package/dist/cli/usage.d.cts +2 -2
  18. package/dist/cli/usage.d.ts +2 -2
  19. package/dist/cli/usage.js +1 -1
  20. package/dist/config-Bs1p6XwV.js +3 -0
  21. package/dist/config-DFewJLVx.cjs +6 -0
  22. package/dist/{config-jAHLRqMZ.js → config-DtimzxvV-BItTrGiz.js} +3 -306
  23. package/dist/config-DtimzxvV-BItTrGiz.js.map +1 -0
  24. package/dist/{config-2JTOC4-d.cjs → config-DtimzxvV-D3ccpxhQ.cjs} +2 -311
  25. package/dist/config-DtimzxvV-D3ccpxhQ.cjs.map +1 -0
  26. package/dist/index.cjs +21352 -77
  27. package/dist/index.cjs.map +1 -1
  28. package/dist/index.js +21376 -69
  29. package/dist/index.js.map +1 -1
  30. package/dist/{parse-Br-BwKdT.cjs → parse-By6nDBNs.cjs} +2 -2
  31. package/dist/{parse-Br-BwKdT.cjs.map → parse-By6nDBNs.cjs.map} +1 -1
  32. package/dist/{parse-BvHK_nys.js → parse-Dn9XeQSj.js} +1 -1
  33. package/dist/{parse-BvHK_nys.js.map → parse-Dn9XeQSj.js.map} +1 -1
  34. package/dist/resolve-BCdS4js5.js +590 -0
  35. package/dist/resolve-BCdS4js5.js.map +1 -0
  36. package/dist/resolve-BMmRdCFJ.cjs +692 -0
  37. package/dist/resolve-BMmRdCFJ.cjs.map +1 -0
  38. package/dist/{stdio-2BaHF2h-.js → stdio-Cp-EJZB9.js} +7 -3
  39. package/dist/stdio-Cp-EJZB9.js.map +1 -0
  40. package/dist/{stdio-DL-ID7Q4.cjs → stdio-iRuX-anh.cjs} +20 -4
  41. package/dist/stdio-iRuX-anh.cjs.map +1 -0
  42. package/dist/transports/stdio.cjs +1 -2
  43. package/dist/transports/stdio.d.cts +1 -3
  44. package/dist/transports/stdio.d.cts.map +1 -1
  45. package/dist/transports/stdio.d.ts +1 -3
  46. package/dist/transports/stdio.d.ts.map +1 -1
  47. package/dist/transports/stdio.js +1 -2
  48. package/dist/{types-BeIzCAF1.d.cts → types-CM88pHH_.d.ts} +3 -3
  49. package/dist/{types-C70IdmF4.d.ts.map → types-CM88pHH_.d.ts.map} +1 -1
  50. package/dist/{types-C70IdmF4.d.ts → types-CnLRMjvf.d.cts} +3 -3
  51. package/dist/{types-BeIzCAF1.d.cts.map → types-CnLRMjvf.d.cts.map} +1 -1
  52. package/dist/{usage-CpguKuwi.js → usage-DMGbIpV-.js} +1 -1
  53. package/dist/usage-DMGbIpV-.js.map +1 -0
  54. package/dist/{usage-CMWaPhZv.cjs → usage-iwGZsu3a.cjs} +1 -1
  55. package/dist/usage-iwGZsu3a.cjs.map +1 -0
  56. package/package.json +20 -105
  57. package/README.md +0 -121
  58. package/dist/agent-9s0S2VUD.js +0 -43
  59. package/dist/agent-9s0S2VUD.js.map +0 -1
  60. package/dist/agent-BI-VWYjJ.d.ts +0 -93
  61. package/dist/agent-BI-VWYjJ.d.ts.map +0 -1
  62. package/dist/agent-Bm5Hsfal.d.cts +0 -32
  63. package/dist/agent-Bm5Hsfal.d.cts.map +0 -1
  64. package/dist/agent-BmPRmM9x.d.cts +0 -93
  65. package/dist/agent-BmPRmM9x.d.cts.map +0 -1
  66. package/dist/agent-BsCC60AU.js +0 -64
  67. package/dist/agent-BsCC60AU.js.map +0 -1
  68. package/dist/agent-CJ6SVqAB.d.ts +0 -32
  69. package/dist/agent-CJ6SVqAB.d.ts.map +0 -1
  70. package/dist/agent-CirZFiaJ.cjs +0 -55
  71. package/dist/agent-CirZFiaJ.cjs.map +0 -1
  72. package/dist/agent-CnHO6uyy.cjs +0 -76
  73. package/dist/agent-CnHO6uyy.cjs.map +0 -1
  74. package/dist/agent-D8Mz9ung.d.cts +0 -35
  75. package/dist/agent-D8Mz9ung.d.cts.map +0 -1
  76. package/dist/agent-DD0p64Dq.js +0 -29
  77. package/dist/agent-DD0p64Dq.js.map +0 -1
  78. package/dist/agent-DQdvMLcG.d.ts +0 -35
  79. package/dist/agent-DQdvMLcG.d.ts.map +0 -1
  80. package/dist/agent-DaUNg6Ut.cjs +0 -35
  81. package/dist/agent-DaUNg6Ut.cjs.map +0 -1
  82. package/dist/analyze-issue-with-seer-6OwT1RJP.js +0 -200
  83. package/dist/analyze-issue-with-seer-6OwT1RJP.js.map +0 -1
  84. package/dist/analyze-issue-with-seer-wsCEFdZs.cjs +0 -206
  85. package/dist/analyze-issue-with-seer-wsCEFdZs.cjs.map +0 -1
  86. package/dist/api-BCICbJoI.js +0 -63
  87. package/dist/api-BCICbJoI.js.map +0 -1
  88. package/dist/api-CfzBwheo.cjs +0 -80
  89. package/dist/api-CfzBwheo.cjs.map +0 -1
  90. package/dist/api-client/client.cjs +0 -9
  91. package/dist/api-client/client.d.cts +0 -4
  92. package/dist/api-client/client.d.ts +0 -4
  93. package/dist/api-client/client.js +0 -9
  94. package/dist/api-client/errors.cjs +0 -11
  95. package/dist/api-client/errors.d.cts +0 -2
  96. package/dist/api-client/errors.d.ts +0 -2
  97. package/dist/api-client/errors.js +0 -3
  98. package/dist/api-client/index.cjs +0 -70
  99. package/dist/api-client/index.d.cts +0 -6
  100. package/dist/api-client/index.d.ts +0 -6
  101. package/dist/api-client/index.js +0 -11
  102. package/dist/api-client/schema.cjs +0 -52
  103. package/dist/api-client/schema.d.cts +0 -2
  104. package/dist/api-client/schema.d.ts +0 -2
  105. package/dist/api-client/schema.js +0 -3
  106. package/dist/api-client/types.cjs +0 -1
  107. package/dist/api-client/types.d.cts +0 -3
  108. package/dist/api-client/types.d.ts +0 -3
  109. package/dist/api-client/types.js +0 -1
  110. package/dist/api-client-BGgaBFuD.cjs +0 -0
  111. package/dist/api-client-CSLxiNP9.js +0 -0
  112. package/dist/callEmbeddedAgent-BIfQ-_5T.d.ts +0 -34
  113. package/dist/callEmbeddedAgent-BIfQ-_5T.d.ts.map +0 -1
  114. package/dist/callEmbeddedAgent-CFHLQjFx.d.cts +0 -34
  115. package/dist/callEmbeddedAgent-CFHLQjFx.d.cts.map +0 -1
  116. package/dist/callEmbeddedAgent-COB8Jrcn.cjs +0 -51
  117. package/dist/callEmbeddedAgent-COB8Jrcn.cjs.map +0 -1
  118. package/dist/callEmbeddedAgent-rEUWAl2g.js +0 -45
  119. package/dist/callEmbeddedAgent-rEUWAl2g.js.map +0 -1
  120. package/dist/client-8_aKE-B-.d.cts +0 -844
  121. package/dist/client-8_aKE-B-.d.cts.map +0 -1
  122. package/dist/client-BGVY6gBL.d.ts +0 -844
  123. package/dist/client-BGVY6gBL.d.ts.map +0 -1
  124. package/dist/client-Be1DR1al.js +0 -1098
  125. package/dist/client-Be1DR1al.js.map +0 -1
  126. package/dist/client-DSxCsnqO.cjs +0 -1103
  127. package/dist/client-DSxCsnqO.cjs.map +0 -1
  128. package/dist/config-2JTOC4-d.cjs.map +0 -1
  129. package/dist/config-BFaJp4hW.js +0 -74
  130. package/dist/config-BFaJp4hW.js.map +0 -1
  131. package/dist/config-BMLvvgGQ.cjs +0 -37
  132. package/dist/config-BMLvvgGQ.cjs.map +0 -1
  133. package/dist/config-BacDkkdz.cjs +0 -80
  134. package/dist/config-BacDkkdz.cjs.map +0 -1
  135. package/dist/config-Dh25cVhL.js +0 -25
  136. package/dist/config-Dh25cVhL.js.map +0 -1
  137. package/dist/config-jAHLRqMZ.js.map +0 -1
  138. package/dist/constants-CgLLujFn.cjs +0 -220
  139. package/dist/constants-CgLLujFn.cjs.map +0 -1
  140. package/dist/constants-D8axTonA.js +0 -184
  141. package/dist/constants-D8axTonA.js.map +0 -1
  142. package/dist/constants.cjs +0 -10
  143. package/dist/constants.d.cts +0 -36
  144. package/dist/constants.d.cts.map +0 -1
  145. package/dist/constants.d.ts +0 -36
  146. package/dist/constants.d.ts.map +0 -1
  147. package/dist/constants.js +0 -4
  148. package/dist/constraint-helpers-CBddlAo8.js +0 -64
  149. package/dist/constraint-helpers-CBddlAo8.js.map +0 -1
  150. package/dist/constraint-helpers-UEovDW_M.cjs +0 -76
  151. package/dist/constraint-helpers-UEovDW_M.cjs.map +0 -1
  152. package/dist/create-dsn-C5vd9Btg.cjs +0 -74
  153. package/dist/create-dsn-C5vd9Btg.cjs.map +0 -1
  154. package/dist/create-dsn-DBqCDM_6.js +0 -68
  155. package/dist/create-dsn-DBqCDM_6.js.map +0 -1
  156. package/dist/create-project-BsN4Q0cl.js +0 -86
  157. package/dist/create-project-BsN4Q0cl.js.map +0 -1
  158. package/dist/create-project-D4W66CxU.cjs +0 -92
  159. package/dist/create-project-D4W66CxU.cjs.map +0 -1
  160. package/dist/create-team-DUBAEGGr.js +0 -63
  161. package/dist/create-team-DUBAEGGr.js.map +0 -1
  162. package/dist/create-team-DV6XmZkb.cjs +0 -69
  163. package/dist/create-team-DV6XmZkb.cjs.map +0 -1
  164. package/dist/dataset-fields-Bp_g-sD6.cjs +0 -179
  165. package/dist/dataset-fields-Bp_g-sD6.cjs.map +0 -1
  166. package/dist/dataset-fields-dZ43jEgF.js +0 -155
  167. package/dist/dataset-fields-dZ43jEgF.js.map +0 -1
  168. package/dist/define-CLp6EtpZ.cjs +0 -14
  169. package/dist/define-CLp6EtpZ.cjs.map +0 -1
  170. package/dist/define-vA6uuVue.js +0 -8
  171. package/dist/define-vA6uuVue.js.map +0 -1
  172. package/dist/enhance-error-BULHg3Tl.js +0 -32
  173. package/dist/enhance-error-BULHg3Tl.js.map +0 -1
  174. package/dist/enhance-error-vihkdCX5.cjs +0 -37
  175. package/dist/enhance-error-vihkdCX5.cjs.map +0 -1
  176. package/dist/error-handling-CLnyY1TR.js +0 -97
  177. package/dist/error-handling-CLnyY1TR.js.map +0 -1
  178. package/dist/error-handling-FGjcJT8U.cjs +0 -132
  179. package/dist/error-handling-FGjcJT8U.cjs.map +0 -1
  180. package/dist/errors-BXmNwD2K.js +0 -26
  181. package/dist/errors-BXmNwD2K.js.map +0 -1
  182. package/dist/errors-BYClKbv4.d.cts +0 -20
  183. package/dist/errors-BYClKbv4.d.cts.map +0 -1
  184. package/dist/errors-Cn4l-BlC.d.ts +0 -20
  185. package/dist/errors-Cn4l-BlC.d.ts.map +0 -1
  186. package/dist/errors-CyAWBU2S.d.ts +0 -126
  187. package/dist/errors-CyAWBU2S.d.ts.map +0 -1
  188. package/dist/errors-DMiENfq7.d.cts +0 -126
  189. package/dist/errors-DMiENfq7.d.cts.map +0 -1
  190. package/dist/errors-DUEMWOr1.js +0 -217
  191. package/dist/errors-DUEMWOr1.js.map +0 -1
  192. package/dist/errors-DWysOIMw.cjs +0 -271
  193. package/dist/errors-DWysOIMw.cjs.map +0 -1
  194. package/dist/errors-umQzF_vW.cjs +0 -38
  195. package/dist/errors-umQzF_vW.cjs.map +0 -1
  196. package/dist/errors.cjs +0 -4
  197. package/dist/errors.d.cts +0 -2
  198. package/dist/errors.d.ts +0 -2
  199. package/dist/errors.js +0 -3
  200. package/dist/fetch-utils-C6qSgZai.js +0 -52
  201. package/dist/fetch-utils-C6qSgZai.js.map +0 -1
  202. package/dist/fetch-utils-DRgOJp3e.cjs +0 -64
  203. package/dist/fetch-utils-DRgOJp3e.cjs.map +0 -1
  204. package/dist/find-dsns-BabAfVEt.cjs +0 -64
  205. package/dist/find-dsns-BabAfVEt.cjs.map +0 -1
  206. package/dist/find-dsns-C-Q6yJT5.js +0 -58
  207. package/dist/find-dsns-C-Q6yJT5.js.map +0 -1
  208. package/dist/find-organizations-Bo-JdU-R.js +0 -59
  209. package/dist/find-organizations-Bo-JdU-R.js.map +0 -1
  210. package/dist/find-organizations-CEEqa1an.cjs +0 -64
  211. package/dist/find-organizations-CEEqa1an.cjs.map +0 -1
  212. package/dist/find-projects-BWyvosHM.cjs +0 -59
  213. package/dist/find-projects-BWyvosHM.cjs.map +0 -1
  214. package/dist/find-projects-zM4CM_xX.js +0 -53
  215. package/dist/find-projects-zM4CM_xX.js.map +0 -1
  216. package/dist/find-releases-DMJrj5wz.cjs +0 -105
  217. package/dist/find-releases-DMJrj5wz.cjs.map +0 -1
  218. package/dist/find-releases-DzdGLPSN.js +0 -99
  219. package/dist/find-releases-DzdGLPSN.js.map +0 -1
  220. package/dist/find-teams-CR_hdlun.js +0 -56
  221. package/dist/find-teams-CR_hdlun.js.map +0 -1
  222. package/dist/find-teams-lOqS_719.cjs +0 -62
  223. package/dist/find-teams-lOqS_719.cjs.map +0 -1
  224. package/dist/formatters-B6H5qTFe.cjs +0 -98
  225. package/dist/formatters-B6H5qTFe.cjs.map +0 -1
  226. package/dist/formatters-BOJNlDKG.js +0 -223
  227. package/dist/formatters-BOJNlDKG.js.map +0 -1
  228. package/dist/formatters-C9MhdNDX.js +0 -86
  229. package/dist/formatters-C9MhdNDX.js.map +0 -1
  230. package/dist/formatters-ObdzRwld.cjs +0 -247
  231. package/dist/formatters-ObdzRwld.cjs.map +0 -1
  232. package/dist/formatting-BatGC-29.cjs +0 -984
  233. package/dist/formatting-BatGC-29.cjs.map +0 -1
  234. package/dist/formatting-Bm1GxhEu.d.ts +0 -54
  235. package/dist/formatting-Bm1GxhEu.d.ts.map +0 -1
  236. package/dist/formatting-C6hyL-Yv.cjs +0 -20
  237. package/dist/formatting-C6hyL-Yv.cjs.map +0 -1
  238. package/dist/formatting-DJFcfTJG.js +0 -14
  239. package/dist/formatting-DJFcfTJG.js.map +0 -1
  240. package/dist/formatting-DUODx6N5.js +0 -967
  241. package/dist/formatting-DUODx6N5.js.map +0 -1
  242. package/dist/formatting-GZdM57wq.d.cts +0 -54
  243. package/dist/formatting-GZdM57wq.d.cts.map +0 -1
  244. package/dist/get-doc-CbVw4ada.cjs +0 -93
  245. package/dist/get-doc-CbVw4ada.cjs.map +0 -1
  246. package/dist/get-doc-FuILofQP.js +0 -87
  247. package/dist/get-doc-FuILofQP.js.map +0 -1
  248. package/dist/get-event-attachment-DuyBT68p.cjs +0 -150
  249. package/dist/get-event-attachment-DuyBT68p.cjs.map +0 -1
  250. package/dist/get-event-attachment-Dzg2R7ng.js +0 -144
  251. package/dist/get-event-attachment-Dzg2R7ng.js.map +0 -1
  252. package/dist/get-issue-details-BY7S1YyX.cjs +0 -201
  253. package/dist/get-issue-details-BY7S1YyX.cjs.map +0 -1
  254. package/dist/get-issue-details-BxJzOzFQ.js +0 -195
  255. package/dist/get-issue-details-BxJzOzFQ.js.map +0 -1
  256. package/dist/get-trace-details-DD0p3apU.cjs +0 -313
  257. package/dist/get-trace-details-DD0p3apU.cjs.map +0 -1
  258. package/dist/get-trace-details-Dv2FB534.js +0 -307
  259. package/dist/get-trace-details-Dv2FB534.js.map +0 -1
  260. package/dist/handler-0iIvlYwy.d.cts +0 -11
  261. package/dist/handler-0iIvlYwy.d.cts.map +0 -1
  262. package/dist/handler-8JzODzam.d.cts +0 -15
  263. package/dist/handler-8JzODzam.d.cts.map +0 -1
  264. package/dist/handler-9UUkphzv.d.ts +0 -15
  265. package/dist/handler-9UUkphzv.d.ts.map +0 -1
  266. package/dist/handler-BfTAwyrq.js +0 -153
  267. package/dist/handler-BfTAwyrq.js.map +0 -1
  268. package/dist/handler-BhjeSo2N.js +0 -132
  269. package/dist/handler-BhjeSo2N.js.map +0 -1
  270. package/dist/handler-BjTPOR8v.cjs +0 -138
  271. package/dist/handler-BjTPOR8v.cjs.map +0 -1
  272. package/dist/handler-C5Tgh1wj.cjs +0 -159
  273. package/dist/handler-C5Tgh1wj.cjs.map +0 -1
  274. package/dist/handler-ClZBIn0B.d.cts +0 -15
  275. package/dist/handler-ClZBIn0B.d.cts.map +0 -1
  276. package/dist/handler-CmAbLcaV.d.ts +0 -15
  277. package/dist/handler-CmAbLcaV.d.ts.map +0 -1
  278. package/dist/handler-DbUy8Z54.d.ts +0 -11
  279. package/dist/handler-DbUy8Z54.d.ts.map +0 -1
  280. package/dist/index-CmCelmEL.d.cts +0 -1
  281. package/dist/index-NfFbnYt3.d.ts +0 -1
  282. package/dist/internal/agents/callEmbeddedAgent.cjs +0 -6
  283. package/dist/internal/agents/callEmbeddedAgent.d.cts +0 -2
  284. package/dist/internal/agents/callEmbeddedAgent.d.ts +0 -2
  285. package/dist/internal/agents/callEmbeddedAgent.js +0 -6
  286. package/dist/internal/agents/openai-provider.cjs +0 -5
  287. package/dist/internal/agents/openai-provider.d.cts +0 -22
  288. package/dist/internal/agents/openai-provider.d.cts.map +0 -1
  289. package/dist/internal/agents/openai-provider.d.ts +0 -22
  290. package/dist/internal/agents/openai-provider.d.ts.map +0 -1
  291. package/dist/internal/agents/openai-provider.js +0 -4
  292. package/dist/internal/agents/tools/dataset-fields.cjs +0 -16
  293. package/dist/internal/agents/tools/dataset-fields.d.cts +0 -58
  294. package/dist/internal/agents/tools/dataset-fields.d.cts.map +0 -1
  295. package/dist/internal/agents/tools/dataset-fields.d.ts +0 -58
  296. package/dist/internal/agents/tools/dataset-fields.d.ts.map +0 -1
  297. package/dist/internal/agents/tools/dataset-fields.js +0 -13
  298. package/dist/internal/agents/tools/otel-semantics.cjs +0 -14
  299. package/dist/internal/agents/tools/otel-semantics.d.cts +0 -41
  300. package/dist/internal/agents/tools/otel-semantics.d.cts.map +0 -1
  301. package/dist/internal/agents/tools/otel-semantics.d.ts +0 -41
  302. package/dist/internal/agents/tools/otel-semantics.d.ts.map +0 -1
  303. package/dist/internal/agents/tools/otel-semantics.js +0 -13
  304. package/dist/internal/agents/tools/utils.cjs +0 -12
  305. package/dist/internal/agents/tools/utils.d.cts +0 -2
  306. package/dist/internal/agents/tools/utils.d.ts +0 -2
  307. package/dist/internal/agents/tools/utils.js +0 -12
  308. package/dist/internal/agents/tools/whoami.cjs +0 -14
  309. package/dist/internal/agents/tools/whoami.d.cts +0 -33
  310. package/dist/internal/agents/tools/whoami.d.cts.map +0 -1
  311. package/dist/internal/agents/tools/whoami.d.ts +0 -33
  312. package/dist/internal/agents/tools/whoami.d.ts.map +0 -1
  313. package/dist/internal/agents/tools/whoami.js +0 -13
  314. package/dist/internal/constraint-helpers.cjs +0 -4
  315. package/dist/internal/constraint-helpers.d.cts +0 -54
  316. package/dist/internal/constraint-helpers.d.cts.map +0 -1
  317. package/dist/internal/constraint-helpers.d.ts +0 -54
  318. package/dist/internal/constraint-helpers.d.ts.map +0 -1
  319. package/dist/internal/constraint-helpers.js +0 -3
  320. package/dist/internal/error-handling.cjs +0 -17
  321. package/dist/internal/error-handling.d.cts +0 -40
  322. package/dist/internal/error-handling.d.cts.map +0 -1
  323. package/dist/internal/error-handling.d.ts +0 -40
  324. package/dist/internal/error-handling.d.ts.map +0 -1
  325. package/dist/internal/error-handling.js +0 -12
  326. package/dist/internal/fetch-utils.cjs +0 -4
  327. package/dist/internal/fetch-utils.d.cts +0 -33
  328. package/dist/internal/fetch-utils.d.cts.map +0 -1
  329. package/dist/internal/fetch-utils.d.ts +0 -33
  330. package/dist/internal/fetch-utils.d.ts.map +0 -1
  331. package/dist/internal/fetch-utils.js +0 -3
  332. package/dist/internal/formatting.cjs +0 -7
  333. package/dist/internal/formatting.d.cts +0 -7
  334. package/dist/internal/formatting.d.ts +0 -7
  335. package/dist/internal/formatting.js +0 -5
  336. package/dist/internal/issue-helpers.cjs +0 -6
  337. package/dist/internal/issue-helpers.d.cts +0 -2
  338. package/dist/internal/issue-helpers.d.ts +0 -2
  339. package/dist/internal/issue-helpers.js +0 -4
  340. package/dist/internal/test-fixtures.cjs +0 -224
  341. package/dist/internal/test-fixtures.cjs.map +0 -1
  342. package/dist/internal/test-fixtures.d.cts +0 -130
  343. package/dist/internal/test-fixtures.d.cts.map +0 -1
  344. package/dist/internal/test-fixtures.d.ts +0 -130
  345. package/dist/internal/test-fixtures.d.ts.map +0 -1
  346. package/dist/internal/test-fixtures.js +0 -215
  347. package/dist/internal/test-fixtures.js.map +0 -1
  348. package/dist/internal/tool-helpers/api.cjs +0 -17
  349. package/dist/internal/tool-helpers/api.d.cts +0 -42
  350. package/dist/internal/tool-helpers/api.d.cts.map +0 -1
  351. package/dist/internal/tool-helpers/api.d.ts +0 -42
  352. package/dist/internal/tool-helpers/api.d.ts.map +0 -1
  353. package/dist/internal/tool-helpers/api.js +0 -15
  354. package/dist/internal/tool-helpers/define.cjs +0 -3
  355. package/dist/internal/tool-helpers/define.d.cts +0 -13
  356. package/dist/internal/tool-helpers/define.d.cts.map +0 -1
  357. package/dist/internal/tool-helpers/define.d.ts +0 -13
  358. package/dist/internal/tool-helpers/define.d.ts.map +0 -1
  359. package/dist/internal/tool-helpers/define.js +0 -3
  360. package/dist/internal/tool-helpers/enhance-error.cjs +0 -12
  361. package/dist/internal/tool-helpers/enhance-error.d.cts +0 -29
  362. package/dist/internal/tool-helpers/enhance-error.d.cts.map +0 -1
  363. package/dist/internal/tool-helpers/enhance-error.d.ts +0 -29
  364. package/dist/internal/tool-helpers/enhance-error.d.ts.map +0 -1
  365. package/dist/internal/tool-helpers/enhance-error.js +0 -12
  366. package/dist/internal/tool-helpers/formatting.cjs +0 -3
  367. package/dist/internal/tool-helpers/formatting.d.cts +0 -16
  368. package/dist/internal/tool-helpers/formatting.d.cts.map +0 -1
  369. package/dist/internal/tool-helpers/formatting.d.ts +0 -16
  370. package/dist/internal/tool-helpers/formatting.d.ts.map +0 -1
  371. package/dist/internal/tool-helpers/formatting.js +0 -3
  372. package/dist/internal/tool-helpers/issue.cjs +0 -9
  373. package/dist/internal/tool-helpers/issue.d.cts +0 -8
  374. package/dist/internal/tool-helpers/issue.d.ts +0 -8
  375. package/dist/internal/tool-helpers/issue.js +0 -8
  376. package/dist/internal/tool-helpers/seer.cjs +0 -11
  377. package/dist/internal/tool-helpers/seer.d.cts +0 -31
  378. package/dist/internal/tool-helpers/seer.d.cts.map +0 -1
  379. package/dist/internal/tool-helpers/seer.d.ts +0 -31
  380. package/dist/internal/tool-helpers/seer.d.ts.map +0 -1
  381. package/dist/internal/tool-helpers/seer.js +0 -3
  382. package/dist/internal/tool-helpers/validate-region-url.cjs +0 -6
  383. package/dist/internal/tool-helpers/validate-region-url.d.cts +0 -20
  384. package/dist/internal/tool-helpers/validate-region-url.d.cts.map +0 -1
  385. package/dist/internal/tool-helpers/validate-region-url.d.ts +0 -20
  386. package/dist/internal/tool-helpers/validate-region-url.d.ts.map +0 -1
  387. package/dist/internal/tool-helpers/validate-region-url.js +0 -6
  388. package/dist/issue-1C6txnk3.js +0 -0
  389. package/dist/issue-ChNk4cuO.cjs +0 -0
  390. package/dist/issue-helpers-D-hBnXTk.cjs +0 -97
  391. package/dist/issue-helpers-D-hBnXTk.cjs.map +0 -1
  392. package/dist/issue-helpers-D4NRLqkR.d.ts +0 -52
  393. package/dist/issue-helpers-D4NRLqkR.d.ts.map +0 -1
  394. package/dist/issue-helpers-DtCbXiRZ.js +0 -80
  395. package/dist/issue-helpers-DtCbXiRZ.js.map +0 -1
  396. package/dist/issue-helpers-ILmSPsJZ.d.cts +0 -52
  397. package/dist/issue-helpers-ILmSPsJZ.d.cts.map +0 -1
  398. package/dist/logging-BgTqJ4mI.d.ts +0 -31
  399. package/dist/logging-BgTqJ4mI.d.ts.map +0 -1
  400. package/dist/logging-BjKioF_x.d.cts +0 -31
  401. package/dist/logging-BjKioF_x.d.cts.map +0 -1
  402. package/dist/logging-C-ST7-Ow.cjs +0 -298
  403. package/dist/logging-C-ST7-Ow.cjs.map +0 -1
  404. package/dist/logging-ChQnSEmD.js +0 -256
  405. package/dist/logging-ChQnSEmD.js.map +0 -1
  406. package/dist/openai-provider-BsMAb6zY.js +0 -48
  407. package/dist/openai-provider-BsMAb6zY.js.map +0 -1
  408. package/dist/openai-provider-BycgrQgi.cjs +0 -60
  409. package/dist/openai-provider-BycgrQgi.cjs.map +0 -1
  410. package/dist/otel-semantics-CWWWmiNy.js +0 -5070
  411. package/dist/otel-semantics-CWWWmiNy.js.map +0 -1
  412. package/dist/otel-semantics-n8_5Ib9C.cjs +0 -5082
  413. package/dist/otel-semantics-n8_5Ib9C.cjs.map +0 -1
  414. package/dist/permissions-Berbg2vC.cjs +0 -209
  415. package/dist/permissions-Berbg2vC.cjs.map +0 -1
  416. package/dist/permissions-CiIVEs4_.d.ts +0 -79
  417. package/dist/permissions-CiIVEs4_.d.ts.map +0 -1
  418. package/dist/permissions-Cm5e34n2.d.cts +0 -79
  419. package/dist/permissions-Cm5e34n2.d.cts.map +0 -1
  420. package/dist/permissions-DvkVlUJ1.js +0 -155
  421. package/dist/permissions-DvkVlUJ1.js.map +0 -1
  422. package/dist/permissions.cjs +0 -11
  423. package/dist/permissions.d.cts +0 -2
  424. package/dist/permissions.d.ts +0 -2
  425. package/dist/permissions.js +0 -3
  426. package/dist/resolve-CrYQ5aF_.cjs +0 -107
  427. package/dist/resolve-CrYQ5aF_.cjs.map +0 -1
  428. package/dist/resolve-DQ-6eLec.js +0 -90
  429. package/dist/resolve-DQ-6eLec.js.map +0 -1
  430. package/dist/schema-1xQ4asuW.cjs +0 -801
  431. package/dist/schema-1xQ4asuW.cjs.map +0 -1
  432. package/dist/schema-BGVOjcD7.cjs +0 -141
  433. package/dist/schema-BGVOjcD7.cjs.map +0 -1
  434. package/dist/schema-CZXkkfj-.d.cts +0 -16950
  435. package/dist/schema-CZXkkfj-.d.cts.map +0 -1
  436. package/dist/schema-Cfvy5rTy.d.ts +0 -16950
  437. package/dist/schema-Cfvy5rTy.d.ts.map +0 -1
  438. package/dist/schema-ChlpIaqA.js +0 -39
  439. package/dist/schema-ChlpIaqA.js.map +0 -1
  440. package/dist/schema-oeFNxyo_.js +0 -501
  441. package/dist/schema-oeFNxyo_.js.map +0 -1
  442. package/dist/schema.cjs +0 -22
  443. package/dist/schema.d.cts +0 -34
  444. package/dist/schema.d.cts.map +0 -1
  445. package/dist/schema.d.ts +0 -34
  446. package/dist/schema.d.ts.map +0 -1
  447. package/dist/schema.js +0 -6
  448. package/dist/search-docs-C5x-ZRhd.cjs +0 -97
  449. package/dist/search-docs-C5x-ZRhd.cjs.map +0 -1
  450. package/dist/search-docs-UCe9oXQt.js +0 -91
  451. package/dist/search-docs-UCe9oXQt.js.map +0 -1
  452. package/dist/search-events-B-MXKSB_.js +0 -0
  453. package/dist/search-events-BrEw3wC-.cjs +0 -0
  454. package/dist/search-issues-C7Zs6rFB.cjs +0 -0
  455. package/dist/search-issues-DUSkomYp.js +0 -0
  456. package/dist/seer-CSFgx4AP.js +0 -89
  457. package/dist/seer-CSFgx4AP.js.map +0 -1
  458. package/dist/seer-sA1asAZs.cjs +0 -143
  459. package/dist/seer-sA1asAZs.cjs.map +0 -1
  460. package/dist/sentry-3DC3Kob2.cjs +0 -110
  461. package/dist/sentry-3DC3Kob2.cjs.map +0 -1
  462. package/dist/sentry-CfePWwtE.d.cts +0 -9
  463. package/dist/sentry-CfePWwtE.d.cts.map +0 -1
  464. package/dist/sentry-Cfj4OGMQ.js +0 -104
  465. package/dist/sentry-Cfj4OGMQ.js.map +0 -1
  466. package/dist/sentry-DKiJwGZX.d.ts +0 -9
  467. package/dist/sentry-DKiJwGZX.d.ts.map +0 -1
  468. package/dist/server-BbJwtfJr.js +0 -336
  469. package/dist/server-BbJwtfJr.js.map +0 -1
  470. package/dist/server-OW--pQOQ.cjs +0 -354
  471. package/dist/server-OW--pQOQ.cjs.map +0 -1
  472. package/dist/server.cjs +0 -65
  473. package/dist/server.d.cts +0 -59
  474. package/dist/server.d.cts.map +0 -1
  475. package/dist/server.d.ts +0 -59
  476. package/dist/server.d.ts.map +0 -1
  477. package/dist/server.js +0 -65
  478. package/dist/skillDefinitions.cjs +0 -258
  479. package/dist/skillDefinitions.cjs.map +0 -1
  480. package/dist/skillDefinitions.d.cts +0 -18
  481. package/dist/skillDefinitions.d.cts.map +0 -1
  482. package/dist/skillDefinitions.d.ts +0 -18
  483. package/dist/skillDefinitions.d.ts.map +0 -1
  484. package/dist/skillDefinitions.js +0 -257
  485. package/dist/skillDefinitions.js.map +0 -1
  486. package/dist/skills-BmFl7P6V.js +0 -94
  487. package/dist/skills-BmFl7P6V.js.map +0 -1
  488. package/dist/skills-COOuBrrA.cjs +0 -148
  489. package/dist/skills-COOuBrrA.cjs.map +0 -1
  490. package/dist/skills-HlAeBq_E.d.cts +0 -33
  491. package/dist/skills-HlAeBq_E.d.cts.map +0 -1
  492. package/dist/skills-g0WCenTA.d.ts +0 -33
  493. package/dist/skills-g0WCenTA.d.ts.map +0 -1
  494. package/dist/skills.cjs +0 -11
  495. package/dist/skills.d.cts +0 -2
  496. package/dist/skills.d.ts +0 -2
  497. package/dist/skills.js +0 -3
  498. package/dist/slug-validation-Bkteg65O.js +0 -93
  499. package/dist/slug-validation-Bkteg65O.js.map +0 -1
  500. package/dist/slug-validation-D5VJqMwH.cjs +0 -111
  501. package/dist/slug-validation-D5VJqMwH.cjs.map +0 -1
  502. package/dist/stdio-2BaHF2h-.js.map +0 -1
  503. package/dist/stdio-DL-ID7Q4.cjs.map +0 -1
  504. package/dist/telem/index.cjs +0 -10
  505. package/dist/telem/index.d.cts +0 -3
  506. package/dist/telem/index.d.ts +0 -3
  507. package/dist/telem/index.js +0 -4
  508. package/dist/telem/logging.cjs +0 -9
  509. package/dist/telem/logging.d.cts +0 -2
  510. package/dist/telem/logging.d.ts +0 -2
  511. package/dist/telem/logging.js +0 -3
  512. package/dist/telem/sentry.cjs +0 -3
  513. package/dist/telem/sentry.d.cts +0 -2
  514. package/dist/telem/sentry.d.ts +0 -2
  515. package/dist/telem/sentry.js +0 -3
  516. package/dist/test-setup.cjs +0 -56
  517. package/dist/test-setup.cjs.map +0 -1
  518. package/dist/test-setup.d.cts +0 -33
  519. package/dist/test-setup.d.cts.map +0 -1
  520. package/dist/test-setup.d.ts +0 -33
  521. package/dist/test-setup.d.ts.map +0 -1
  522. package/dist/test-setup.js +0 -55
  523. package/dist/test-setup.js.map +0 -1
  524. package/dist/test-utils/context.cjs +0 -32
  525. package/dist/test-utils/context.cjs.map +0 -1
  526. package/dist/test-utils/context.d.cts +0 -18
  527. package/dist/test-utils/context.d.cts.map +0 -1
  528. package/dist/test-utils/context.d.ts +0 -18
  529. package/dist/test-utils/context.d.ts.map +0 -1
  530. package/dist/test-utils/context.js +0 -30
  531. package/dist/test-utils/context.js.map +0 -1
  532. package/dist/toolDefinitions.cjs +0 -838
  533. package/dist/toolDefinitions.cjs.map +0 -1
  534. package/dist/toolDefinitions.d.cts +0 -13
  535. package/dist/toolDefinitions.d.cts.map +0 -1
  536. package/dist/toolDefinitions.d.ts +0 -13
  537. package/dist/toolDefinitions.d.ts.map +0 -1
  538. package/dist/toolDefinitions.js +0 -837
  539. package/dist/toolDefinitions.js.map +0 -1
  540. package/dist/tools/analyze-issue-with-seer.cjs +0 -24
  541. package/dist/tools/analyze-issue-with-seer.d.cts +0 -17
  542. package/dist/tools/analyze-issue-with-seer.d.cts.map +0 -1
  543. package/dist/tools/analyze-issue-with-seer.d.ts +0 -17
  544. package/dist/tools/analyze-issue-with-seer.d.ts.map +0 -1
  545. package/dist/tools/analyze-issue-with-seer.js +0 -24
  546. package/dist/tools/create-dsn.cjs +0 -19
  547. package/dist/tools/create-dsn.d.cts +0 -16
  548. package/dist/tools/create-dsn.d.cts.map +0 -1
  549. package/dist/tools/create-dsn.d.ts +0 -16
  550. package/dist/tools/create-dsn.d.ts.map +0 -1
  551. package/dist/tools/create-dsn.js +0 -19
  552. package/dist/tools/create-project.cjs +0 -19
  553. package/dist/tools/create-project.d.cts +0 -17
  554. package/dist/tools/create-project.d.cts.map +0 -1
  555. package/dist/tools/create-project.d.ts +0 -17
  556. package/dist/tools/create-project.d.ts.map +0 -1
  557. package/dist/tools/create-project.js +0 -19
  558. package/dist/tools/create-team.cjs +0 -19
  559. package/dist/tools/create-team.d.cts +0 -15
  560. package/dist/tools/create-team.d.cts.map +0 -1
  561. package/dist/tools/create-team.d.ts +0 -15
  562. package/dist/tools/create-team.d.ts.map +0 -1
  563. package/dist/tools/create-team.js +0 -19
  564. package/dist/tools/find-dsns.cjs +0 -19
  565. package/dist/tools/find-dsns.d.cts +0 -15
  566. package/dist/tools/find-dsns.d.cts.map +0 -1
  567. package/dist/tools/find-dsns.d.ts +0 -15
  568. package/dist/tools/find-dsns.d.ts.map +0 -1
  569. package/dist/tools/find-dsns.js +0 -19
  570. package/dist/tools/find-organizations.cjs +0 -19
  571. package/dist/tools/find-organizations.d.cts +0 -13
  572. package/dist/tools/find-organizations.d.cts.map +0 -1
  573. package/dist/tools/find-organizations.d.ts +0 -13
  574. package/dist/tools/find-organizations.d.ts.map +0 -1
  575. package/dist/tools/find-organizations.js +0 -19
  576. package/dist/tools/find-projects.cjs +0 -19
  577. package/dist/tools/find-projects.d.cts +0 -15
  578. package/dist/tools/find-projects.d.cts.map +0 -1
  579. package/dist/tools/find-projects.d.ts +0 -15
  580. package/dist/tools/find-projects.d.ts.map +0 -1
  581. package/dist/tools/find-projects.js +0 -19
  582. package/dist/tools/find-releases.cjs +0 -19
  583. package/dist/tools/find-releases.d.cts +0 -16
  584. package/dist/tools/find-releases.d.cts.map +0 -1
  585. package/dist/tools/find-releases.d.ts +0 -16
  586. package/dist/tools/find-releases.d.ts.map +0 -1
  587. package/dist/tools/find-releases.js +0 -19
  588. package/dist/tools/find-teams.cjs +0 -19
  589. package/dist/tools/find-teams.d.cts +0 -15
  590. package/dist/tools/find-teams.d.cts.map +0 -1
  591. package/dist/tools/find-teams.d.ts +0 -15
  592. package/dist/tools/find-teams.d.ts.map +0 -1
  593. package/dist/tools/find-teams.js +0 -19
  594. package/dist/tools/get-doc.cjs +0 -14
  595. package/dist/tools/get-doc.d.cts +0 -13
  596. package/dist/tools/get-doc.d.cts.map +0 -1
  597. package/dist/tools/get-doc.d.ts +0 -13
  598. package/dist/tools/get-doc.d.ts.map +0 -1
  599. package/dist/tools/get-doc.js +0 -14
  600. package/dist/tools/get-event-attachment.cjs +0 -19
  601. package/dist/tools/get-event-attachment.d.cts +0 -17
  602. package/dist/tools/get-event-attachment.d.cts.map +0 -1
  603. package/dist/tools/get-event-attachment.d.ts +0 -17
  604. package/dist/tools/get-event-attachment.d.ts.map +0 -1
  605. package/dist/tools/get-event-attachment.js +0 -19
  606. package/dist/tools/get-issue-details.cjs +0 -24
  607. package/dist/tools/get-issue-details.d.cts +0 -17
  608. package/dist/tools/get-issue-details.d.cts.map +0 -1
  609. package/dist/tools/get-issue-details.d.ts +0 -17
  610. package/dist/tools/get-issue-details.d.ts.map +0 -1
  611. package/dist/tools/get-issue-details.js +0 -24
  612. package/dist/tools/get-trace-details.cjs +0 -19
  613. package/dist/tools/get-trace-details.d.cts +0 -15
  614. package/dist/tools/get-trace-details.d.cts.map +0 -1
  615. package/dist/tools/get-trace-details.d.ts +0 -15
  616. package/dist/tools/get-trace-details.d.ts.map +0 -1
  617. package/dist/tools/get-trace-details.js +0 -19
  618. package/dist/tools/index.cjs +0 -65
  619. package/dist/tools/index.d.cts +0 -129
  620. package/dist/tools/index.d.cts.map +0 -1
  621. package/dist/tools/index.d.ts +0 -129
  622. package/dist/tools/index.d.ts.map +0 -1
  623. package/dist/tools/index.js +0 -65
  624. package/dist/tools/search-docs.cjs +0 -18
  625. package/dist/tools/search-docs.d.cts +0 -15
  626. package/dist/tools/search-docs.d.cts.map +0 -1
  627. package/dist/tools/search-docs.d.ts +0 -15
  628. package/dist/tools/search-docs.d.ts.map +0 -1
  629. package/dist/tools/search-docs.js +0 -18
  630. package/dist/tools/search-events/agent.cjs +0 -20
  631. package/dist/tools/search-events/agent.d.cts +0 -7
  632. package/dist/tools/search-events/agent.d.ts +0 -7
  633. package/dist/tools/search-events/agent.js +0 -19
  634. package/dist/tools/search-events/config.cjs +0 -8
  635. package/dist/tools/search-events/config.d.cts +0 -132
  636. package/dist/tools/search-events/config.d.cts.map +0 -1
  637. package/dist/tools/search-events/config.d.ts +0 -132
  638. package/dist/tools/search-events/config.d.ts.map +0 -1
  639. package/dist/tools/search-events/config.js +0 -3
  640. package/dist/tools/search-events/formatters.cjs +0 -17
  641. package/dist/tools/search-events/formatters.d.cts +0 -43
  642. package/dist/tools/search-events/formatters.d.cts.map +0 -1
  643. package/dist/tools/search-events/formatters.d.ts +0 -43
  644. package/dist/tools/search-events/formatters.d.ts.map +0 -1
  645. package/dist/tools/search-events/formatters.js +0 -14
  646. package/dist/tools/search-events/handler.cjs +0 -28
  647. package/dist/tools/search-events/handler.d.cts +0 -6
  648. package/dist/tools/search-events/handler.d.ts +0 -6
  649. package/dist/tools/search-events/handler.js +0 -28
  650. package/dist/tools/search-events/index.cjs +0 -31
  651. package/dist/tools/search-events/index.d.cts +0 -12
  652. package/dist/tools/search-events/index.d.ts +0 -12
  653. package/dist/tools/search-events/index.js +0 -29
  654. package/dist/tools/search-events/utils.cjs +0 -17
  655. package/dist/tools/search-events/utils.d.cts +0 -8
  656. package/dist/tools/search-events/utils.d.ts +0 -8
  657. package/dist/tools/search-events/utils.js +0 -13
  658. package/dist/tools/search-issues/agent.cjs +0 -19
  659. package/dist/tools/search-issues/agent.d.cts +0 -7
  660. package/dist/tools/search-issues/agent.d.ts +0 -7
  661. package/dist/tools/search-issues/agent.js +0 -18
  662. package/dist/tools/search-issues/config.cjs +0 -3
  663. package/dist/tools/search-issues/config.d.cts +0 -9
  664. package/dist/tools/search-issues/config.d.cts.map +0 -1
  665. package/dist/tools/search-issues/config.d.ts +0 -9
  666. package/dist/tools/search-issues/config.d.ts.map +0 -1
  667. package/dist/tools/search-issues/config.js +0 -3
  668. package/dist/tools/search-issues/formatters.cjs +0 -5
  669. package/dist/tools/search-issues/formatters.d.cts +0 -28
  670. package/dist/tools/search-issues/formatters.d.cts.map +0 -1
  671. package/dist/tools/search-issues/formatters.d.ts +0 -28
  672. package/dist/tools/search-issues/formatters.d.ts.map +0 -1
  673. package/dist/tools/search-issues/formatters.js +0 -4
  674. package/dist/tools/search-issues/handler.cjs +0 -27
  675. package/dist/tools/search-issues/handler.d.cts +0 -6
  676. package/dist/tools/search-issues/handler.d.ts +0 -6
  677. package/dist/tools/search-issues/handler.js +0 -27
  678. package/dist/tools/search-issues/index.cjs +0 -30
  679. package/dist/tools/search-issues/index.d.cts +0 -12
  680. package/dist/tools/search-issues/index.d.ts +0 -12
  681. package/dist/tools/search-issues/index.js +0 -28
  682. package/dist/tools/types.cjs +0 -0
  683. package/dist/tools/types.d.cts +0 -5
  684. package/dist/tools/types.d.ts +0 -5
  685. package/dist/tools/types.js +0 -0
  686. package/dist/tools/update-issue.cjs +0 -24
  687. package/dist/tools/update-issue.d.cts +0 -18
  688. package/dist/tools/update-issue.d.cts.map +0 -1
  689. package/dist/tools/update-issue.d.ts +0 -18
  690. package/dist/tools/update-issue.d.ts.map +0 -1
  691. package/dist/tools/update-issue.js +0 -24
  692. package/dist/tools/update-project.cjs +0 -19
  693. package/dist/tools/update-project.d.cts +0 -19
  694. package/dist/tools/update-project.d.cts.map +0 -1
  695. package/dist/tools/update-project.d.ts +0 -19
  696. package/dist/tools/update-project.d.ts.map +0 -1
  697. package/dist/tools/update-project.js +0 -19
  698. package/dist/tools/use-sentry/agent.cjs +0 -8
  699. package/dist/tools/use-sentry/agent.d.cts +0 -3
  700. package/dist/tools/use-sentry/agent.d.ts +0 -3
  701. package/dist/tools/use-sentry/agent.js +0 -8
  702. package/dist/tools/use-sentry/config.cjs +0 -4
  703. package/dist/tools/use-sentry/config.d.cts +0 -21
  704. package/dist/tools/use-sentry/config.d.cts.map +0 -1
  705. package/dist/tools/use-sentry/config.d.ts +0 -21
  706. package/dist/tools/use-sentry/config.d.ts.map +0 -1
  707. package/dist/tools/use-sentry/config.js +0 -3
  708. package/dist/tools/use-sentry/handler.cjs +0 -65
  709. package/dist/tools/use-sentry/handler.d.cts +0 -6
  710. package/dist/tools/use-sentry/handler.d.ts +0 -6
  711. package/dist/tools/use-sentry/handler.js +0 -65
  712. package/dist/tools/use-sentry/index.cjs +0 -67
  713. package/dist/tools/use-sentry/index.d.cts +0 -8
  714. package/dist/tools/use-sentry/index.d.ts +0 -8
  715. package/dist/tools/use-sentry/index.js +0 -65
  716. package/dist/tools/use-sentry/tool-wrapper.cjs +0 -63
  717. package/dist/tools/use-sentry/tool-wrapper.cjs.map +0 -1
  718. package/dist/tools/use-sentry/tool-wrapper.d.cts +0 -119
  719. package/dist/tools/use-sentry/tool-wrapper.d.cts.map +0 -1
  720. package/dist/tools/use-sentry/tool-wrapper.d.ts +0 -119
  721. package/dist/tools/use-sentry/tool-wrapper.d.ts.map +0 -1
  722. package/dist/tools/use-sentry/tool-wrapper.js +0 -62
  723. package/dist/tools/use-sentry/tool-wrapper.js.map +0 -1
  724. package/dist/tools/whoami.cjs +0 -17
  725. package/dist/tools/whoami.d.cts +0 -10
  726. package/dist/tools/whoami.d.cts.map +0 -1
  727. package/dist/tools/whoami.d.ts +0 -10
  728. package/dist/tools/whoami.d.ts.map +0 -1
  729. package/dist/tools/whoami.js +0 -17
  730. package/dist/types-B_3dsqbN.d.cts +0 -38
  731. package/dist/types-B_3dsqbN.d.cts.map +0 -1
  732. package/dist/types-Cet6uyS6.d.ts +0 -41
  733. package/dist/types-Cet6uyS6.d.ts.map +0 -1
  734. package/dist/types-CokRupPo.d.cts +0 -33
  735. package/dist/types-CokRupPo.d.cts.map +0 -1
  736. package/dist/types-D1CEiyup.d.cts +0 -41
  737. package/dist/types-D1CEiyup.d.cts.map +0 -1
  738. package/dist/types-D670-rDz.js +0 -0
  739. package/dist/types-OrkP7cEA.d.ts +0 -33
  740. package/dist/types-OrkP7cEA.d.ts.map +0 -1
  741. package/dist/types-n3wuZu5X.cjs +0 -0
  742. package/dist/types-u52qwG59.d.ts +0 -38
  743. package/dist/types-u52qwG59.d.ts.map +0 -1
  744. package/dist/types.cjs +0 -16
  745. package/dist/types.cjs.map +0 -1
  746. package/dist/types.d.cts +0 -4
  747. package/dist/types.d.ts +0 -4
  748. package/dist/types.js +0 -15
  749. package/dist/types.js.map +0 -1
  750. package/dist/update-issue-BGm8g4G0.js +0 -118
  751. package/dist/update-issue-BGm8g4G0.js.map +0 -1
  752. package/dist/update-issue-Dx2EZ5pY.cjs +0 -124
  753. package/dist/update-issue-Dx2EZ5pY.cjs.map +0 -1
  754. package/dist/update-project-B0clXxii.js +0 -128
  755. package/dist/update-project-B0clXxii.js.map +0 -1
  756. package/dist/update-project-BJkzcapF.cjs +0 -134
  757. package/dist/update-project-BJkzcapF.cjs.map +0 -1
  758. package/dist/url-utils-CbcNJVYS.cjs +0 -235
  759. package/dist/url-utils-CbcNJVYS.cjs.map +0 -1
  760. package/dist/url-utils-CfKwo6s5.js +0 -175
  761. package/dist/url-utils-CfKwo6s5.js.map +0 -1
  762. package/dist/usage-CMWaPhZv.cjs.map +0 -1
  763. package/dist/usage-CpguKuwi.js.map +0 -1
  764. package/dist/utils/slug-validation.cjs +0 -5
  765. package/dist/utils/slug-validation.d.cts +0 -51
  766. package/dist/utils/slug-validation.d.cts.map +0 -1
  767. package/dist/utils/slug-validation.d.ts +0 -51
  768. package/dist/utils/slug-validation.d.ts.map +0 -1
  769. package/dist/utils/slug-validation.js +0 -3
  770. package/dist/utils/url-utils.cjs +0 -12
  771. package/dist/utils/url-utils.d.cts +0 -87
  772. package/dist/utils/url-utils.d.cts.map +0 -1
  773. package/dist/utils/url-utils.d.ts +0 -87
  774. package/dist/utils/url-utils.d.ts.map +0 -1
  775. package/dist/utils/url-utils.js +0 -3
  776. package/dist/utils-C7sQWgE3.d.cts +0 -39
  777. package/dist/utils-C7sQWgE3.d.cts.map +0 -1
  778. package/dist/utils-CIt6Amml.cjs +0 -124
  779. package/dist/utils-CIt6Amml.cjs.map +0 -1
  780. package/dist/utils-CaNeCYCH.js +0 -94
  781. package/dist/utils-CaNeCYCH.js.map +0 -1
  782. package/dist/utils-CmH2wxA_.d.ts +0 -39
  783. package/dist/utils-CmH2wxA_.d.ts.map +0 -1
  784. package/dist/utils-DJIwl8YR.cjs +0 -96
  785. package/dist/utils-DJIwl8YR.cjs.map +0 -1
  786. package/dist/utils-DOb7bs5_.js +0 -90
  787. package/dist/utils-DOb7bs5_.js.map +0 -1
  788. package/dist/utils-R15EJutP.d.ts +0 -43
  789. package/dist/utils-R15EJutP.d.ts.map +0 -1
  790. package/dist/utils-RPc9DHgJ.d.cts +0 -43
  791. package/dist/utils-RPc9DHgJ.d.cts.map +0 -1
  792. package/dist/validate-region-url-Bdokgz65.js +0 -37
  793. package/dist/validate-region-url-Bdokgz65.js.map +0 -1
  794. package/dist/validate-region-url-BvT-IgKg.cjs +0 -42
  795. package/dist/validate-region-url-BvT-IgKg.cjs.map +0 -1
  796. package/dist/version-CaFsr_xb.cjs +0 -19
  797. package/dist/version-CaFsr_xb.cjs.map +0 -1
  798. package/dist/version-DY1nl1TZ.js +0 -7
  799. package/dist/version-DY1nl1TZ.js.map +0 -1
  800. package/dist/version.cjs +0 -4
  801. package/dist/version.d.cts +0 -8
  802. package/dist/version.d.cts.map +0 -1
  803. package/dist/version.d.ts +0 -8
  804. package/dist/version.d.ts.map +0 -1
  805. package/dist/version.js +0 -3
  806. package/dist/whoami-9JymZ3NV.cjs +0 -46
  807. package/dist/whoami-9JymZ3NV.cjs.map +0 -1
  808. package/dist/whoami-BsX-LoXG.js +0 -34
  809. package/dist/whoami-BsX-LoXG.js.map +0 -1
  810. package/dist/whoami-DRDjyhDL.cjs +0 -44
  811. package/dist/whoami-DRDjyhDL.cjs.map +0 -1
  812. package/dist/whoami-FliA3IrX.js +0 -39
  813. package/dist/whoami-FliA3IrX.js.map +0 -1
@@ -1,984 +0,0 @@
1
- const require_logging = require('./logging-C-ST7-Ow.cjs');
2
- const require_seer = require('./seer-sA1asAZs.cjs');
3
-
4
- //#region src/internal/formatting.ts
5
- const LANGUAGE_EXTENSIONS = {
6
- ".java": "java",
7
- ".py": "python",
8
- ".js": "javascript",
9
- ".jsx": "javascript",
10
- ".ts": "javascript",
11
- ".tsx": "javascript",
12
- ".rb": "ruby",
13
- ".php": "php"
14
- };
15
- const LANGUAGE_MODULE_PATTERNS = [[/^(java\.|com\.|org\.)/, "java"]];
16
- /**
17
- * Detects the programming language of a stack frame based on the file extension.
18
- * Falls back to the platform parameter if no filename is available or extension is unrecognized.
19
- *
20
- * @param frame - The stack frame containing file and location information
21
- * @param platform - Optional platform hint to use as fallback
22
- * @returns The detected language or platform fallback or "unknown"
23
- */
24
- function detectLanguage(frame, platform) {
25
- if (frame.filename) {
26
- const ext = frame.filename.toLowerCase().match(/\.[^.]+$/)?.[0];
27
- if (ext && LANGUAGE_EXTENSIONS[ext]) return LANGUAGE_EXTENSIONS[ext];
28
- }
29
- if (frame.module) {
30
- for (const [pattern, language] of LANGUAGE_MODULE_PATTERNS) if (pattern.test(frame.module)) return language;
31
- }
32
- return platform || "unknown";
33
- }
34
- /**
35
- * Formats a stack frame into a language-specific string representation.
36
- * Different languages have different conventions for displaying stack traces.
37
- *
38
- * @param frame - The stack frame to format
39
- * @param frameIndex - Optional frame index for languages that display frame numbers
40
- * @param platform - Optional platform hint for language detection fallback
41
- * @returns Formatted stack frame string
42
- */
43
- function formatFrameHeader(frame, frameIndex, platform) {
44
- const language = detectLanguage(frame, platform);
45
- switch (language) {
46
- case "java": {
47
- const className = frame.module || "UnknownClass";
48
- const method = frame.function || "<unknown>";
49
- const source = frame.filename || "Unknown Source";
50
- const location = frame.lineNo ? `:${frame.lineNo}` : "";
51
- return `at ${className}.${method}(${source}${location})`;
52
- }
53
- case "python": {
54
- const file = frame.filename || frame.absPath || frame.module || "<unknown>";
55
- const func = frame.function || "<module>";
56
- const line = frame.lineNo ? `, line ${frame.lineNo}` : "";
57
- return ` File "${file}"${line}, in ${func}`;
58
- }
59
- case "javascript": return `${[
60
- frame.filename,
61
- frame.lineNo,
62
- frame.colNo
63
- ].filter((i) => !!i).join(":")}${frame.function ? ` (${frame.function})` : ""}`;
64
- case "ruby": {
65
- const file = frame.filename || frame.module || "<unknown>";
66
- const func = frame.function ? ` \`${frame.function}\`` : "";
67
- const line = frame.lineNo ? `:${frame.lineNo}:in` : "";
68
- return ` from ${file}${line}${func}`;
69
- }
70
- case "php": {
71
- const file = frame.filename || "<unknown>";
72
- const line = frame.lineNo ? `(${frame.lineNo})` : "";
73
- const func = frame.function || "<unknown>";
74
- const prefix = frameIndex !== void 0 ? `#${frameIndex} ` : "";
75
- return `${prefix}${file}${line}: ${func}()`;
76
- }
77
- default: {
78
- const func = frame.function || "<unknown>";
79
- const location = frame.filename || frame.module || "<unknown>";
80
- const line = frame.lineNo ? `:${frame.lineNo}` : "";
81
- const col = frame.colNo != null ? `:${frame.colNo}` : "";
82
- return ` at ${func} (${location}${line}${col})`;
83
- }
84
- }
85
- }
86
- /**
87
- * Formats a Sentry event into a structured markdown output.
88
- * Includes error messages, stack traces, request info, and contextual data.
89
- *
90
- * @param event - The Sentry event to format
91
- * @param options - Additional formatting context
92
- * @returns Formatted markdown string
93
- */
94
- function formatEventOutput(event, options) {
95
- let output = "";
96
- if (!event.entries || !Array.isArray(event.entries)) {
97
- output += formatTags(event.tags);
98
- output += formatContext(event.context);
99
- output += formatContexts(event.contexts);
100
- return output;
101
- }
102
- const messageEntry = event.entries.find((e) => e.type === "message");
103
- const exceptionEntry = event.entries.find((e) => e.type === "exception");
104
- const threadsEntry = event.entries.find((e) => e.type === "threads");
105
- const requestEntry = event.entries.find((e) => e.type === "request");
106
- const spansEntry = event.entries.find((e) => e.type === "spans");
107
- const cspEntry = event.entries.find((e) => e.type === "csp");
108
- if (messageEntry) output += formatMessageInterfaceOutput(event, messageEntry.data);
109
- if (exceptionEntry) output += formatExceptionInterfaceOutput(event, exceptionEntry.data);
110
- else if (threadsEntry) output += formatThreadsInterfaceOutput(event, threadsEntry.data);
111
- if (requestEntry) output += formatRequestInterfaceOutput(event, requestEntry.data);
112
- if (cspEntry) output += formatCspInterfaceOutput(event, cspEntry.data);
113
- if (event.type === "transaction") output += formatPerformanceIssueOutput(event, spansEntry?.data, options);
114
- if (event.type === "generic") output += formatGenericEventOutput(event);
115
- output += formatTags(event.tags);
116
- output += formatContext(event.context);
117
- output += formatContexts(event.contexts);
118
- return output;
119
- }
120
- /**
121
- * Extracts the context line matching the frame's line number for inline display.
122
- * This is used in the full stacktrace view to show the actual line of code
123
- * that caused the error inline with the stack frame.
124
- *
125
- * @param frame - The stack frame containing context lines
126
- * @returns The line of code at the frame's line number, or empty string if not available
127
- */
128
- function renderInlineContext(frame) {
129
- if (!frame.context?.length || !frame.lineNo) return "";
130
- const contextLine = frame.context.find(([lineNo]) => lineNo === frame.lineNo);
131
- return contextLine ? `\n${contextLine[1]}` : "";
132
- }
133
- /**
134
- * Renders an enhanced view of a stack frame with context lines and variables.
135
- * Used for the "Most Relevant Frame" section to provide detailed information
136
- * about the most relevant application frame where the error occurred.
137
- *
138
- * @param frame - The stack frame to render with enhanced information
139
- * @param event - The Sentry event containing platform information for language detection
140
- * @returns Formatted string with frame header, context lines, and variables table
141
- */
142
- function renderEnhancedFrame(frame, event) {
143
- const parts = [];
144
- parts.push("**Most Relevant Frame:**");
145
- parts.push("─────────────────────");
146
- parts.push(formatFrameHeader(frame, void 0, event.platform));
147
- if (frame.context?.length) {
148
- const contextLines = renderContextLines(frame);
149
- if (contextLines) {
150
- parts.push("");
151
- parts.push(contextLines);
152
- }
153
- }
154
- if (frame.vars && Object.keys(frame.vars).length > 0) {
155
- parts.push("");
156
- parts.push(renderVariablesTable(frame.vars));
157
- }
158
- return parts.join("\n");
159
- }
160
- function formatExceptionInterfaceOutput(event, data) {
161
- const parts = [];
162
- const exceptions = data.values || (data.value ? [data.value] : []);
163
- if (exceptions.length === 0) return "";
164
- const isChained = exceptions.length > 1;
165
- [...exceptions].reverse().forEach((exception, index) => {
166
- if (!exception) return;
167
- if (isChained && index > 0) {
168
- parts.push("");
169
- parts.push(getExceptionChainMessage(event.platform || null, index, exceptions.length));
170
- parts.push("");
171
- }
172
- const exceptionTitle = `${exception.type}${exception.value ? `: ${exception.value}` : ""}`;
173
- parts.push(index === 0 ? "### Error" : `### ${exceptionTitle}`);
174
- parts.push("");
175
- if (index === 0) {
176
- parts.push("```");
177
- parts.push(exceptionTitle);
178
- parts.push("```");
179
- parts.push("");
180
- }
181
- if (!exception.stacktrace || !exception.stacktrace.frames) {
182
- parts.push("**Stacktrace:**");
183
- parts.push("```");
184
- parts.push("No stacktrace available");
185
- parts.push("```");
186
- return;
187
- }
188
- const frames = exception.stacktrace.frames;
189
- if (index === 0) {
190
- const firstInAppFrame = findFirstInAppFrame(frames);
191
- if (firstInAppFrame && (firstInAppFrame.context?.length || firstInAppFrame.vars)) {
192
- parts.push(renderEnhancedFrame(firstInAppFrame, event));
193
- parts.push("");
194
- parts.push("**Full Stacktrace:**");
195
- parts.push("────────────────");
196
- } else parts.push("**Stacktrace:**");
197
- } else parts.push("**Stacktrace:**");
198
- parts.push("```");
199
- parts.push(frames.map((frame) => {
200
- const header = formatFrameHeader(frame, void 0, event.platform);
201
- const context = renderInlineContext(frame);
202
- return `${header}${context}`;
203
- }).join("\n"));
204
- parts.push("```");
205
- });
206
- parts.push("");
207
- parts.push("");
208
- return parts.join("\n");
209
- }
210
- /**
211
- * Get the appropriate exception chain message based on the platform
212
- */
213
- function getExceptionChainMessage(platform, index, totalExceptions) {
214
- const defaultMessage = "**During handling of the above exception, another exception occurred:**";
215
- if (!platform) return defaultMessage;
216
- switch (platform.toLowerCase()) {
217
- case "python": return "**During handling of the above exception, another exception occurred:**";
218
- case "java": return "**Caused by:**";
219
- case "csharp":
220
- case "dotnet": return "**---> Inner Exception:**";
221
- case "ruby": return "**Caused by:**";
222
- case "go": return "**Wrapped error:**";
223
- case "rust": return `**Caused by (${index}):**`;
224
- default: return defaultMessage;
225
- }
226
- }
227
- function formatCspInterfaceOutput(event, data) {
228
- if (!data) return "";
229
- const parts = [];
230
- parts.push("### CSP Violation");
231
- parts.push("");
232
- if (data.blocked_uri) parts.push(`**Blocked URI**: ${data.blocked_uri}`);
233
- if (data.violated_directive) parts.push(`**Violated Directive**: ${data.violated_directive}`);
234
- if (data.effective_directive) parts.push(`**Effective Directive**: ${data.effective_directive}`);
235
- if (data.document_uri) parts.push(`**Document URI**: ${data.document_uri}`);
236
- if (data.source_file) {
237
- parts.push(`**Source File**: ${data.source_file}`);
238
- if (data.line_number) parts.push(`**Line Number**: ${data.line_number}`);
239
- }
240
- if (data.disposition) parts.push(`**Disposition**: ${data.disposition}`);
241
- if (data.original_policy) {
242
- parts.push("");
243
- parts.push("**Original Policy:**");
244
- parts.push("```");
245
- parts.push(data.original_policy);
246
- parts.push("```");
247
- }
248
- parts.push("");
249
- parts.push("");
250
- return parts.join("\n");
251
- }
252
- function formatRequestInterfaceOutput(event, data) {
253
- if (!data.method || !data.url) return "";
254
- return `### HTTP Request\n\n**Method:** ${data.method}\n**URL:** ${data.url}\n\n`;
255
- }
256
- function formatMessageInterfaceOutput(event, data) {
257
- if (!data.formatted && !data.message) return "";
258
- const message = data.formatted || data.message || "";
259
- return `### Error\n\n\`\`\`\n${message}\n\`\`\`\n\n`;
260
- }
261
- function formatThreadsInterfaceOutput(event, data) {
262
- if (!data.values || data.values.length === 0) return "";
263
- const crashedThread = data.values.find((t) => t.crashed);
264
- if (!crashedThread?.stacktrace?.frames) return "";
265
- const parts = [];
266
- if (crashedThread.name) {
267
- parts.push(`**Thread** (${crashedThread.name})`);
268
- parts.push("");
269
- }
270
- const frames = crashedThread.stacktrace.frames;
271
- const firstInAppFrame = findFirstInAppFrame(frames);
272
- if (firstInAppFrame && (firstInAppFrame.context?.length || firstInAppFrame.vars)) {
273
- parts.push(renderEnhancedFrame(firstInAppFrame, event));
274
- parts.push("");
275
- parts.push("**Full Stacktrace:**");
276
- parts.push("────────────────");
277
- } else parts.push("**Stacktrace:**");
278
- parts.push("```");
279
- parts.push(frames.map((frame) => {
280
- const header = formatFrameHeader(frame, void 0, event.platform);
281
- const context = renderInlineContext(frame);
282
- return `${header}${context}`;
283
- }).join("\n"));
284
- parts.push("```");
285
- parts.push("");
286
- return parts.join("\n");
287
- }
288
- /**
289
- * Renders surrounding source code context for a stack frame.
290
- * Shows a window of code lines around the error line with visual indicators.
291
- *
292
- * @param frame - The stack frame containing context lines
293
- * @param contextSize - Number of lines to show before and after the error line (default: 3)
294
- * @returns Formatted context lines with line numbers and arrow indicator for the error line
295
- */
296
- function renderContextLines(frame, contextSize = 3) {
297
- if (!frame.context || frame.context.length === 0 || !frame.lineNo) return "";
298
- const lines = [];
299
- const errorLine = frame.lineNo;
300
- const maxLineNoWidth = Math.max(...frame.context.map(([lineNo]) => lineNo.toString().length));
301
- for (const [lineNo, code] of frame.context) {
302
- const isErrorLine = lineNo === errorLine;
303
- const lineNoStr = lineNo.toString().padStart(maxLineNoWidth, " ");
304
- if (Math.abs(lineNo - errorLine) <= contextSize) if (isErrorLine) lines.push(` → ${lineNoStr} │ ${code}`);
305
- else lines.push(` ${lineNoStr} │ ${code}`);
306
- }
307
- return lines.join("\n");
308
- }
309
- /**
310
- * Formats a variable value for display in the variables table.
311
- * Handles different types appropriately and safely, converting complex objects
312
- * to readable representations and handling edge cases like circular references.
313
- *
314
- * @param value - The variable value to format (can be any type)
315
- * @param maxLength - Maximum length for stringified objects/arrays (default: 80)
316
- * @returns Human-readable string representation of the value
317
- */
318
- function formatVariableValue(value, maxLength = 80) {
319
- try {
320
- if (typeof value === "string") return `"${value}"`;
321
- if (value === null) return "null";
322
- if (value === void 0) return "undefined";
323
- if (typeof value === "object") {
324
- const stringified = JSON.stringify(value);
325
- if (stringified.length > maxLength) {
326
- const truncateAt = maxLength - 6;
327
- let truncated = stringified.substring(0, truncateAt);
328
- const lastComma = truncated.lastIndexOf(",");
329
- if (lastComma > 0) truncated = truncated.substring(0, lastComma);
330
- if (Array.isArray(value)) return `${truncated}, ...]`;
331
- return `${truncated}, ...}`;
332
- }
333
- return stringified;
334
- }
335
- return String(value);
336
- } catch {
337
- return `<${typeof value}>`;
338
- }
339
- }
340
- /**
341
- * Renders a table of local variables in a tree-like format.
342
- * Uses box-drawing characters to create a visual hierarchy of variables
343
- * and their values at the point where the error occurred.
344
- *
345
- * @param vars - Object containing variable names as keys and their values
346
- * @returns Formatted variables table with tree-style prefix characters
347
- */
348
- function renderVariablesTable(vars) {
349
- const entries = Object.entries(vars);
350
- if (entries.length === 0) return "";
351
- const lines = ["Local Variables:"];
352
- const lastIndex = entries.length - 1;
353
- entries.forEach(([key, value], index) => {
354
- const prefix = index === lastIndex ? "└─" : "├─";
355
- const valueStr = formatVariableValue(value);
356
- lines.push(`${prefix} ${key}: ${valueStr}`);
357
- });
358
- return lines.join("\n");
359
- }
360
- /**
361
- * Finds the first application frame (in_app) in a stack trace.
362
- * Searches from the bottom of the stack (oldest frame) to find the first
363
- * frame that belongs to the user's application code rather than libraries.
364
- *
365
- * @param frames - Array of stack frames, typically in reverse chronological order
366
- * @returns The first in-app frame found, or undefined if none exist
367
- */
368
- function findFirstInAppFrame(frames) {
369
- for (let i = frames.length - 1; i >= 0; i--) if (frames[i].inApp === true) return frames[i];
370
- return void 0;
371
- }
372
- /**
373
- * Constants for performance issue formatting
374
- */
375
- const MAX_SPANS_IN_TREE = 10;
376
- /**
377
- * Safely parse a number from a string, returning a default if invalid
378
- */
379
- function safeParseInt(value, defaultValue) {
380
- if (typeof value === "number") return value;
381
- if (typeof value === "string") {
382
- const parsed = Number.parseInt(value, 10);
383
- return Number.isNaN(parsed) ? defaultValue : parsed;
384
- }
385
- return defaultValue;
386
- }
387
- function normalizeSpanId(value) {
388
- if (typeof value === "string" && value) return value;
389
- return void 0;
390
- }
391
- function getSpanIdentifier(span) {
392
- if (span.span_id !== void 0) return normalizeSpanId(span.span_id);
393
- if (span.id !== void 0) return normalizeSpanId(span.id);
394
- return void 0;
395
- }
396
- function getSpanDurationMs(span) {
397
- if (typeof span.timestamp === "number" && typeof span.start_timestamp === "number") {
398
- const deltaSeconds = span.timestamp - span.start_timestamp;
399
- if (Number.isFinite(deltaSeconds) && deltaSeconds >= 0) return deltaSeconds * 1e3;
400
- }
401
- if (typeof span.duration === "number" && Number.isFinite(span.duration)) return span.duration >= 0 ? span.duration : 0;
402
- return 0;
403
- }
404
- function normalizeIdArray(values) {
405
- if (!Array.isArray(values)) return [];
406
- return values.map((value) => normalizeSpanId(value)).filter((value) => value !== void 0);
407
- }
408
- function isValidSpanArray(value) {
409
- return Array.isArray(value);
410
- }
411
- /**
412
- * Get the repeating span descriptions from evidence data.
413
- * Prefers repeatingSpansCompact (more concise) over repeatingSpans (verbose).
414
- */
415
- function getRepeatingSpanLines(evidenceData) {
416
- if (Array.isArray(evidenceData.repeatingSpansCompact) && evidenceData.repeatingSpansCompact.length > 0) return evidenceData.repeatingSpansCompact.map((s) => typeof s === "string" ? s.trim() : "").filter((s) => s.length > 0);
417
- if (Array.isArray(evidenceData.repeatingSpans) && evidenceData.repeatingSpans.length > 0) return evidenceData.repeatingSpans.map((s) => typeof s === "string" ? s.trim() : "").filter((s) => s.length > 0);
418
- return [];
419
- }
420
- function isTraceSpan(node) {
421
- if (node === null || typeof node !== "object") return false;
422
- const candidate = node;
423
- return candidate.event_type === "span" && typeof candidate.event_id === "string";
424
- }
425
- function buildTraceSpanTree(trace, parentSpanIds, offenderSpanIds, maxSpans) {
426
- const offenderSet = new Set(offenderSpanIds);
427
- const spanMap = /* @__PURE__ */ new Map();
428
- function indexSpan(span) {
429
- const spanId = normalizeSpanId(span.additional_attributes?.span_id) || span.event_id;
430
- if (spanId && spanId.length > 0) spanMap.set(spanId, span);
431
- for (const child of span.children ?? []) if (isTraceSpan(child)) indexSpan(child);
432
- }
433
- for (const node of trace) if (isTraceSpan(node)) indexSpan(node);
434
- const roots = [];
435
- const budget = {
436
- count: 0,
437
- limit: maxSpans
438
- };
439
- for (const parentId of parentSpanIds) {
440
- const span = spanMap.get(parentId);
441
- if (!span) continue;
442
- const perfSpan = convertTraceSpanToPerformanceSpan(span, offenderSet, budget, 0);
443
- if (perfSpan) roots.push(perfSpan);
444
- if (budget.count >= budget.limit) break;
445
- }
446
- if (roots.length === 0 && offenderSpanIds.length > 0) for (const offenderId of offenderSpanIds) {
447
- const span = spanMap.get(offenderId);
448
- if (!span) continue;
449
- const perfSpan = convertTraceSpanToPerformanceSpan(span, offenderSet, budget, 0);
450
- if (perfSpan) roots.push(perfSpan);
451
- if (budget.count >= budget.limit) break;
452
- }
453
- if (roots.length === 0) return [];
454
- return renderPerformanceSpanTree(roots);
455
- }
456
- function convertTraceSpanToPerformanceSpan(span, offenderSet, budget, level) {
457
- if (budget.count >= budget.limit) return null;
458
- budget.count += 1;
459
- const spanId = normalizeSpanId(span.additional_attributes?.span_id) || span.event_id;
460
- const performanceSpan = {
461
- span_id: spanId,
462
- op: span.op || "unknown",
463
- description: formatTraceSpanDescription(span),
464
- duration: getTraceSpanDurationMs(span),
465
- is_n1_query: offenderSet.has(spanId),
466
- children: [],
467
- level
468
- };
469
- for (const child of span.children ?? []) {
470
- if (!isTraceSpan(child)) continue;
471
- if (budget.count >= budget.limit) break;
472
- const childSpan = convertTraceSpanToPerformanceSpan(child, offenderSet, budget, level + 1);
473
- if (childSpan) performanceSpan.children.push(childSpan);
474
- if (budget.count >= budget.limit) break;
475
- }
476
- return performanceSpan;
477
- }
478
- function formatTraceSpanDescription(span) {
479
- if (span.name && span.name.trim().length > 0) return span.name.trim();
480
- if (span.description && span.description.trim().length > 0) return span.description.trim();
481
- if (span.op && span.op.trim().length > 0) return span.op.trim();
482
- return "unnamed";
483
- }
484
- function getTraceSpanDurationMs(span) {
485
- if (typeof span.duration === "number" && span.duration >= 0) return span.duration;
486
- if (typeof span.end_timestamp === "number" && typeof span.start_timestamp === "number") {
487
- const deltaSeconds = span.end_timestamp - span.start_timestamp;
488
- if (Number.isFinite(deltaSeconds) && deltaSeconds >= 0) return deltaSeconds * 1e3;
489
- }
490
- return 0;
491
- }
492
- function buildOffenderSummaries(spans, offenderSpanIds) {
493
- if (offenderSpanIds.length === 0) return [];
494
- const spanMap = /* @__PURE__ */ new Map();
495
- for (const span of spans) {
496
- const identifier = getSpanIdentifier(span);
497
- if (identifier) spanMap.set(identifier, span);
498
- }
499
- const summaries = [];
500
- for (const offenderId of offenderSpanIds) {
501
- const span = spanMap.get(offenderId);
502
- if (span) {
503
- const description = span.description || span.op || `Span ${offenderId}`;
504
- const duration = getSpanDurationMs(span);
505
- const durationLabel = duration > 0 ? ` (${Math.round(duration)}ms)` : "";
506
- summaries.push(`${description}${durationLabel} [${offenderId}] [N+1]`);
507
- } else summaries.push(`Span ${offenderId} [N+1]`);
508
- }
509
- return summaries;
510
- }
511
- /**
512
- * Renders a hierarchical tree of performance spans using box-drawing characters.
513
- * Highlights N+1 queries with a special indicator.
514
- *
515
- * @param spans - Array of selected performance spans
516
- * @returns Array of formatted strings representing the tree
517
- */
518
- function renderPerformanceSpanTree(spans) {
519
- const lines = [];
520
- function renderSpan(span, prefix = "", isLast = true) {
521
- const connector = prefix === "" ? "" : isLast ? "└─ " : "├─ ";
522
- const displayName = span.description?.trim() || span.op || "unnamed";
523
- const shortId = span.span_id ? span.span_id.substring(0, 8) : "unknown";
524
- const durationDisplay = span.duration > 0 ? `${Math.round(span.duration)}ms` : "unknown";
525
- const metadataParts = [shortId];
526
- if (span.op && span.op !== "default") metadataParts.push(span.op);
527
- metadataParts.push(durationDisplay);
528
- const line = `${prefix}${connector}${displayName} [${metadataParts.join(" · ")}]${span.is_n1_query ? " [N+1]" : ""}`;
529
- lines.push(line);
530
- for (let i = 0; i < span.children.length; i++) {
531
- const child = span.children[i];
532
- const isLastChild = i === span.children.length - 1;
533
- const childPrefix = prefix + (isLast ? " " : "│ ");
534
- renderSpan(child, childPrefix, isLastChild);
535
- }
536
- }
537
- for (let i = 0; i < spans.length; i++) {
538
- const span = spans[i];
539
- const isLastRoot = i === spans.length - 1;
540
- renderSpan(span, "", isLastRoot);
541
- }
542
- return lines;
543
- }
544
- function selectN1QuerySpans(spans, evidence, maxSpans = MAX_SPANS_IN_TREE) {
545
- const selected = [];
546
- let spanCount = 0;
547
- const offenderSpanIds = normalizeIdArray(evidence.offenderSpanIds);
548
- const parentSpanIds = normalizeIdArray(evidence.parentSpanIds);
549
- let parentSpan = null;
550
- if (parentSpanIds.length > 0) {
551
- const parent = spans.find((span) => {
552
- const identifier = getSpanIdentifier(span);
553
- return identifier ? parentSpanIds.includes(identifier) : false;
554
- });
555
- if (parent) {
556
- parentSpan = {
557
- span_id: getSpanIdentifier(parent) ?? "unknown",
558
- op: parent.op || "unknown",
559
- description: parent.description || evidence.parentSpan || "Parent Operation",
560
- duration: getSpanDurationMs(parent),
561
- is_n1_query: false,
562
- children: [],
563
- level: 0
564
- };
565
- selected.push(parentSpan);
566
- spanCount += 1;
567
- }
568
- }
569
- if (offenderSpanIds.length > 0) {
570
- const offenderSet = new Set(offenderSpanIds);
571
- const offenderSpans = spans.filter((span) => {
572
- const identifier = getSpanIdentifier(span);
573
- return identifier ? offenderSet.has(identifier) : false;
574
- }).slice(0, Math.max(0, maxSpans - spanCount));
575
- for (const span of offenderSpans) {
576
- const perfSpan = {
577
- span_id: getSpanIdentifier(span) ?? "unknown",
578
- op: span.op || "db.query",
579
- description: span.description || "Database Query",
580
- duration: getSpanDurationMs(span),
581
- is_n1_query: true,
582
- children: [],
583
- level: parentSpan ? 1 : 0
584
- };
585
- if (parentSpan) parentSpan.children.push(perfSpan);
586
- else selected.push(perfSpan);
587
- spanCount += 1;
588
- if (spanCount >= maxSpans) break;
589
- }
590
- }
591
- return selected;
592
- }
593
- /**
594
- * Known Sentry performance issue types that we handle.
595
- *
596
- * NOTE: We intentionally only implement formatters for high-value performance issues
597
- * that provide complex insights. Not all issue types need custom formatting - many
598
- * can rely on the generic evidenceDisplay fields that Sentry provides.
599
- *
600
- * Currently fully implemented:
601
- * - N+1 query detection (DB and API)
602
- *
603
- * Partially implemented:
604
- * - Slow DB queries (shows parent span only)
605
- *
606
- * Not implemented (lower priority):
607
- * - Asset-related issues (render blocking, uncompressed, large payloads)
608
- * - File I/O issues
609
- * - Consecutive queries
610
- */
611
- const KNOWN_PERFORMANCE_ISSUE_TYPES = {
612
- N_PLUS_ONE_DB_QUERIES: "performance_n_plus_one_db_queries",
613
- N_PLUS_ONE_API_CALLS: "performance_n_plus_one_api_calls",
614
- SLOW_DB_QUERY: "performance_slow_db_query",
615
- RENDER_BLOCKING_ASSET: "performance_render_blocking_asset",
616
- CONSECUTIVE_DB_QUERIES: "performance_consecutive_db_queries",
617
- FILE_IO_MAIN_THREAD: "performance_file_io_main_thread",
618
- M_N_PLUS_ONE_DB_QUERIES: "performance_m_n_plus_one_db_queries",
619
- UNCOMPRESSED_ASSET: "performance_uncompressed_asset",
620
- LARGE_HTTP_PAYLOAD: "performance_large_http_payload"
621
- };
622
- /**
623
- * Map numeric occurrence types to issue types (from Sentry's codebase).
624
- *
625
- * Sentry uses numeric type IDs internally in the occurrence data structure,
626
- * but string issue types in the UI and other APIs. This mapping converts
627
- * between them.
628
- *
629
- * Source: sentry/static/app/types/group.tsx in Sentry's codebase
630
- * Range: 1xxx = transaction-based performance issues
631
- * 2xxx = profile-based performance issues
632
- */
633
- const OCCURRENCE_TYPE_TO_ISSUE_TYPE = {
634
- 1001: KNOWN_PERFORMANCE_ISSUE_TYPES.SLOW_DB_QUERY,
635
- 1004: KNOWN_PERFORMANCE_ISSUE_TYPES.RENDER_BLOCKING_ASSET,
636
- 1006: KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_DB_QUERIES,
637
- 1906: KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_DB_QUERIES,
638
- 1007: KNOWN_PERFORMANCE_ISSUE_TYPES.CONSECUTIVE_DB_QUERIES,
639
- 1008: KNOWN_PERFORMANCE_ISSUE_TYPES.FILE_IO_MAIN_THREAD,
640
- 1009: "performance_consecutive_http",
641
- 1010: KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_API_CALLS,
642
- 1910: KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_API_CALLS,
643
- 1012: KNOWN_PERFORMANCE_ISSUE_TYPES.UNCOMPRESSED_ASSET,
644
- 1013: "performance_db_main_thread",
645
- 1015: KNOWN_PERFORMANCE_ISSUE_TYPES.LARGE_HTTP_PAYLOAD,
646
- 1016: "performance_http_overhead"
647
- };
648
- /**
649
- * Formats N+1 query issue evidence data.
650
- *
651
- * N+1 queries are a common performance anti-pattern where code executes
652
- * 1 query to get a list of items, then N additional queries (one per item)
653
- * instead of using a single JOIN or batch query.
654
- *
655
- * Evidence fields we use:
656
- * - parentSpan: The operation that triggered the N+1 queries
657
- * - repeatingSpansCompact/repeatingSpans: The query pattern being repeated
658
- * - numberRepeatingSpans: How many times the query was executed
659
- * - offenderSpanIds: IDs of the actual span instances
660
- * - parentSpanIds: IDs of parent spans for tree visualization
661
- */
662
- function formatN1QueryEvidence(evidenceData, spansData, performanceTrace) {
663
- const parts = [];
664
- if (evidenceData.parentSpan) {
665
- parts.push("**Parent Operation:**");
666
- parts.push(`${evidenceData.parentSpan}`);
667
- parts.push("");
668
- }
669
- const repeatingLines = getRepeatingSpanLines(evidenceData);
670
- if (repeatingLines.length > 0) {
671
- parts.push("### Repeated Database Queries");
672
- parts.push("");
673
- const queryCount = evidenceData.numberRepeatingSpans ? safeParseInt(evidenceData.numberRepeatingSpans, 0) : evidenceData.numPatternRepetitions || evidenceData.offenderSpanIds?.length || 0;
674
- if (queryCount > 0) parts.push(`**Query executed ${queryCount} times:**`);
675
- if (repeatingLines.length === 1) {
676
- parts.push("```sql");
677
- parts.push(repeatingLines[0]);
678
- parts.push("```");
679
- parts.push("");
680
- } else {
681
- parts.push("**Repeated operations:**");
682
- for (const line of repeatingLines) parts.push(`- ${line}`);
683
- parts.push("");
684
- }
685
- }
686
- const parentSpanIds = normalizeIdArray(evidenceData.parentSpanIds);
687
- const offenderSpanIds = normalizeIdArray(evidenceData.offenderSpanIds);
688
- const traceLines = performanceTrace ? buildTraceSpanTree(performanceTrace, parentSpanIds, offenderSpanIds, MAX_SPANS_IN_TREE) : [];
689
- if (traceLines.length > 0) {
690
- parts.push(`### Span Tree (Limited to ${MAX_SPANS_IN_TREE} spans)`);
691
- parts.push("");
692
- parts.push("```");
693
- parts.push(...traceLines);
694
- parts.push("```");
695
- parts.push("");
696
- } else {
697
- const spanTree = isValidSpanArray(spansData) ? selectN1QuerySpans(spansData, evidenceData, MAX_SPANS_IN_TREE) : [];
698
- if (spanTree.length > 0) {
699
- parts.push(`### Span Tree (Limited to ${MAX_SPANS_IN_TREE} spans)`);
700
- parts.push("");
701
- parts.push("```");
702
- parts.push(...renderPerformanceSpanTree(spanTree));
703
- parts.push("```");
704
- parts.push("");
705
- } else if (isValidSpanArray(spansData)) {
706
- const offenderSummaries = buildOffenderSummaries(spansData, offenderSpanIds);
707
- if (offenderSummaries.length > 0) {
708
- parts.push("### Offending Spans");
709
- parts.push("");
710
- for (const summary of offenderSummaries) parts.push(`- ${summary}`);
711
- }
712
- }
713
- }
714
- return parts.join("\n");
715
- }
716
- /**
717
- * Formats slow DB query issue evidence data.
718
- *
719
- * Currently only partially implemented - shows parent span information.
720
- * Full implementation would show query duration, explain plan, etc.
721
- *
722
- * This is lower priority as the generic evidenceDisplay fields usually
723
- * provide sufficient information for slow query issues.
724
- */
725
- function formatSlowDbQueryEvidence(evidenceData, spansData) {
726
- const parts = [];
727
- if (evidenceData.parentSpan) {
728
- parts.push("**Parent Operation:**");
729
- parts.push(`${evidenceData.parentSpan}`);
730
- parts.push("");
731
- }
732
- console.warn("[formatSlowDbQueryEvidence] Evidence data rendering not yet fully implemented");
733
- return parts.join("\n");
734
- }
735
- /**
736
- * Formats performance issue details from transaction events based on the issue type.
737
- *
738
- * This is the main dispatcher for performance issue formatting. It:
739
- * 1. Detects the issue type from occurrence data (numeric or string)
740
- * 2. Calls the appropriate type-specific formatter if implemented
741
- * 3. Falls back to generic evidenceDisplay fields for unimplemented types
742
- * 4. Provides span analysis fallback for events without occurrence data
743
- *
744
- * The occurrence data structure comes from Sentry's performance issue detection
745
- * and contains evidence about what triggered the issue.
746
- *
747
- * @param event - The transaction event containing performance issue data
748
- * @param spansData - The spans data from the event entries
749
- * @returns Formatted markdown string with performance issue details
750
- */
751
- function formatPerformanceIssueOutput(event, spansData, options) {
752
- const parts = [];
753
- const occurrence = event.occurrence;
754
- if (!occurrence) return "";
755
- let issueType;
756
- if (typeof occurrence.type === "number") issueType = OCCURRENCE_TYPE_TO_ISSUE_TYPE[occurrence.type];
757
- else issueType = occurrence.issueType || occurrence.type;
758
- const evidenceData = occurrence.evidenceData;
759
- if (evidenceData) switch (issueType) {
760
- case KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_DB_QUERIES:
761
- case KNOWN_PERFORMANCE_ISSUE_TYPES.N_PLUS_ONE_API_CALLS:
762
- case KNOWN_PERFORMANCE_ISSUE_TYPES.M_N_PLUS_ONE_DB_QUERIES: {
763
- const result = formatN1QueryEvidence(evidenceData, spansData, options?.performanceTrace);
764
- if (result) parts.push(result);
765
- break;
766
- }
767
- case KNOWN_PERFORMANCE_ISSUE_TYPES.SLOW_DB_QUERY: {
768
- const result = formatSlowDbQueryEvidence(evidenceData, spansData);
769
- if (result) parts.push(result);
770
- break;
771
- }
772
- default: if (issueType) console.warn(`[formatPerformanceIssueOutput] No custom formatter for issue type: ${issueType}`);
773
- }
774
- if (evidenceData?.transactionName) {
775
- parts.push("**Transaction:**");
776
- parts.push(`${evidenceData.transactionName}`);
777
- parts.push("");
778
- }
779
- if (occurrence.evidenceDisplay?.length > 0) {
780
- for (const display of occurrence.evidenceDisplay) if (display.important) {
781
- parts.push(`**${display.name}:**`);
782
- parts.push(`${display.value}`);
783
- parts.push("");
784
- }
785
- }
786
- return parts.length > 0 ? `${parts.join("\n")}\n` : "";
787
- }
788
- /**
789
- * Formats generic event output (performance regressions, metric-based issues).
790
- * Generic events don't have traditional error entries, but have occurrence data
791
- * with evidenceDisplay showing regression details, metric changes, etc.
792
- */
793
- function formatGenericEventOutput(event) {
794
- const parts = [];
795
- if (event.type !== "generic") return "";
796
- const genericEvent = event;
797
- const occurrence = genericEvent.occurrence;
798
- if (!occurrence) return "";
799
- const evidenceData = occurrence.evidenceData;
800
- if (evidenceData) {
801
- parts.push("### Performance Regression Details");
802
- parts.push("");
803
- }
804
- if (occurrence.evidenceDisplay && occurrence.evidenceDisplay.length > 0) {
805
- for (const display of occurrence.evidenceDisplay) if (display.important) {
806
- parts.push(`**${display.name}:**`);
807
- parts.push(`${display.value}`);
808
- parts.push("");
809
- }
810
- }
811
- return parts.length > 0 ? `${parts.join("\n")}\n` : "";
812
- }
813
- function formatTags(tags) {
814
- if (!tags || tags.length === 0) return "";
815
- return `### Tags\n\n${tags.map((tag) => `**${tag.key}**: ${tag.value}`).join("\n")}\n\n`;
816
- }
817
- function formatContext(context) {
818
- if (!context || Object.keys(context).length === 0) return "";
819
- return `### Extra Data\n\nAdditional data attached to this event.\n\n${Object.entries(context).map(([key, value]) => {
820
- return `**${key}**: ${JSON.stringify(value, void 0, 2)}`;
821
- }).join("\n")}\n\n`;
822
- }
823
- function formatContexts(contexts) {
824
- if (!contexts || Object.keys(contexts).length === 0) return "";
825
- return `### Additional Context\n\nThese are additional context provided by the user when they're instrumenting their application.\n\n${Object.entries(contexts).map(([name, data]) => `**${name}**\n${Object.entries(data).filter(([key, _]) => key !== "type").map(([key, value]) => {
826
- return `${key}: ${JSON.stringify(value, void 0, 2)}`;
827
- }).join("\n")}`).join("\n\n")}\n\n`;
828
- }
829
- /**
830
- * Formats a brief Seer analysis summary for inclusion in issue details.
831
- * Shows current status and high-level insights, prompting to use analyze_issue_with_seer for full details.
832
- *
833
- * @param autofixState - The autofix state containing Seer analysis data
834
- * @param organizationSlug - The organization slug for the issue
835
- * @param issueId - The issue ID (shortId)
836
- * @returns Formatted markdown string with Seer summary, or empty string if no analysis exists
837
- */
838
- function formatSeerSummary(autofixState, organizationSlug, issueId) {
839
- if (!autofixState || !autofixState.autofix) return "";
840
- const { autofix } = autofixState;
841
- const parts = [];
842
- parts.push("## Seer Analysis");
843
- parts.push("");
844
- const statusDisplay = require_seer.getStatusDisplayName(autofix.status);
845
- if (!require_seer.isTerminalStatus(autofix.status)) {
846
- parts.push(`**Status:** ${statusDisplay}`);
847
- parts.push("");
848
- }
849
- if (autofix.steps.length > 0) {
850
- const completedSteps = autofix.steps.filter((step) => step.status === "COMPLETED");
851
- const solutionStep = completedSteps.find((step) => step.type === "solution");
852
- if (solutionStep) {
853
- const solutionDescription = solutionStep.description;
854
- if (solutionDescription && typeof solutionDescription === "string" && solutionDescription.trim()) {
855
- parts.push("**Summary:**");
856
- parts.push(solutionDescription.trim());
857
- } else {
858
- const solutionOutput = require_seer.getOutputForAutofixStep(solutionStep);
859
- const lines = solutionOutput.split("\n");
860
- const firstParagraph = lines.find((line) => line.trim().length > 50 && !line.startsWith("#") && !line.startsWith("*"));
861
- if (firstParagraph) {
862
- parts.push("**Summary:**");
863
- parts.push(firstParagraph.trim());
864
- }
865
- }
866
- } else if (completedSteps.length > 0) {
867
- const rootCauseStep = completedSteps.find((step) => step.type === "root_cause_analysis");
868
- if (rootCauseStep) {
869
- const typedStep = rootCauseStep;
870
- if (typedStep.causes && typedStep.causes.length > 0 && typedStep.causes[0].description) {
871
- parts.push("**Root Cause Identified:**");
872
- parts.push(typedStep.causes[0].description.trim());
873
- }
874
- } else parts.push(`**Progress:** ${completedSteps.length} of ${autofix.steps.length} steps completed`);
875
- }
876
- } else if (require_seer.isTerminalStatus(autofix.status)) {
877
- if (autofix.status === "FAILED" || autofix.status === "ERROR") parts.push("**Status:** Analysis failed.");
878
- else if (autofix.status === "CANCELLED") parts.push("**Status:** Analysis was cancelled.");
879
- else if (autofix.status === "NEED_MORE_INFORMATION" || autofix.status === "WAITING_FOR_USER_RESPONSE") parts.push("**Status:** Analysis paused - additional information needed.");
880
- } else parts.push("Analysis has started but no results yet.");
881
- if (autofix.steps.length > 0 && require_seer.isTerminalStatus(autofix.status)) {
882
- if (autofix.status === "FAILED" || autofix.status === "ERROR") {
883
- parts.push("");
884
- parts.push("**Status:** Analysis failed.");
885
- } else if (autofix.status === "CANCELLED") {
886
- parts.push("");
887
- parts.push("**Status:** Analysis was cancelled.");
888
- } else if (autofix.status === "NEED_MORE_INFORMATION" || autofix.status === "WAITING_FOR_USER_RESPONSE") {
889
- parts.push("");
890
- parts.push("**Status:** Analysis paused - additional information needed.");
891
- }
892
- }
893
- parts.push("");
894
- parts.push(`**Note:** For detailed root cause analysis and solutions, call \`analyze_issue_with_seer(organizationSlug='${organizationSlug}', issueId='${issueId}')\``);
895
- return `${parts.join("\n")}\n\n`;
896
- }
897
- /**
898
- * Formats a Sentry issue with its latest event into comprehensive markdown output.
899
- * Includes issue metadata, event details, and usage instructions.
900
- *
901
- * @param params - Object containing organization slug, issue, event, and API service
902
- * @returns Formatted markdown string with complete issue information
903
- */
904
- function formatIssueOutput({ organizationSlug, issue, event, apiService, autofixState, performanceTrace }) {
905
- let output = `# Issue ${issue.shortId} in **${organizationSlug}**\n\n`;
906
- const isPerformanceIssue = issue.issueType?.startsWith("performance_") || issue.issueCategory === "performance";
907
- if (isPerformanceIssue && issue.metadata) {
908
- const issueTitle = issue.metadata.title || issue.title;
909
- output += `**Description**: ${issueTitle}\n`;
910
- if (issue.metadata.location) output += `**Location**: ${issue.metadata.location}\n`;
911
- if (issue.metadata.value) output += `**Query Pattern**: \`${issue.metadata.value}\`\n`;
912
- } else {
913
- output += `**Description**: ${issue.title}\n`;
914
- output += `**Culprit**: ${issue.culprit}\n`;
915
- }
916
- output += `**First Seen**: ${new Date(issue.firstSeen).toISOString()}\n`;
917
- output += `**Last Seen**: ${new Date(issue.lastSeen).toISOString()}\n`;
918
- output += `**Occurrences**: ${issue.count}\n`;
919
- output += `**Users Impacted**: ${issue.userCount}\n`;
920
- output += `**Status**: ${issue.status}\n`;
921
- if (issue.substatus) output += `**Substatus**: ${issue.substatus}\n`;
922
- if (issue.issueType) output += `**Issue Type**: ${issue.issueType}\n`;
923
- if (issue.issueCategory) output += `**Issue Category**: ${issue.issueCategory}\n`;
924
- output += `**Platform**: ${issue.platform}\n`;
925
- output += `**Project**: ${issue.project.name}\n`;
926
- output += `**URL**: ${apiService.getIssueUrl(organizationSlug, issue.shortId)}\n`;
927
- output += "\n";
928
- output += "## Event Details\n\n";
929
- const eventType = event.type;
930
- const isUnsupportedType = eventType !== "error" && eventType !== "default" && eventType !== "transaction" && eventType !== "generic" && eventType !== "csp";
931
- if (isUnsupportedType) {
932
- const sentryEventId = require_logging.logIssue(`Unsupported event type encountered: ${String(eventType)}`, { contexts: { event: {
933
- event_id: event.id,
934
- event_type: eventType,
935
- issue_id: issue.id,
936
- issue_short_id: issue.shortId,
937
- organization_slug: organizationSlug,
938
- project_slug: issue.project.slug
939
- } } });
940
- output += `⚠️ **Warning**: Unsupported event type "${String(eventType)}"\n\n`;
941
- output += "This event type is not yet fully supported by the MCP server. ";
942
- output += "Only basic issue information is shown above.\n\n";
943
- output += "**Please report this**: Open a GitHub issue at https://github.com/getsentry/sentry-mcp/issues/new ";
944
- output += `and include Event ID **${event.id}**`;
945
- if (sentryEventId) output += ` and Sentry Event ID **${sentryEventId}**`;
946
- output += " to help us add support for this event type.\n";
947
- return output;
948
- }
949
- output += `**Event ID**: ${event.id}\n`;
950
- output += `**Type**: ${event.type}\n`;
951
- if (event.type === "error" || event.type === "default" || event.type === "generic" || event.type === "csp") {
952
- const typedEvent = event;
953
- if (typedEvent.dateCreated) output += `**Occurred At**: ${new Date(typedEvent.dateCreated).toISOString()}\n`;
954
- }
955
- if (event.message) output += `**Message**:\n${event.message}\n`;
956
- output += "\n";
957
- output += formatEventOutput(event, { performanceTrace });
958
- if (autofixState) output += formatSeerSummary(autofixState, organizationSlug, issue.shortId);
959
- output += "# Using this information\n\n";
960
- output += `- You can reference the IssueID in commit messages (e.g. \`Fixes ${issue.shortId}\`) to automatically close the issue when the commit is merged.\n`;
961
- output += "- The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.\n";
962
- return output;
963
- }
964
-
965
- //#endregion
966
- Object.defineProperty(exports, 'formatEventOutput', {
967
- enumerable: true,
968
- get: function () {
969
- return formatEventOutput;
970
- }
971
- });
972
- Object.defineProperty(exports, 'formatFrameHeader', {
973
- enumerable: true,
974
- get: function () {
975
- return formatFrameHeader;
976
- }
977
- });
978
- Object.defineProperty(exports, 'formatIssueOutput', {
979
- enumerable: true,
980
- get: function () {
981
- return formatIssueOutput;
982
- }
983
- });
984
- //# sourceMappingURL=formatting-BatGC-29.cjs.map