@sentry/mcp-server 0.11.0 → 0.13.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 (581) hide show
  1. package/README.md +4 -2
  2. package/dist/analyze-issue-with-seer-Bq3kefOr.cjs +169 -0
  3. package/dist/analyze-issue-with-seer-Bq3kefOr.cjs.map +1 -0
  4. package/dist/analyze-issue-with-seer-Dk0ZFwN8.js +163 -0
  5. package/dist/analyze-issue-with-seer-Dk0ZFwN8.js.map +1 -0
  6. package/dist/api-client/client.cjs +2 -2
  7. package/dist/api-client/client.d.cts +3 -3
  8. package/dist/api-client/client.d.ts +3 -3
  9. package/dist/api-client/client.js +2 -2
  10. package/dist/api-client/index.cjs +10 -2
  11. package/dist/api-client/index.d.cts +4 -4
  12. package/dist/api-client/index.d.ts +5 -5
  13. package/dist/api-client/index.js +5 -5
  14. package/dist/api-client/schema.cjs +9 -1
  15. package/dist/api-client/schema.d.cts +2 -2
  16. package/dist/api-client/schema.d.ts +2 -2
  17. package/dist/api-client/schema.js +2 -2
  18. package/dist/api-client/types.d.cts +3 -3
  19. package/dist/api-client/types.d.ts +3 -3
  20. package/dist/api-client/types.js +1 -1
  21. package/dist/api-utils-BJS0CChW.cjs +36 -0
  22. package/dist/api-utils-BJS0CChW.cjs.map +1 -0
  23. package/dist/api-utils-BcB1cMXS.js +31 -0
  24. package/dist/api-utils-BcB1cMXS.js.map +1 -0
  25. package/dist/client-BNTsOycD.cjs +620 -0
  26. package/dist/client-BNTsOycD.cjs.map +1 -0
  27. package/dist/client-BbamPqV4.js +609 -0
  28. package/dist/client-BbamPqV4.js.map +1 -0
  29. package/dist/client-Dae1ZwWb.d.cts +556 -0
  30. package/dist/client-Dae1ZwWb.d.cts.map +1 -0
  31. package/dist/client-qyEu8fvj.d.ts +556 -0
  32. package/dist/client-qyEu8fvj.d.ts.map +1 -0
  33. package/dist/constants-ClkMK29-.cjs +182 -0
  34. package/dist/constants-ClkMK29-.cjs.map +1 -0
  35. package/dist/constants-S7AU45oQ.js +164 -0
  36. package/dist/constants-S7AU45oQ.js.map +1 -0
  37. package/dist/constants.cjs +5 -0
  38. package/dist/constants.d.cts +23 -0
  39. package/dist/constants.d.cts.map +1 -0
  40. package/dist/constants.d.ts +23 -0
  41. package/dist/constants.d.ts.map +1 -0
  42. package/dist/constants.js +3 -0
  43. package/dist/create-dsn-B3L8iWno.js +59 -0
  44. package/dist/create-dsn-B3L8iWno.js.map +1 -0
  45. package/dist/create-dsn-CVPtt_Es.cjs +65 -0
  46. package/dist/create-dsn-CVPtt_Es.cjs.map +1 -0
  47. package/dist/create-project-B_6a6okf.cjs +82 -0
  48. package/dist/create-project-B_6a6okf.cjs.map +1 -0
  49. package/dist/create-project-DdIXMvWI.js +76 -0
  50. package/dist/create-project-DdIXMvWI.js.map +1 -0
  51. package/dist/create-team-BarRdaZK.js +47 -0
  52. package/dist/create-team-BarRdaZK.js.map +1 -0
  53. package/dist/create-team-C1DP5Z1r.cjs +53 -0
  54. package/dist/create-team-C1DP5Z1r.cjs.map +1 -0
  55. package/dist/defineTool-77H4nSna.js +8 -0
  56. package/dist/defineTool-77H4nSna.js.map +1 -0
  57. package/dist/defineTool-lWNTzWl_.cjs +14 -0
  58. package/dist/defineTool-lWNTzWl_.cjs.map +1 -0
  59. package/dist/{errors-BJSrT6Ou.js → errors-CIoxzIug.js} +1 -1
  60. package/dist/{errors-BJSrT6Ou.js.map → errors-CIoxzIug.js.map} +1 -1
  61. package/dist/{errors-B9fwS-aP.cjs → errors-YmiXLOyx.cjs} +1 -1
  62. package/dist/{errors-B9fwS-aP.cjs.map → errors-YmiXLOyx.cjs.map} +1 -1
  63. package/dist/errors.cjs +1 -1
  64. package/dist/errors.js +1 -1
  65. package/dist/fetch-utils-B-a92ObC.d.ts +14 -0
  66. package/dist/fetch-utils-B-a92ObC.d.ts.map +1 -0
  67. package/dist/fetch-utils-BMKjO-cc.js +29 -0
  68. package/dist/fetch-utils-BMKjO-cc.js.map +1 -0
  69. package/dist/fetch-utils-DlPjrSk2.js +0 -0
  70. package/dist/fetch-utils-DzdRW4Yd.d.cts +14 -0
  71. package/dist/fetch-utils-DzdRW4Yd.d.cts.map +1 -0
  72. package/dist/fetch-utils-oab6uNp3.cjs +35 -0
  73. package/dist/fetch-utils-oab6uNp3.cjs.map +1 -0
  74. package/dist/find-dsns-BDJWY6nZ.cjs +58 -0
  75. package/dist/find-dsns-BDJWY6nZ.cjs.map +1 -0
  76. package/dist/find-dsns-BPbblgrn.js +52 -0
  77. package/dist/find-dsns-BPbblgrn.js.map +1 -0
  78. package/dist/find-errors-B9wLxXA0.js +91 -0
  79. package/dist/find-errors-B9wLxXA0.js.map +1 -0
  80. package/dist/find-errors-DnFs3PaH.cjs +97 -0
  81. package/dist/find-errors-DnFs3PaH.cjs.map +1 -0
  82. package/dist/find-issues-BI1tI3cJ.js +92 -0
  83. package/dist/find-issues-BI1tI3cJ.js.map +1 -0
  84. package/dist/find-issues-CwPbwRXK.cjs +98 -0
  85. package/dist/find-issues-CwPbwRXK.cjs.map +1 -0
  86. package/dist/find-organizations-CdiouW48.js +45 -0
  87. package/dist/find-organizations-CdiouW48.js.map +1 -0
  88. package/dist/find-organizations-DqS6zoTK.cjs +50 -0
  89. package/dist/find-organizations-DqS6zoTK.cjs.map +1 -0
  90. package/dist/find-projects-Ba6cdX7n.cjs +45 -0
  91. package/dist/find-projects-Ba6cdX7n.cjs.map +1 -0
  92. package/dist/find-projects-Ccfxv47h.js +39 -0
  93. package/dist/find-projects-Ccfxv47h.js.map +1 -0
  94. package/dist/find-releases-CFl86XMT.cjs +99 -0
  95. package/dist/find-releases-CFl86XMT.cjs.map +1 -0
  96. package/dist/find-releases-CFoGytN-.js +93 -0
  97. package/dist/find-releases-CFoGytN-.js.map +1 -0
  98. package/dist/find-tags-ORtYLH5b.js +39 -0
  99. package/dist/find-tags-ORtYLH5b.js.map +1 -0
  100. package/dist/find-tags-h2o0BKWO.cjs +45 -0
  101. package/dist/find-tags-h2o0BKWO.cjs.map +1 -0
  102. package/dist/find-teams-DUcDfSOl.cjs +45 -0
  103. package/dist/find-teams-DUcDfSOl.cjs.map +1 -0
  104. package/dist/find-teams-hreVp1nw.js +39 -0
  105. package/dist/find-teams-hreVp1nw.js.map +1 -0
  106. package/dist/find-transactions-BehUqQYs.js +83 -0
  107. package/dist/find-transactions-BehUqQYs.js.map +1 -0
  108. package/dist/find-transactions-BkPscam3.cjs +89 -0
  109. package/dist/find-transactions-BkPscam3.cjs.map +1 -0
  110. package/dist/formatting-B-u5CbYn.d.ts +47 -0
  111. package/dist/formatting-B-u5CbYn.d.ts.map +1 -0
  112. package/dist/formatting-BlMiQa9i.cjs +388 -0
  113. package/dist/formatting-BlMiQa9i.cjs.map +1 -0
  114. package/dist/formatting-Di1X9Jn3.d.cts +47 -0
  115. package/dist/formatting-Di1X9Jn3.d.cts.map +1 -0
  116. package/dist/formatting-pUm38KOj.js +370 -0
  117. package/dist/formatting-pUm38KOj.js.map +1 -0
  118. package/dist/formatting-utils-C3sej5ER.js +14 -0
  119. package/dist/formatting-utils-C3sej5ER.js.map +1 -0
  120. package/dist/formatting-utils-DDz14xeB.cjs +20 -0
  121. package/dist/formatting-utils-DDz14xeB.cjs.map +1 -0
  122. package/dist/get-doc-AuAW_qr9.cjs +86 -0
  123. package/dist/get-doc-AuAW_qr9.cjs.map +1 -0
  124. package/dist/get-doc-BtxZOy7y.js +80 -0
  125. package/dist/get-doc-BtxZOy7y.js.map +1 -0
  126. package/dist/get-event-attachment-Bq5lkaKV.cjs +144 -0
  127. package/dist/get-event-attachment-Bq5lkaKV.cjs.map +1 -0
  128. package/dist/get-event-attachment-DwAl54zv.js +138 -0
  129. package/dist/get-event-attachment-DwAl54zv.js.map +1 -0
  130. package/dist/get-issue-details-DrpD5LlK.js +104 -0
  131. package/dist/get-issue-details-DrpD5LlK.js.map +1 -0
  132. package/dist/get-issue-details-qGwu18JX.cjs +110 -0
  133. package/dist/get-issue-details-qGwu18JX.cjs.map +1 -0
  134. package/dist/index.cjs +60 -21
  135. package/dist/index.cjs.map +1 -1
  136. package/dist/index.js +62 -23
  137. package/dist/index.js.map +1 -1
  138. package/dist/internal/fetch-utils.cjs +3 -0
  139. package/dist/internal/fetch-utils.d.cts +2 -0
  140. package/dist/internal/fetch-utils.d.ts +2 -0
  141. package/dist/internal/fetch-utils.js +3 -0
  142. package/dist/internal/formatting.cjs +1 -1
  143. package/dist/internal/formatting.d.cts +5 -24
  144. package/dist/internal/formatting.d.ts +6 -25
  145. package/dist/internal/formatting.js +1 -1
  146. package/dist/internal/issue-helpers.cjs +1 -1
  147. package/dist/internal/issue-helpers.d.cts +2 -44
  148. package/dist/internal/issue-helpers.d.ts +2 -44
  149. package/dist/internal/issue-helpers.js +1 -1
  150. package/dist/internal/test-fixtures.cjs +214 -0
  151. package/dist/internal/test-fixtures.cjs.map +1 -0
  152. package/dist/internal/test-fixtures.d.cts +2138 -0
  153. package/dist/internal/test-fixtures.d.cts.map +1 -0
  154. package/dist/internal/test-fixtures.d.ts +2138 -0
  155. package/dist/internal/test-fixtures.d.ts.map +1 -0
  156. package/dist/internal/test-fixtures.js +205 -0
  157. package/dist/internal/test-fixtures.js.map +1 -0
  158. package/dist/issue-helpers-BOn4g7rx.d.ts +52 -0
  159. package/dist/issue-helpers-BOn4g7rx.d.ts.map +1 -0
  160. package/dist/{issue-helpers-CSNNO03f.js → issue-helpers-CqqYnwYE.js} +9 -1
  161. package/dist/issue-helpers-CqqYnwYE.js.map +1 -0
  162. package/dist/issue-helpers-Cz01Ipvl.d.cts +52 -0
  163. package/dist/issue-helpers-Cz01Ipvl.d.cts.map +1 -0
  164. package/dist/{issue-helpers-71XgJVXC.cjs → issue-helpers-DyAIO0w6.cjs} +9 -1
  165. package/dist/issue-helpers-DyAIO0w6.cjs.map +1 -0
  166. package/dist/issue-utils-BVAB6I-Z.js +0 -0
  167. package/dist/issue-utils-pdbo-5LW.cjs +0 -0
  168. package/dist/{logging-CXLD0FFB.js → logging-LnQMFw-_.js} +1 -1
  169. package/dist/logging-LnQMFw-_.js.map +1 -0
  170. package/dist/{logging-ByvSjT6V.cjs → logging-oIouXrcb.cjs} +1 -1
  171. package/dist/logging-oIouXrcb.cjs.map +1 -0
  172. package/dist/logging.cjs +1 -1
  173. package/dist/logging.d.cts +30 -1
  174. package/dist/logging.d.cts.map +1 -1
  175. package/dist/logging.d.ts +30 -1
  176. package/dist/logging.d.ts.map +1 -1
  177. package/dist/logging.js +1 -1
  178. package/dist/{promptDefinitions-H0q1_X-K.d.ts → promptDefinitions-6xelipaz.d.ts} +11 -3
  179. package/dist/promptDefinitions-6xelipaz.d.ts.map +1 -0
  180. package/dist/{promptDefinitions-D3ll3qCd.cjs → promptDefinitions-C29BWGYg.cjs} +11 -4
  181. package/dist/promptDefinitions-C29BWGYg.cjs.map +1 -0
  182. package/dist/{promptDefinitions-aKmUZWWO.js → promptDefinitions-CSKE8T0a.js} +11 -4
  183. package/dist/promptDefinitions-CSKE8T0a.js.map +1 -0
  184. package/dist/{promptDefinitions-DMucOchd.d.cts → promptDefinitions-CVHtYaj8.d.cts} +11 -3
  185. package/dist/promptDefinitions-CVHtYaj8.d.cts.map +1 -0
  186. package/dist/promptDefinitions.cjs +3 -2
  187. package/dist/promptDefinitions.d.cts +1 -1
  188. package/dist/promptDefinitions.d.ts +1 -1
  189. package/dist/promptDefinitions.js +3 -2
  190. package/dist/{prompts-CzD0yl7Z.js → prompts-C8Y9w5c4.js} +9 -7
  191. package/dist/prompts-C8Y9w5c4.js.map +1 -0
  192. package/dist/{prompts-DMwoay8l.cjs → prompts-Df3i1XSB.cjs} +8 -7
  193. package/dist/prompts-Df3i1XSB.cjs.map +1 -0
  194. package/dist/prompts.cjs +2 -1
  195. package/dist/prompts.d.cts +4 -5
  196. package/dist/prompts.d.cts.map +1 -1
  197. package/dist/prompts.d.ts +4 -5
  198. package/dist/prompts.d.ts.map +1 -1
  199. package/dist/prompts.js +2 -1
  200. package/dist/resources-BHF8a1ZB.js +92 -0
  201. package/dist/resources-BHF8a1ZB.js.map +1 -0
  202. package/dist/resources-BM_YQGcb.cjs +104 -0
  203. package/dist/resources-BM_YQGcb.cjs.map +1 -0
  204. package/dist/resources.cjs +5 -2
  205. package/dist/resources.d.cts +30 -7
  206. package/dist/resources.d.cts.map +1 -1
  207. package/dist/resources.d.ts +30 -7
  208. package/dist/resources.d.ts.map +1 -1
  209. package/dist/resources.js +4 -2
  210. package/dist/{schema-DqxkW9Tx.d.cts → schema-B5BpplNK.d.ts} +3746 -575
  211. package/dist/schema-B5BpplNK.d.ts.map +1 -0
  212. package/dist/{schema-DkyWSqp_.cjs → schema-B_cMyyJJ.cjs} +130 -13
  213. package/dist/schema-B_cMyyJJ.cjs.map +1 -0
  214. package/dist/{schema-B8lT632E.cjs → schema-BpJVmev8.cjs} +51 -2
  215. package/dist/schema-BpJVmev8.cjs.map +1 -0
  216. package/dist/{schema-C-MLkWMc.d.ts → schema-Dt-HKnd_.d.cts} +3674 -503
  217. package/dist/schema-Dt-HKnd_.d.cts.map +1 -0
  218. package/dist/schema-DtsnsxMl.js +36 -0
  219. package/dist/schema-DtsnsxMl.js.map +1 -0
  220. package/dist/{schema-CewAKS9A.js → schema-WDk5Yqww.js} +83 -14
  221. package/dist/schema-WDk5Yqww.js.map +1 -0
  222. package/dist/schema.cjs +7 -1
  223. package/dist/schema.d.cts +16 -3
  224. package/dist/schema.d.cts.map +1 -1
  225. package/dist/schema.d.ts +16 -3
  226. package/dist/schema.d.ts.map +1 -1
  227. package/dist/schema.js +3 -2
  228. package/dist/search-docs-CrMdRDJy.js +102 -0
  229. package/dist/search-docs-CrMdRDJy.js.map +1 -0
  230. package/dist/search-docs-VhefTOOH.cjs +108 -0
  231. package/dist/search-docs-VhefTOOH.cjs.map +1 -0
  232. package/dist/seer-utils-Ckr8nYlz.js +87 -0
  233. package/dist/seer-utils-Ckr8nYlz.js.map +1 -0
  234. package/dist/seer-utils-CzYEEZb2.cjs +129 -0
  235. package/dist/seer-utils-CzYEEZb2.cjs.map +1 -0
  236. package/dist/server-CHG27fcn.cjs +243 -0
  237. package/dist/server-CHG27fcn.cjs.map +1 -0
  238. package/dist/server-DeuBftc5.js +237 -0
  239. package/dist/server-DeuBftc5.js.map +1 -0
  240. package/dist/server.cjs +40 -13
  241. package/dist/server.d.cts +22 -4
  242. package/dist/server.d.cts.map +1 -1
  243. package/dist/server.d.ts +22 -4
  244. package/dist/server.d.ts.map +1 -1
  245. package/dist/server.js +42 -15
  246. package/dist/stdio-BtVdTwx-.cjs +57 -0
  247. package/dist/stdio-BtVdTwx-.cjs.map +1 -0
  248. package/dist/stdio-DIuLW5EE.js +51 -0
  249. package/dist/stdio-DIuLW5EE.js.map +1 -0
  250. package/dist/test-setup.cjs +1763 -1410
  251. package/dist/test-setup.cjs.map +1 -1
  252. package/dist/test-setup.js +1581 -1201
  253. package/dist/test-setup.js.map +1 -1
  254. package/dist/toolDefinitions.d.ts +25 -2
  255. package/dist/toolDefinitions.js +1059 -4
  256. package/dist/tools/analyze-issue-with-seer.cjs +16 -0
  257. package/dist/tools/analyze-issue-with-seer.d.cts +16 -0
  258. package/dist/tools/analyze-issue-with-seer.d.cts.map +1 -0
  259. package/dist/tools/analyze-issue-with-seer.d.ts +16 -0
  260. package/dist/tools/analyze-issue-with-seer.d.ts.map +1 -0
  261. package/dist/tools/analyze-issue-with-seer.js +16 -0
  262. package/dist/tools/create-dsn.cjs +12 -0
  263. package/dist/tools/create-dsn.d.cts +15 -0
  264. package/dist/tools/create-dsn.d.cts.map +1 -0
  265. package/dist/tools/create-dsn.d.ts +15 -0
  266. package/dist/tools/create-dsn.d.ts.map +1 -0
  267. package/dist/tools/create-dsn.js +12 -0
  268. package/dist/tools/create-project.cjs +13 -0
  269. package/dist/tools/create-project.d.cts +16 -0
  270. package/dist/tools/create-project.d.cts.map +1 -0
  271. package/dist/tools/create-project.d.ts +16 -0
  272. package/dist/tools/create-project.d.ts.map +1 -0
  273. package/dist/tools/create-project.js +13 -0
  274. package/dist/tools/create-team.cjs +12 -0
  275. package/dist/tools/create-team.d.cts +14 -0
  276. package/dist/tools/create-team.d.cts.map +1 -0
  277. package/dist/tools/create-team.d.ts +14 -0
  278. package/dist/tools/create-team.d.ts.map +1 -0
  279. package/dist/tools/create-team.js +12 -0
  280. package/dist/tools/find-dsns.cjs +12 -0
  281. package/dist/tools/find-dsns.d.cts +14 -0
  282. package/dist/tools/find-dsns.d.cts.map +1 -0
  283. package/dist/tools/find-dsns.d.ts +14 -0
  284. package/dist/tools/find-dsns.d.ts.map +1 -0
  285. package/dist/tools/find-dsns.js +12 -0
  286. package/dist/tools/find-errors.cjs +12 -0
  287. package/dist/tools/find-errors.d.cts +18 -0
  288. package/dist/tools/find-errors.d.cts.map +1 -0
  289. package/dist/tools/find-errors.d.ts +18 -0
  290. package/dist/tools/find-errors.d.ts.map +1 -0
  291. package/dist/tools/find-errors.js +12 -0
  292. package/dist/tools/find-issues.cjs +12 -0
  293. package/dist/tools/find-issues.d.cts +16 -0
  294. package/dist/tools/find-issues.d.cts.map +1 -0
  295. package/dist/tools/find-issues.d.ts +16 -0
  296. package/dist/tools/find-issues.d.ts.map +1 -0
  297. package/dist/tools/find-issues.js +12 -0
  298. package/dist/tools/find-organizations.cjs +10 -0
  299. package/dist/tools/find-organizations.d.cts +9 -0
  300. package/dist/tools/find-organizations.d.cts.map +1 -0
  301. package/dist/tools/find-organizations.d.ts +9 -0
  302. package/dist/tools/find-organizations.d.ts.map +1 -0
  303. package/dist/tools/find-organizations.js +10 -0
  304. package/dist/tools/find-projects.cjs +12 -0
  305. package/dist/tools/find-projects.d.cts +13 -0
  306. package/dist/tools/find-projects.d.cts.map +1 -0
  307. package/dist/tools/find-projects.d.ts +13 -0
  308. package/dist/tools/find-projects.d.ts.map +1 -0
  309. package/dist/tools/find-projects.js +12 -0
  310. package/dist/tools/find-releases.cjs +12 -0
  311. package/dist/tools/find-releases.d.cts +15 -0
  312. package/dist/tools/find-releases.d.cts.map +1 -0
  313. package/dist/tools/find-releases.d.ts +15 -0
  314. package/dist/tools/find-releases.d.ts.map +1 -0
  315. package/dist/tools/find-releases.js +12 -0
  316. package/dist/tools/find-tags.cjs +12 -0
  317. package/dist/tools/find-tags.d.cts +13 -0
  318. package/dist/tools/find-tags.d.cts.map +1 -0
  319. package/dist/tools/find-tags.d.ts +13 -0
  320. package/dist/tools/find-tags.d.ts.map +1 -0
  321. package/dist/tools/find-tags.js +12 -0
  322. package/dist/tools/find-teams.cjs +12 -0
  323. package/dist/tools/find-teams.d.cts +13 -0
  324. package/dist/tools/find-teams.d.cts.map +1 -0
  325. package/dist/tools/find-teams.d.ts +13 -0
  326. package/dist/tools/find-teams.d.ts.map +1 -0
  327. package/dist/tools/find-teams.js +12 -0
  328. package/dist/tools/find-transactions.cjs +12 -0
  329. package/dist/tools/find-transactions.d.cts +17 -0
  330. package/dist/tools/find-transactions.d.cts.map +1 -0
  331. package/dist/tools/find-transactions.d.ts +17 -0
  332. package/dist/tools/find-transactions.d.ts.map +1 -0
  333. package/dist/tools/find-transactions.js +12 -0
  334. package/dist/tools/get-doc.cjs +11 -0
  335. package/dist/tools/get-doc.d.cts +12 -0
  336. package/dist/tools/get-doc.d.cts.map +1 -0
  337. package/dist/tools/get-doc.d.ts +12 -0
  338. package/dist/tools/get-doc.d.ts.map +1 -0
  339. package/dist/tools/get-doc.js +11 -0
  340. package/dist/tools/get-event-attachment.cjs +12 -0
  341. package/dist/tools/get-event-attachment.d.cts +16 -0
  342. package/dist/tools/get-event-attachment.d.cts.map +1 -0
  343. package/dist/tools/get-event-attachment.d.ts +16 -0
  344. package/dist/tools/get-event-attachment.d.ts.map +1 -0
  345. package/dist/tools/get-event-attachment.js +12 -0
  346. package/dist/tools/get-issue-details.cjs +15 -0
  347. package/dist/tools/get-issue-details.d.cts +16 -0
  348. package/dist/tools/get-issue-details.d.cts.map +1 -0
  349. package/dist/tools/get-issue-details.d.ts +16 -0
  350. package/dist/tools/get-issue-details.d.ts.map +1 -0
  351. package/dist/tools/get-issue-details.js +15 -0
  352. package/dist/tools/index.cjs +40 -0
  353. package/dist/tools/index.d.cts +127 -0
  354. package/dist/tools/index.d.cts.map +1 -0
  355. package/dist/tools/index.d.ts +127 -0
  356. package/dist/tools/index.d.ts.map +1 -0
  357. package/dist/tools/index.js +40 -0
  358. package/dist/tools/search-docs.cjs +12 -0
  359. package/dist/tools/search-docs.d.cts +14 -0
  360. package/dist/tools/search-docs.d.cts.map +1 -0
  361. package/dist/tools/search-docs.d.ts +14 -0
  362. package/dist/tools/search-docs.d.ts.map +1 -0
  363. package/dist/tools/search-docs.js +12 -0
  364. package/dist/tools/types.cjs +0 -0
  365. package/dist/tools/types.d.cts +4 -0
  366. package/dist/tools/types.d.ts +4 -0
  367. package/dist/tools/types.js +0 -0
  368. package/dist/tools/update-issue.cjs +16 -0
  369. package/dist/tools/update-issue.d.cts +17 -0
  370. package/dist/tools/update-issue.d.cts.map +1 -0
  371. package/dist/tools/update-issue.d.ts +17 -0
  372. package/dist/tools/update-issue.d.ts.map +1 -0
  373. package/dist/tools/update-issue.js +16 -0
  374. package/dist/tools/update-project.cjs +13 -0
  375. package/dist/tools/update-project.d.cts +18 -0
  376. package/dist/tools/update-project.d.cts.map +1 -0
  377. package/dist/tools/update-project.d.ts +18 -0
  378. package/dist/tools/update-project.d.ts.map +1 -0
  379. package/dist/tools/update-project.js +13 -0
  380. package/dist/tools/utils/api-utils.cjs +8 -0
  381. package/dist/tools/utils/api-utils.d.cts +24 -0
  382. package/dist/tools/utils/api-utils.d.cts.map +1 -0
  383. package/dist/tools/utils/api-utils.d.ts +24 -0
  384. package/dist/tools/utils/api-utils.d.ts.map +1 -0
  385. package/dist/tools/utils/api-utils.js +8 -0
  386. package/dist/tools/utils/defineTool.cjs +3 -0
  387. package/dist/tools/utils/defineTool.d.cts +12 -0
  388. package/dist/tools/utils/defineTool.d.cts.map +1 -0
  389. package/dist/tools/utils/defineTool.d.ts +12 -0
  390. package/dist/tools/utils/defineTool.d.ts.map +1 -0
  391. package/dist/tools/utils/defineTool.js +3 -0
  392. package/dist/tools/utils/fetch-utils.cjs +4 -0
  393. package/dist/tools/utils/fetch-utils.d.cts +2 -0
  394. package/dist/tools/utils/fetch-utils.d.ts +2 -0
  395. package/dist/tools/utils/fetch-utils.js +4 -0
  396. package/dist/tools/utils/formatting-utils.cjs +3 -0
  397. package/dist/tools/utils/formatting-utils.d.cts +15 -0
  398. package/dist/tools/utils/formatting-utils.d.cts.map +1 -0
  399. package/dist/tools/utils/formatting-utils.d.ts +15 -0
  400. package/dist/tools/utils/formatting-utils.d.ts.map +1 -0
  401. package/dist/tools/utils/formatting-utils.js +3 -0
  402. package/dist/tools/utils/issue-utils.cjs +6 -0
  403. package/dist/tools/utils/issue-utils.d.cts +7 -0
  404. package/dist/tools/utils/issue-utils.d.ts +7 -0
  405. package/dist/tools/utils/issue-utils.js +5 -0
  406. package/dist/tools/utils/seer-utils.cjs +9 -0
  407. package/dist/tools/utils/seer-utils.d.cts +28 -0
  408. package/dist/tools/utils/seer-utils.d.cts.map +1 -0
  409. package/dist/tools/utils/seer-utils.d.ts +28 -0
  410. package/dist/tools/utils/seer-utils.d.ts.map +1 -0
  411. package/dist/tools/utils/seer-utils.js +3 -0
  412. package/dist/tools/whoami.cjs +10 -0
  413. package/dist/tools/whoami.d.cts +9 -0
  414. package/dist/tools/whoami.d.cts.map +1 -0
  415. package/dist/tools/whoami.d.ts +9 -0
  416. package/dist/tools/whoami.d.ts.map +1 -0
  417. package/dist/tools/whoami.js +10 -0
  418. package/dist/tools-BiZ7ZDKf.cjs +53 -0
  419. package/dist/tools-BiZ7ZDKf.cjs.map +1 -0
  420. package/dist/tools-DGF9GhbP.js +48 -0
  421. package/dist/tools-DGF9GhbP.js.map +1 -0
  422. package/dist/transports/stdio.cjs +42 -14
  423. package/dist/transports/stdio.d.cts +25 -4
  424. package/dist/transports/stdio.d.cts.map +1 -1
  425. package/dist/transports/stdio.d.ts +25 -4
  426. package/dist/transports/stdio.d.ts.map +1 -1
  427. package/dist/transports/stdio.js +44 -16
  428. package/dist/types-B2qOfefC.d.ts +29 -0
  429. package/dist/types-B2qOfefC.d.ts.map +1 -0
  430. package/dist/{types-DuUmV9zh.d.ts → types-Br0saqtE.d.ts} +7 -3
  431. package/dist/types-Br0saqtE.d.ts.map +1 -0
  432. package/dist/{types-CcffrLXB.d.cts → types-C3pRFQyA.d.cts} +7 -3
  433. package/dist/types-C3pRFQyA.d.cts.map +1 -0
  434. package/dist/types-CCHsZshF.js +0 -0
  435. package/dist/types-CYjev2Ep.d.cts +29 -0
  436. package/dist/types-CYjev2Ep.d.cts.map +1 -0
  437. package/dist/types-CZaMk5Yg.d.cts +29 -0
  438. package/dist/types-CZaMk5Yg.d.cts.map +1 -0
  439. package/dist/types-D5KkaSjc.d.ts +29 -0
  440. package/dist/types-D5KkaSjc.d.ts.map +1 -0
  441. package/dist/types.d.cts +3 -4
  442. package/dist/types.d.ts +3 -4
  443. package/dist/update-issue-Bz-u_Yaa.cjs +115 -0
  444. package/dist/update-issue-Bz-u_Yaa.cjs.map +1 -0
  445. package/dist/update-issue-DN80uuKU.js +109 -0
  446. package/dist/update-issue-DN80uuKU.js.map +1 -0
  447. package/dist/update-project-5j-SOHWU.js +120 -0
  448. package/dist/update-project-5j-SOHWU.js.map +1 -0
  449. package/dist/update-project-C7Xbmhqg.cjs +126 -0
  450. package/dist/update-project-C7Xbmhqg.cjs.map +1 -0
  451. package/dist/version-DvMKCu-i.js +6 -0
  452. package/dist/version-DvMKCu-i.js.map +1 -0
  453. package/dist/{version-CRzAHHGZ.cjs → version-Dyz6_b54.cjs} +2 -2
  454. package/dist/version-Dyz6_b54.cjs.map +1 -0
  455. package/dist/version.cjs +1 -1
  456. package/dist/version.js +1 -1
  457. package/dist/whoami-qIbcECMA.cjs +28 -0
  458. package/dist/whoami-qIbcECMA.cjs.map +1 -0
  459. package/dist/whoami-raA70UBD.js +23 -0
  460. package/dist/whoami-raA70UBD.js.map +1 -0
  461. package/package.json +24 -14
  462. package/dist/api-client/client.test.cjs +0 -33
  463. package/dist/api-client/client.test.cjs.map +0 -1
  464. package/dist/api-client/client.test.d.ts +0 -1
  465. package/dist/api-client/client.test.js +0 -33
  466. package/dist/api-client/client.test.js.map +0 -1
  467. package/dist/chunk-BLXvPPr8.js +0 -30
  468. package/dist/client-Bxf4MxOz.d.cts +0 -179
  469. package/dist/client-Bxf4MxOz.d.cts.map +0 -1
  470. package/dist/client-D5xFZtxK.js +0 -224
  471. package/dist/client-D5xFZtxK.js.map +0 -1
  472. package/dist/client-DOhBiaMJ.d.ts +0 -179
  473. package/dist/client-DOhBiaMJ.d.ts.map +0 -1
  474. package/dist/client-GKHZSXgV.cjs +0 -235
  475. package/dist/client-GKHZSXgV.cjs.map +0 -1
  476. package/dist/dist-BlIWGSIM.cjs +0 -8197
  477. package/dist/dist-BlIWGSIM.cjs.map +0 -1
  478. package/dist/dist-DDpQABxe.js +0 -8054
  479. package/dist/dist-DDpQABxe.js.map +0 -1
  480. package/dist/errors.test.cjs +0 -24
  481. package/dist/errors.test.cjs.map +0 -1
  482. package/dist/errors.test.d.cts +0 -1
  483. package/dist/errors.test.d.ts +0 -1
  484. package/dist/errors.test.js +0 -24
  485. package/dist/errors.test.js.map +0 -1
  486. package/dist/formatting-BaARL2gT.js +0 -68
  487. package/dist/formatting-BaARL2gT.js.map +0 -1
  488. package/dist/formatting-C2kN0ok6.cjs +0 -86
  489. package/dist/formatting-C2kN0ok6.cjs.map +0 -1
  490. package/dist/index-h64gcVNJ.d.ts +0 -1
  491. package/dist/internal/formatting.d.cts.map +0 -1
  492. package/dist/internal/formatting.d.ts.map +0 -1
  493. package/dist/internal/issue-helpers.d.cts.map +0 -1
  494. package/dist/internal/issue-helpers.d.ts.map +0 -1
  495. package/dist/internal/issue-helpers.test.cjs +0 -110
  496. package/dist/internal/issue-helpers.test.cjs.map +0 -1
  497. package/dist/internal/issue-helpers.test.d.cts +0 -1
  498. package/dist/internal/issue-helpers.test.d.ts +0 -1
  499. package/dist/internal/issue-helpers.test.js +0 -110
  500. package/dist/internal/issue-helpers.test.js.map +0 -1
  501. package/dist/issue-helpers-71XgJVXC.cjs.map +0 -1
  502. package/dist/issue-helpers-CSNNO03f.js.map +0 -1
  503. package/dist/logging-ByvSjT6V.cjs.map +0 -1
  504. package/dist/logging-CXLD0FFB.js.map +0 -1
  505. package/dist/magic-string.es-CybcVAw7.cjs +0 -1016
  506. package/dist/magic-string.es-CybcVAw7.cjs.map +0 -1
  507. package/dist/magic-string.es-DY8GVHw9.js +0 -1015
  508. package/dist/magic-string.es-DY8GVHw9.js.map +0 -1
  509. package/dist/promptDefinitions-D3ll3qCd.cjs.map +0 -1
  510. package/dist/promptDefinitions-DMucOchd.d.cts.map +0 -1
  511. package/dist/promptDefinitions-H0q1_X-K.d.ts.map +0 -1
  512. package/dist/promptDefinitions-aKmUZWWO.js.map +0 -1
  513. package/dist/prompts-CzD0yl7Z.js.map +0 -1
  514. package/dist/prompts-DMwoay8l.cjs.map +0 -1
  515. package/dist/resources-D6TW2ER0.cjs +0 -32
  516. package/dist/resources-D6TW2ER0.cjs.map +0 -1
  517. package/dist/resources-x-GaokG8.js +0 -26
  518. package/dist/resources-x-GaokG8.js.map +0 -1
  519. package/dist/schema-B8lT632E.cjs.map +0 -1
  520. package/dist/schema-BkHf97d7.js +0 -17
  521. package/dist/schema-BkHf97d7.js.map +0 -1
  522. package/dist/schema-C-MLkWMc.d.ts.map +0 -1
  523. package/dist/schema-CewAKS9A.js.map +0 -1
  524. package/dist/schema-DkyWSqp_.cjs.map +0 -1
  525. package/dist/schema-DqxkW9Tx.d.cts.map +0 -1
  526. package/dist/server-pGtEIwE3.cjs +0 -148
  527. package/dist/server-pGtEIwE3.cjs.map +0 -1
  528. package/dist/server-qpWdf-ST.js +0 -142
  529. package/dist/server-qpWdf-ST.js.map +0 -1
  530. package/dist/stdio-D8u2W847.js +0 -19
  531. package/dist/stdio-D8u2W847.js.map +0 -1
  532. package/dist/stdio-DydB2Pxu.cjs +0 -25
  533. package/dist/stdio-DydB2Pxu.cjs.map +0 -1
  534. package/dist/toolDefinitions-BSC2D_S-.js +0 -430
  535. package/dist/toolDefinitions-BSC2D_S-.js.map +0 -1
  536. package/dist/toolDefinitions-BtHN8t_d.cjs +0 -436
  537. package/dist/toolDefinitions-BtHN8t_d.cjs.map +0 -1
  538. package/dist/toolDefinitions-Dp13BpEu.d.cts +0 -296
  539. package/dist/toolDefinitions-Dp13BpEu.d.cts.map +0 -1
  540. package/dist/toolDefinitions-fQrpWznJ.d.ts +0 -296
  541. package/dist/toolDefinitions-fQrpWznJ.d.ts.map +0 -1
  542. package/dist/toolDefinitions.cjs +0 -4
  543. package/dist/toolDefinitions.d.cts +0 -2
  544. package/dist/toolDefinitions.test.cjs +0 -15
  545. package/dist/toolDefinitions.test.cjs.map +0 -1
  546. package/dist/toolDefinitions.test.d.cts +0 -1
  547. package/dist/toolDefinitions.test.d.ts +0 -1
  548. package/dist/toolDefinitions.test.js +0 -15
  549. package/dist/toolDefinitions.test.js.map +0 -1
  550. package/dist/tools-4Rtn4WEf.js +0 -470
  551. package/dist/tools-4Rtn4WEf.js.map +0 -1
  552. package/dist/tools-DHHqAqP9.cjs +0 -476
  553. package/dist/tools-DHHqAqP9.cjs.map +0 -1
  554. package/dist/tools.cjs +0 -11
  555. package/dist/tools.d.cts +0 -251
  556. package/dist/tools.d.cts.map +0 -1
  557. package/dist/tools.d.ts +0 -251
  558. package/dist/tools.d.ts.map +0 -1
  559. package/dist/tools.js +0 -11
  560. package/dist/tools.test.cjs +0 -1018
  561. package/dist/tools.test.cjs.map +0 -1
  562. package/dist/tools.test.d.cts +0 -1
  563. package/dist/tools.test.d.ts +0 -1
  564. package/dist/tools.test.js +0 -1018
  565. package/dist/tools.test.js.map +0 -1
  566. package/dist/types-CbLyQvVe.d.cts +0 -38
  567. package/dist/types-CbLyQvVe.d.cts.map +0 -1
  568. package/dist/types-CcffrLXB.d.cts.map +0 -1
  569. package/dist/types-CfJ51LyL.d.ts +0 -38
  570. package/dist/types-CfJ51LyL.d.ts.map +0 -1
  571. package/dist/types-DuUmV9zh.d.ts.map +0 -1
  572. package/dist/version-BT9r_3jm.js +0 -6
  573. package/dist/version-BT9r_3jm.js.map +0 -1
  574. package/dist/version-CRzAHHGZ.cjs.map +0 -1
  575. package/dist/vi.bdSIJ99Y-BfJr7I2s.js +0 -6349
  576. package/dist/vi.bdSIJ99Y-BfJr7I2s.js.map +0 -1
  577. package/dist/vi.bdSIJ99Y-Dft_B_Ta.cjs +0 -6355
  578. package/dist/vi.bdSIJ99Y-Dft_B_Ta.cjs.map +0 -1
  579. /package/dist/{api-client-CNv_hbPO.js → api-client-ChL_0F2u.js} +0 -0
  580. /package/dist/{types-6zHoEWAx.js → fetch-utils-C0F4eH6S.cjs} +0 -0
  581. /package/dist/{api-client/client.test.d.cts → index-BrojxuhJ.d.ts} +0 -0
@@ -1,1018 +0,0 @@
1
- import { describe, it } from "./dist-DDpQABxe.js";
2
- import { globalExpect } from "./vi.bdSIJ99Y-BfJr7I2s.js";
3
- import "./errors-BJSrT6Ou.js";
4
- import "./schema-CewAKS9A.js";
5
- import "./client-D5xFZtxK.js";
6
- import "./types-6zHoEWAx.js";
7
- import "./api-client-CNv_hbPO.js";
8
- import "./formatting-BaARL2gT.js";
9
- import "./issue-helpers-CSNNO03f.js";
10
- import "./logging-CXLD0FFB.js";
11
- import { TOOL_HANDLERS } from "./tools-4Rtn4WEf.js";
12
-
13
- //#region src/tools.test.ts
14
- describe("whoami", () => {
15
- it("serializes", async () => {
16
- const tool = TOOL_HANDLERS.whoami;
17
- const result = await tool({
18
- accessToken: "access-token",
19
- userId: "1",
20
- organizationSlug: null
21
- }, { regionUrl: void 0 });
22
- globalExpect(result).toMatchInlineSnapshot(`
23
- "You are authenticated as John Doe (john.doe@example.com).
24
-
25
- Your Sentry User ID is 1."
26
- `);
27
- });
28
- });
29
- describe("find_organizations", () => {
30
- it("serializes", async () => {
31
- const tool = TOOL_HANDLERS.find_organizations;
32
- const result = await tool({
33
- accessToken: "access-token",
34
- userId: "1",
35
- organizationSlug: null
36
- }, { regionUrl: void 0 });
37
- globalExpect(result).toMatchInlineSnapshot(`
38
- "# Organizations
39
-
40
- ## **sentry-mcp-evals**
41
-
42
- **Web URL:** https://sentry.io/sentry-mcp-evals
43
- **Region URL:** https://us.sentry.io
44
-
45
- # Using this information
46
-
47
- - The organization's name is the identifier for the organization, and is used in many tools for \`organizationSlug\`.
48
- - If a tool supports passing in the \`regionUrl\`, you MUST pass in the correct value there.
49
- "
50
- `);
51
- });
52
- });
53
- describe("find_teams", () => {
54
- it("serializes", async () => {
55
- const tool = TOOL_HANDLERS.find_teams;
56
- const result = await tool({
57
- accessToken: "access-token",
58
- userId: "1",
59
- organizationSlug: null
60
- }, {
61
- organizationSlug: "sentry-mcp-evals",
62
- regionUrl: void 0
63
- });
64
- globalExpect(result).toMatchInlineSnapshot(`
65
- "# Teams in **sentry-mcp-evals**
66
-
67
- - the-goats
68
- "
69
- `);
70
- });
71
- });
72
- describe("find_projects", () => {
73
- it("serializes", async () => {
74
- const tool = TOOL_HANDLERS.find_projects;
75
- const result = await tool({
76
- accessToken: "access-token",
77
- userId: "1",
78
- organizationSlug: null
79
- }, {
80
- organizationSlug: "sentry-mcp-evals",
81
- regionUrl: void 0
82
- });
83
- globalExpect(result).toMatchInlineSnapshot(`
84
- "# Projects in **sentry-mcp-evals**
85
-
86
- - **cloudflare-mcp**
87
- "
88
- `);
89
- });
90
- });
91
- describe("find_issues", () => {
92
- it("serializes with project", async () => {
93
- const tool = TOOL_HANDLERS.find_issues;
94
- const result = await tool({
95
- accessToken: "access-token",
96
- userId: "1",
97
- organizationSlug: null
98
- }, {
99
- organizationSlug: "sentry-mcp-evals",
100
- projectSlug: "cloudflare-mcp",
101
- query: void 0,
102
- sortBy: "last_seen",
103
- regionUrl: void 0
104
- });
105
- globalExpect(result).toMatchInlineSnapshot(`
106
- "# Issues in **sentry-mcp-evals/cloudflare-mcp**
107
-
108
- ## CLOUDFLARE-MCP-41
109
-
110
- **Description**: Error: Tool list_organizations is already registered
111
- **Culprit**: Object.fetch(index)
112
- **First Seen**: 2025-04-03T22:51:19.403Z
113
- **Last Seen**: 2025-04-12T11:34:11.000Z
114
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
115
-
116
- ## CLOUDFLARE-MCP-42
117
-
118
- **Description**: Error: Tool list_issues is already registered
119
- **Culprit**: Object.fetch(index)
120
- **First Seen**: 2025-04-11T22:51:19.403Z
121
- **Last Seen**: 2025-04-12T11:34:11.000Z
122
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42
123
-
124
- # Using this information
125
-
126
- - You can reference the Issue ID in commit messages (e.g. \`Fixes <issueID>\`) to automatically close the issue when the commit is merged.
127
- - You can get more details about a specific issue by using the tool: \`get_issue_details(organizationSlug="sentry-mcp-evals", issueId=<issueID>)\`
128
- "
129
- `);
130
- });
131
- it("serializes without project", async () => {
132
- const tool = TOOL_HANDLERS.find_issues;
133
- const result = await tool({
134
- accessToken: "access-token",
135
- userId: "1",
136
- organizationSlug: null
137
- }, {
138
- organizationSlug: "sentry-mcp-evals",
139
- projectSlug: void 0,
140
- query: void 0,
141
- sortBy: "last_seen",
142
- regionUrl: void 0
143
- });
144
- globalExpect(result).toMatchInlineSnapshot(`
145
- "# Issues in **sentry-mcp-evals**
146
-
147
- ## CLOUDFLARE-MCP-41
148
-
149
- **Description**: Error: Tool list_organizations is already registered
150
- **Culprit**: Object.fetch(index)
151
- **First Seen**: 2025-04-03T22:51:19.403Z
152
- **Last Seen**: 2025-04-12T11:34:11.000Z
153
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
154
-
155
- ## CLOUDFLARE-MCP-42
156
-
157
- **Description**: Error: Tool list_issues is already registered
158
- **Culprit**: Object.fetch(index)
159
- **First Seen**: 2025-04-11T22:51:19.403Z
160
- **Last Seen**: 2025-04-12T11:34:11.000Z
161
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-42
162
-
163
- # Using this information
164
-
165
- - You can reference the Issue ID in commit messages (e.g. \`Fixes <issueID>\`) to automatically close the issue when the commit is merged.
166
- - You can get more details about a specific issue by using the tool: \`get_issue_details(organizationSlug="sentry-mcp-evals", issueId=<issueID>)\`
167
- "
168
- `);
169
- });
170
- });
171
- describe("find_releases", () => {
172
- it("works without project", async () => {
173
- const tool = TOOL_HANDLERS.find_releases;
174
- const result = await tool({
175
- accessToken: "access-token",
176
- userId: "1",
177
- organizationSlug: null
178
- }, {
179
- organizationSlug: "sentry-mcp-evals",
180
- projectSlug: void 0,
181
- regionUrl: void 0,
182
- query: void 0
183
- });
184
- globalExpect(result).toMatchInlineSnapshot(`
185
- "# Releases in **sentry-mcp-evals**
186
-
187
- ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36
188
-
189
- **Created**: 2025-04-13T19:54:21.764Z
190
- **First Event**: 2025-04-13T19:54:21.000Z
191
- **Last Event**: 2025-04-13T20:28:23.000Z
192
- **New Issues**: 0
193
- **Projects**: cloudflare-mcp
194
-
195
- # Using this information
196
-
197
- - You can reference the Release version in commit messages or documentation.
198
- - You can search for issues in a specific release using the \`find_errors()\` tool with the query \`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\`.
199
- "
200
- `);
201
- });
202
- it("works with project", async () => {
203
- const tool = TOOL_HANDLERS.find_releases;
204
- const result = await tool({
205
- accessToken: "access-token",
206
- userId: "1",
207
- organizationSlug: null
208
- }, {
209
- organizationSlug: "sentry-mcp-evals",
210
- projectSlug: "cloudflare-mcp",
211
- regionUrl: void 0,
212
- query: void 0
213
- });
214
- globalExpect(result).toMatchInlineSnapshot(`
215
- "# Releases in **sentry-mcp-evals/cloudflare-mcp**
216
-
217
- ## 8ce89484-0fec-4913-a2cd-e8e2d41dee36
218
-
219
- **Created**: 2025-04-13T19:54:21.764Z
220
- **First Event**: 2025-04-13T19:54:21.000Z
221
- **Last Event**: 2025-04-13T20:28:23.000Z
222
- **New Issues**: 0
223
- **Projects**: cloudflare-mcp
224
-
225
- # Using this information
226
-
227
- - You can reference the Release version in commit messages or documentation.
228
- - You can search for issues in a specific release using the \`find_errors()\` tool with the query \`release:8ce89484-0fec-4913-a2cd-e8e2d41dee36\`.
229
- "
230
- `);
231
- });
232
- });
233
- describe("find_tags", () => {
234
- it("works", async () => {
235
- const tool = TOOL_HANDLERS.find_tags;
236
- const result = await tool({
237
- accessToken: "access-token",
238
- userId: "1",
239
- organizationSlug: null
240
- }, {
241
- organizationSlug: "sentry-mcp-evals",
242
- projectSlug: void 0,
243
- regionUrl: void 0
244
- });
245
- globalExpect(result).toMatchInlineSnapshot(`
246
- "# Tags in **sentry-mcp-evals**
247
-
248
- - transaction
249
- - runtime.name
250
- - level
251
- - device
252
- - os
253
- - user
254
- - runtime
255
- - release
256
- - url
257
- - uptime_rule
258
- - server_name
259
- - browser
260
- - os.name
261
- - device.family
262
- - replayId
263
- - client_os.name
264
- - environment
265
- - service
266
- - browser.name
267
-
268
- # Using this information
269
-
270
- - You can reference tags in the \`query\` parameter of various tools: \`tagName:tagValue\`.
271
- "
272
- `);
273
- });
274
- });
275
- describe("find_errors", () => {
276
- it("serializes", async () => {
277
- const tool = TOOL_HANDLERS.find_errors;
278
- const result = await tool({
279
- accessToken: "access-token",
280
- userId: "1",
281
- organizationSlug: null
282
- }, {
283
- organizationSlug: "sentry-mcp-evals",
284
- projectSlug: void 0,
285
- filename: void 0,
286
- transaction: void 0,
287
- query: void 0,
288
- sortBy: "count",
289
- regionUrl: void 0
290
- });
291
- globalExpect(result).toMatchInlineSnapshot(`
292
- "# Errors in **sentry-mcp-evals**
293
-
294
-
295
- ## CLOUDFLARE-MCP-41
296
-
297
- **Description**: Error: Tool list_organizations is already registered
298
- **Issue ID**: CLOUDFLARE-MCP-41
299
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
300
- **Project**: test-suite
301
- **Last Seen**: 2025-04-07T12:23:39+00:00
302
- **Occurrences**: 2
303
-
304
- # Using this information
305
-
306
- - You can reference the Issue ID in commit messages (e.g. \`Fixes <issueID>\`) to automatically close the issue when the commit is merged.
307
- - You can get more details about an error by using the tool: \`get_issue_details(organizationSlug="sentry-mcp-evals", issueId=<issueID>)\`
308
- "
309
- `);
310
- });
311
- });
312
- describe("find_transactions", () => {
313
- it("serializes", async () => {
314
- const tool = TOOL_HANDLERS.find_transactions;
315
- const result = await tool({
316
- accessToken: "access-token",
317
- userId: "1",
318
- organizationSlug: null
319
- }, {
320
- organizationSlug: "sentry-mcp-evals",
321
- projectSlug: void 0,
322
- transaction: void 0,
323
- query: void 0,
324
- sortBy: "duration",
325
- regionUrl: void 0
326
- });
327
- globalExpect(result).toMatchInlineSnapshot(`
328
- "# Transactions in **sentry-mcp-evals**
329
-
330
-
331
- ## GET /trpc/bottleList
332
-
333
- **Span ID**: 07752c6aeb027c8f
334
- **Trace ID**: 6a477f5b0f31ef7b6b9b5e1dea66c91d
335
- **Span Operation**: http.server
336
- **Span Description**: GET /trpc/bottleList
337
- **Duration**: 12
338
- **Timestamp**: 2025-04-13T14:19:18+00:00
339
- **Project**: peated
340
- **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/6a477f5b0f31ef7b6b9b5e1dea66c91d
341
-
342
- ## GET /trpc/bottleList
343
-
344
- **Span ID**: 7ab5edf5b3ba42c9
345
- **Trace ID**: 54177131c7b192a446124daba3136045
346
- **Span Operation**: http.server
347
- **Span Description**: GET /trpc/bottleList
348
- **Duration**: 18
349
- **Timestamp**: 2025-04-13T14:19:17+00:00
350
- **Project**: peated
351
- **URL**: https://sentry-mcp-evals.sentry.io/explore/traces/trace/54177131c7b192a446124daba3136045
352
-
353
- "
354
- `);
355
- });
356
- });
357
- describe("get_issue_details", () => {
358
- it("serializes with issueId", async () => {
359
- const tool = TOOL_HANDLERS.get_issue_details;
360
- const result = await tool({
361
- accessToken: "access-token",
362
- userId: "1",
363
- organizationSlug: null
364
- }, {
365
- organizationSlug: "sentry-mcp-evals",
366
- issueId: "CLOUDFLARE-MCP-41",
367
- eventId: void 0,
368
- issueUrl: void 0,
369
- regionUrl: void 0
370
- });
371
- globalExpect(result).toMatchInlineSnapshot(`
372
- "# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
373
-
374
- **Description**: Error: Tool list_organizations is already registered
375
- **Culprit**: Object.fetch(index)
376
- **First Seen**: 2025-04-03T22:51:19.403Z
377
- **Last Seen**: 2025-04-12T11:34:11.000Z
378
- **Occurrences**: 25
379
- **Users Impacted**: 1
380
- **Status**: unresolved
381
- **Platform**: javascript
382
- **Project**: CLOUDFLARE-MCP
383
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
384
-
385
- ## Event Details
386
-
387
- **Event ID**: 7ca573c0f4814912aaa9bdc77d1a7d51
388
- **Occurred At**: 2025-04-08T21:15:04.000Z
389
-
390
- ### Error
391
-
392
- \`\`\`
393
- Error: Tool list_organizations is already registered
394
- \`\`\`
395
-
396
- **Stacktrace:**
397
- \`\`\`
398
- index.js:7809:27
399
- index.js:8029:24 (OAuthProviderImpl.fetch)
400
- index.js:19631:28 (Object.fetch)
401
- \`\`\`
402
-
403
- ### HTTP Request
404
-
405
- **Method:** GET
406
- **URL:** https://mcp.sentry.dev/sse
407
-
408
- ### Additional Context
409
-
410
- These are additional context provided by the user when they're instrumenting their application.
411
-
412
- **cloud_resource**
413
- cloud.provider: "cloudflare"
414
-
415
- **culture**
416
- timezone: "Europe/London"
417
-
418
- **runtime**
419
- name: "cloudflare"
420
-
421
- **trace**
422
- trace_id: "3032af8bcdfe4423b937fc5c041d5d82"
423
- span_id: "953da703d2a6f4c7"
424
- status: "unknown"
425
- client_sample_rate: 1
426
- sampled: true
427
-
428
- # Using this information
429
-
430
- - You can reference the IssueID in commit messages (e.g. \`Fixes CLOUDFLARE-MCP-41\`) to automatically close the issue when the commit is merged.
431
- - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.
432
- "
433
- `);
434
- });
435
- it("serializes with issueUrl", async () => {
436
- const tool = TOOL_HANDLERS.get_issue_details;
437
- const result = await tool({
438
- accessToken: "access-token",
439
- userId: "1",
440
- organizationSlug: null
441
- }, {
442
- organizationSlug: void 0,
443
- issueId: void 0,
444
- eventId: void 0,
445
- issueUrl: "https://sentry-mcp-evals.sentry.io/issues/6507376925",
446
- regionUrl: void 0
447
- });
448
- globalExpect(result).toMatchInlineSnapshot(`
449
- "# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
450
-
451
- **Description**: Error: Tool list_organizations is already registered
452
- **Culprit**: Object.fetch(index)
453
- **First Seen**: 2025-04-03T22:51:19.403Z
454
- **Last Seen**: 2025-04-12T11:34:11.000Z
455
- **Occurrences**: 25
456
- **Users Impacted**: 1
457
- **Status**: unresolved
458
- **Platform**: javascript
459
- **Project**: CLOUDFLARE-MCP
460
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
461
-
462
- ## Event Details
463
-
464
- **Event ID**: 7ca573c0f4814912aaa9bdc77d1a7d51
465
- **Occurred At**: 2025-04-08T21:15:04.000Z
466
-
467
- ### Error
468
-
469
- \`\`\`
470
- Error: Tool list_organizations is already registered
471
- \`\`\`
472
-
473
- **Stacktrace:**
474
- \`\`\`
475
- index.js:7809:27
476
- index.js:8029:24 (OAuthProviderImpl.fetch)
477
- index.js:19631:28 (Object.fetch)
478
- \`\`\`
479
-
480
- ### HTTP Request
481
-
482
- **Method:** GET
483
- **URL:** https://mcp.sentry.dev/sse
484
-
485
- ### Additional Context
486
-
487
- These are additional context provided by the user when they're instrumenting their application.
488
-
489
- **cloud_resource**
490
- cloud.provider: "cloudflare"
491
-
492
- **culture**
493
- timezone: "Europe/London"
494
-
495
- **runtime**
496
- name: "cloudflare"
497
-
498
- **trace**
499
- trace_id: "3032af8bcdfe4423b937fc5c041d5d82"
500
- span_id: "953da703d2a6f4c7"
501
- status: "unknown"
502
- client_sample_rate: 1
503
- sampled: true
504
-
505
- # Using this information
506
-
507
- - You can reference the IssueID in commit messages (e.g. \`Fixes CLOUDFLARE-MCP-41\`) to automatically close the issue when the commit is merged.
508
- - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.
509
- "
510
- `);
511
- });
512
- it("serializes with eventId", async () => {
513
- const tool = TOOL_HANDLERS.get_issue_details;
514
- const result = await tool({
515
- accessToken: "access-token",
516
- userId: "1",
517
- organizationSlug: null
518
- }, {
519
- organizationSlug: "sentry-mcp-evals",
520
- issueId: void 0,
521
- issueUrl: void 0,
522
- eventId: "7ca573c0f4814912aaa9bdc77d1a7d51",
523
- regionUrl: void 0
524
- });
525
- globalExpect(result).toMatchInlineSnapshot(`
526
- "# Issue CLOUDFLARE-MCP-41 in **sentry-mcp-evals**
527
-
528
- **Description**: Error: Tool list_organizations is already registered
529
- **Culprit**: Object.fetch(index)
530
- **First Seen**: 2025-04-03T22:51:19.403Z
531
- **Last Seen**: 2025-04-12T11:34:11.000Z
532
- **Occurrences**: 25
533
- **Users Impacted**: 1
534
- **Status**: unresolved
535
- **Platform**: javascript
536
- **Project**: CLOUDFLARE-MCP
537
- **URL**: https://sentry-mcp-evals.sentry.io/issues/CLOUDFLARE-MCP-41
538
-
539
- ## Event Details
540
-
541
- **Event ID**: 7ca573c0f4814912aaa9bdc77d1a7d51
542
- **Occurred At**: 2025-04-08T21:15:04.000Z
543
-
544
- ### Error
545
-
546
- \`\`\`
547
- Error: Tool list_organizations is already registered
548
- \`\`\`
549
-
550
- **Stacktrace:**
551
- \`\`\`
552
- index.js:7809:27
553
- index.js:8029:24 (OAuthProviderImpl.fetch)
554
- index.js:19631:28 (Object.fetch)
555
- \`\`\`
556
-
557
- ### HTTP Request
558
-
559
- **Method:** GET
560
- **URL:** https://mcp.sentry.dev/sse
561
-
562
- ### Additional Context
563
-
564
- These are additional context provided by the user when they're instrumenting their application.
565
-
566
- **cloud_resource**
567
- cloud.provider: "cloudflare"
568
-
569
- **culture**
570
- timezone: "Europe/London"
571
-
572
- **runtime**
573
- name: "cloudflare"
574
-
575
- **trace**
576
- trace_id: "3032af8bcdfe4423b937fc5c041d5d82"
577
- span_id: "953da703d2a6f4c7"
578
- status: "unknown"
579
- client_sample_rate: 1
580
- sampled: true
581
-
582
- # Using this information
583
-
584
- - You can reference the IssueID in commit messages (e.g. \`Fixes CLOUDFLARE-MCP-41\`) to automatically close the issue when the commit is merged.
585
- - The stacktrace includes both first-party application code as well as third-party code, its important to triage to first-party code.
586
- "
587
- `);
588
- });
589
- });
590
- describe("create_team", () => {
591
- it("serializes", async () => {
592
- const tool = TOOL_HANDLERS.create_team;
593
- const result = await tool({
594
- accessToken: "access-token",
595
- userId: "1",
596
- organizationSlug: null
597
- }, {
598
- organizationSlug: "sentry-mcp-evals",
599
- name: "the-goats",
600
- regionUrl: void 0
601
- });
602
- globalExpect(result).toMatchInlineSnapshot(`
603
- "# New Team in **sentry-mcp-evals**
604
-
605
- **ID**: 4509109078196224
606
- **Slug**: the-goats
607
- **Name**: the-goats
608
- # Using this information
609
-
610
- - You should always inform the user of the Team Slug value.
611
- "
612
- `);
613
- });
614
- });
615
- describe("create_project", () => {
616
- it("serializes", async () => {
617
- const tool = TOOL_HANDLERS.create_project;
618
- const result = await tool({
619
- accessToken: "access-token",
620
- userId: "1",
621
- organizationSlug: null
622
- }, {
623
- organizationSlug: "sentry-mcp-evals",
624
- teamSlug: "the-goats",
625
- name: "cloudflare-mcp",
626
- platform: "javascript",
627
- regionUrl: void 0
628
- });
629
- globalExpect(result).toMatchInlineSnapshot(`
630
- "# New Project in **sentry-mcp-evals**
631
-
632
- **ID**: 4509109104082945
633
- **Slug**: cloudflare-mcp
634
- **Name**: cloudflare-mcp
635
- **SENTRY_DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945
636
-
637
- # Using this information
638
-
639
- - You can reference the **SENTRY_DSN** value to initialize Sentry's SDKs.
640
- - You should always inform the user of the **SENTRY_DSN** and Project Slug values.
641
- "
642
- `);
643
- });
644
- });
645
- describe("create_dsn", () => {
646
- it("serializes", async () => {
647
- const tool = TOOL_HANDLERS.create_dsn;
648
- const result = await tool({
649
- accessToken: "access-token",
650
- userId: "1",
651
- organizationSlug: null
652
- }, {
653
- organizationSlug: "sentry-mcp-evals",
654
- projectSlug: "cloudflare-mcp",
655
- name: "Default",
656
- regionUrl: void 0
657
- });
658
- globalExpect(result).toMatchInlineSnapshot(`
659
- "# New DSN in **sentry-mcp-evals/cloudflare-mcp**
660
-
661
- **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945
662
- **Name**: Default
663
-
664
- # Using this information
665
-
666
- - The \`SENTRY_DSN\` value is a URL that you can use to initialize Sentry's SDKs.
667
- "
668
- `);
669
- });
670
- });
671
- describe("find_dsns", () => {
672
- it("serializes", async () => {
673
- const tool = TOOL_HANDLERS.find_dsns;
674
- const result = await tool({
675
- accessToken: "access-token",
676
- userId: "1",
677
- organizationSlug: null
678
- }, {
679
- organizationSlug: "sentry-mcp-evals",
680
- projectSlug: "cloudflare-mcp",
681
- regionUrl: void 0
682
- });
683
- globalExpect(result).toMatchInlineSnapshot(`
684
- "# DSNs in **sentry-mcp-evals/cloudflare-mcp**
685
-
686
- ## Default
687
- **ID**: d20df0a1ab5031c7f3c7edca9c02814d
688
- **DSN**: https://d20df0a1ab5031c7f3c7edca9c02814d@o4509106732793856.ingest.us.sentry.io/4509109104082945
689
-
690
- # Using this information
691
-
692
- - The \`SENTRY_DSN\` value is a URL that you can use to initialize Sentry's SDKs.
693
- "
694
- `);
695
- });
696
- });
697
- describe("begin_seer_issue_fix", () => {
698
- it("serializes", async () => {
699
- const tool = TOOL_HANDLERS.begin_seer_issue_fix;
700
- const result = await tool({
701
- accessToken: "access-token",
702
- userId: "1",
703
- organizationSlug: null
704
- }, {
705
- organizationSlug: "sentry-mcp-evals",
706
- issueId: "PEATED-A8",
707
- issueUrl: void 0,
708
- regionUrl: void 0
709
- });
710
- globalExpect(result).toMatchInlineSnapshot(`
711
- "# Issue Fix Started for Issue PEATED-A8
712
-
713
- **Run ID:**: 123
714
-
715
- This operation may take some time, so you should call \`get_seer_issue_fix_status()\` to check the status of the analysis, and repeat the process until its finished.
716
-
717
- You should also inform the user that the operation may take some time, and give them updates whenever you check the status of the operation..
718
-
719
- \`\`\`
720
- get_seer_issue_fix_status(organizationSlug="sentry-mcp-evals", issueId="PEATED-A8")
721
- \`\`\`"
722
- `);
723
- });
724
- });
725
- describe("get_seer_issue_fix_status", () => {
726
- it("serializes", async () => {
727
- const tool = TOOL_HANDLERS.get_seer_issue_fix_status;
728
- const result = await tool({
729
- accessToken: "access-token",
730
- userId: "1",
731
- organizationSlug: null
732
- }, {
733
- organizationSlug: "sentry-mcp-evals",
734
- issueId: "PEATED-A8",
735
- issueUrl: void 0,
736
- regionUrl: void 0
737
- });
738
- globalExpect(result).toMatchInlineSnapshot(`
739
- "# Issue Fix Status for Issue PEATED-A8
740
-
741
- ## Analyzing the Issue
742
-
743
- **The \`bottleById\` query fails because the input ID (3216) doesn't exist in the database.
744
- **
745
- The exception details show that the \`input\` value at the time of the \`TRPCError\` in \`bottleById.ts\` was 3216, and the query likely failed because a bottle with ID 3216 was not found in the database.
746
-
747
- \`\`\`
748
- Variable values at the time of the exception::
749
- {
750
- "input": 3216
751
- }
752
- \`\`\`
753
-
754
-
755
- **However, the request also includes a different ID (16720) for \`bottlePriceList\`.
756
- **
757
- The root cause is likely a mismatch of input IDs within the batched TRPC request, where \`bottlePriceList\` expects bottle ID 16720, but \`bottleById\` receives a different ID (3216) leading to the "Bottle not found" error.
758
-
759
- \`\`\`
760
- GET http://api.peated.com/trpc/bottlePriceList,bottleById
761
- \`\`\`
762
-
763
- \`\`\`json
764
- {
765
- "input": 3216
766
- }
767
- \`\`\`
768
-
769
- \`\`\`
770
- TRPCError: Bottle not found. (occurred in: GET /trpc/bottlePriceList,bottleById)
771
- \`\`\`
772
-
773
-
774
- **This suggests a data consistency issue or incorrect client-side request.
775
- **
776
- The \`TRPCError\` originates from \`bottleById.ts\` with the input value being \`3216\`, indicating the procedure failed to find a bottle with that specific ID in the database.
777
-
778
- \`\`\`
779
- <anonymous> in file /app/apps/server/src/trpc/routes/bottleById.ts [Line 33, column 13] (In app)
780
- .select({
781
- ...getTableColumns(bottles),
782
- })
783
- .from(bottleTombstones)
784
- .innerJoin(bottles, eq(bottleTombstones.newBottleId, bottles.id))
785
- .where(eq(bottleTombstones.bottleId, input));
786
- if (!bottle) {
787
- throw new TRPCError({ <-- SUSPECT LINE
788
- message: "Bottle not found.",
789
- code: "NOT_FOUND",
790
- });
791
- }
792
- }
793
-
794
- const createdBy = await db.query.users.findFirst({
795
- ---
796
- Variable values at the time of the exception::
797
- {
798
- "input": 3216
799
- }
800
- \`\`\`
801
-
802
-
803
-
804
- ## Root Cause Analysis
805
-
806
- **The client initiates a batched TRPC request to the \`/trpc/bottlePriceList,bottleById\` endpoint, intending to fetch both the price list and details for a specific bottle.**
807
-
808
- This is the entry point where the client requests data from two different procedures in a single HTTP request. The server needs to correctly route and process the parameters for each procedure.
809
-
810
- **The TRPC server receives the batched request and begins processing the \`bottlePriceList\` procedure, intending to fetch the price list for bottle ID 16720.**
811
-
812
- \`\`\`typescript
813
- // apps/server/src/trpc/routes/bottlePriceList.ts
814
- .input(z.object({ bottle: z.number(), onlyValid: z.boolean().optional() }))
815
- .query(async function ({ input, ctx }) {
816
- const [bottle] = await db.select().from(bottles).where(eq(bottles.id, input.bottle));
817
- if (!bottle) { ... }
818
- \`\`\`
819
- This procedure expects a 'bottle' parameter in the input, which is used to query the database.
820
-
821
- **The TRPC server also processes the \`bottleById\` procedure, but due to a parameter mapping issue or client-side error, it receives bottle ID 3216 as input instead of 16720.**
822
-
823
- \`\`\`typescript
824
- // apps/server/src/trpc/routes/bottleById.ts
825
- export default publicProcedure.input(z.number()).query(async function ({ input, ctx }) {
826
- let [bottle] = await db.select().from(bottles).where(eq(bottles.id, input));
827
- if (!bottle) { ... }
828
- \`\`\`
829
- This procedure expects a numerical ID as input to find the bottle.
830
-
831
- **The \`bottleById\` procedure queries the \`bottles\` table for a bottle with ID 3216, but no such bottle exists.**
832
-
833
- The database query returns no results because bottle ID 3216 is not present in the \`bottles\` table.
834
-
835
- **The \`bottleById\` procedure then checks the \`bottleTombstones\` table to see if bottle ID 3216 has been tombstoned (redirected to a new ID), but no such tombstone exists.**
836
-
837
- The query to \`bottleTombstones\` also returns no results, indicating that bottle ID 3216 has not been redirected.
838
-
839
- **Since the \`bottleById\` procedure cannot find a bottle with ID 3216 in either the \`bottles\` or \`bottleTombstones\` tables, it throws a \`TRPCError\` with the message "Bottle not found."**
840
-
841
- \`\`\`typescript
842
- // apps/server/src/trpc/routes/bottleById.ts
843
- if (!bottle) {
844
- throw new TRPCError({ message: "Bottle not found.", code: "NOT_FOUND" });
845
- }
846
- \`\`\`
847
- This is where the error is thrown, indicating that the bottle could not be found.
848
-
849
-
850
- ## Planning Solution
851
-
852
- **The discrepancy between inputs suggests a potential issue with batch request handling.
853
- **
854
- The \`TRPCError\` occurred in \`bottleById.ts\` with an input of \`3216\`, while the request was initiated with a bottle ID of \`16720\`, indicating a mismatch in the bottle ID being processed.
855
-
856
- \`\`\`
857
- Variable values at the time of the exception::
858
- {
859
- "input": 3216
860
- }
861
- \`\`\`
862
-
863
- \`\`\`
864
- GET http://api.peated.com/trpc/bottlePriceList,bottleById
865
- \`\`\`
866
-
867
-
868
- **The client-side batch request construction is the most likely source of error.
869
- **
870
- The discrepancy between the bottle ID in the error message (16720) and the ID being processed (3216) strongly suggests a client-side parameter mapping issue in the batched TRPC request.
871
-
872
- To fix this, I propose the following steps:
873
-
874
- 1. **Inspect the Client-Side Code:** Identify the code responsible for constructing the TRPC batch request to \`/trpc/bottlePriceList,bottleById\`.
875
-
876
- 2. **Verify Parameter Mapping:** Ensure that both \`bottlePriceList\` and \`bottleById\` are receiving the correct bottle ID (which should be 16720 in this case).
877
-
878
- 3. **Correct Parameter Assignment:** If the parameters are being incorrectly assigned, modify the client-side code to ensure that both procedures receive the same, correct bottle ID.
879
-
880
- 4. **Add Logging (Client-Side):** Add temporary logging to the client-side code to confirm the parameters being sent to each procedure in the batch request. This will help verify the fix.
881
-
882
- \`\`\`typescript
883
- // Example logging (add to the client-side code where the batch request is created)
884
- console.log("bottlePriceList input:", { bottle: 16720 }); // Replace 16720 with the actual ID
885
- console.log("bottleById input:", { bottle: 16720 }); // Replace 16720 with the actual ID
886
- \`\`\`
887
-
888
- 5. **Test the Fix:** After applying the fix, test the affected functionality to ensure that the "Bottle not found" error is resolved and that both procedures are working correctly.
889
-
890
- 6. **Remove Logging:** Once the fix is verified, remove the temporary logging.
891
-
892
- This approach directly addresses the most likely cause of the issue and provides a clear path to resolution.
893
-
894
-
895
- **Ensuring consistent bottle IDs will likely resolve this inconsistency.
896
- **
897
- The error message references bottle ID 16720, but the exception details show the procedure was actually processing ID 3216, indicating a parameter mismatch in the batch request.
898
-
899
- To fix this, I recommend the following steps:
900
-
901
- 1. **Client-Side Investigation**:
902
-
903
- * Examine the client-side code where the TRPC batch request is constructed.
904
- * Verify that the same \`bottleId\` parameter is being passed to both \`bottlePriceList\` and \`bottleById\` procedures.
905
- * If the IDs are being passed correctly, inspect the network request payload to confirm the correct structure of the batched request.
906
-
907
- \`\`\`typescript
908
- // Example (Hypothetical) Client-Side Code
909
- const bottleId = 16720; // Example bottle ID
910
-
911
- // Ensure both procedures receive the same bottleId
912
- const [priceList, bottleDetails] = await trpc.batch(() => [
913
- trpc.bottlePriceList.fetch({ bottle: bottleId }),
914
- trpc.bottleById.fetch(bottleId),
915
- ]);
916
- \`\`\`
917
-
918
- 2. **Server-Side Logging (Temporary)**:
919
-
920
- * Add temporary logging to both \`bottlePriceList\` and \`bottleById\` procedures to log the received \`input\` value.
921
- * This will help confirm whether the server is receiving the correct IDs from the client.
922
- * **Important**: Remove these logs after debugging to avoid unnecessary overhead.
923
-
924
- \`\`\`typescript
925
- // apps/server/src/trpc/routes/bottlePriceList.ts
926
- export default publicProcedure
927
- .input(
928
- z.object({
929
- bottle: z.number(),
930
- onlyValid: z.boolean().optional(),
931
- }),
932
- )
933
- .query(async function ({ input, ctx }) {
934
- console.log("bottlePriceList input:", input); // Add this line
935
- // ... rest of the code
936
- });
937
-
938
- // apps/server/src/trpc/routes/bottleById.ts
939
- export default publicProcedure.input(z.number()).query(async function ({
940
- input,
941
- ctx,
942
- }) {
943
- console.log("bottleById input:", input); // Add this line
944
- // ... rest of the code
945
- });
946
- \`\`\`
947
-
948
- 3. **TRPC Batch Request Configuration**:
949
-
950
- * Review the TRPC batch link configuration on the client-side.
951
- * Ensure that the batching logic is correctly mapping parameters to the corresponding procedures.
952
- * If using a custom batching implementation, verify its correctness.
953
-
954
- 4. **Data Integrity Check**:
955
-
956
- * If the client-side code appears correct, investigate whether bottle ID 3216 should exist in the database.
957
- * Check the \`bottles\` table and \`bottleTombstones\` table for any entries related to bottle ID 3216.
958
- * If the bottle should exist but is missing, investigate potential data deletion or migration issues.
959
-
960
- 5. **Tombstone Logic**:
961
-
962
- * Double-check the logic for creating and using tombstones.
963
- * Ensure that when a bottle is deleted, a tombstone entry is created correctly, pointing to the new bottle (if any).
964
-
965
- 6. **Error Handling**:
966
-
967
- * While this isn't the primary fix, consider improving the error message in \`bottleById.ts\` to include more context.
968
- * Include the original requested bottle ID (if available) in the error message to aid debugging.
969
-
970
- 7. **Client-Side Retries**:
971
-
972
- * Implement a retry mechanism on the client-side for TRPC requests.
973
- * If a "Bottle not found" error occurs, retry the request a few times before giving up. This can help mitigate transient issues.
974
-
975
- By following these steps, you should be able to identify the root cause of the parameter mismatch and implement a fix that ensures consistent bottle IDs are passed to both TRPC procedures in the batch request.
976
-
977
-
978
-
979
- ## Solution
980
-
981
- Consolidate bottle and price data fetching into a single batched TRPC request using \`Promise.all\` to ensure ID consistency.
982
-
983
- **Create a shared utility function to fetch bottle details and price data together.**
984
- \`\`\`typescript
985
- // In a shared utility function or component
986
- export async function getBottleWithPrices(bottleId: number) {
987
- const trpcClient = await getTrpcClient();
988
-
989
- // Use Promise.all to ensure both requests are part of the same batch
990
- // and receive the same parameters
991
- const [bottle, priceList] = await Promise.all([
992
- trpcClient.bottleById.fetch(bottleId),
993
- trpcClient.bottlePriceList.fetch({ bottle: bottleId }),
994
- ]);
995
-
996
- return { bottle, priceList };
997
- }
998
- \`\`\`
999
- This code creates a function that uses \`Promise.all\` to fetch both bottle details and price data concurrently. This ensures that both TRPC procedures are part of the same batch and receive the same \`bottleId\`.
1000
-
1001
- **Modify the page components to use the shared utility function.**
1002
- \`\`\`typescript
1003
- // Then in the page components:
1004
- const { bottle, priceList } = await getBottleWithPrices(Number(bottleId));
1005
- \`\`\`
1006
- This code replaces the separate calls to \`bottleById\` and \`bottlePriceList\` with a single call to the \`getBottleWithPrices\` function, ensuring that both components receive data for the same bottle.
1007
-
1008
- **Add a unit test that reproduces the issue.**
1009
- null
1010
-
1011
-
1012
- "
1013
- `);
1014
- });
1015
- });
1016
-
1017
- //#endregion
1018
- //# sourceMappingURL=tools.test.js.map