@sentry/mcp-server 0.12.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -4
- package/dist/analyze-issue-with-seer-BsNarzJN.js +163 -0
- package/dist/analyze-issue-with-seer-BsNarzJN.js.map +1 -0
- package/dist/analyze-issue-with-seer-DbAWpyTC.cjs +169 -0
- package/dist/analyze-issue-with-seer-DbAWpyTC.cjs.map +1 -0
- package/dist/api-client/client.cjs +2 -2
- package/dist/api-client/client.d.cts +3 -3
- package/dist/api-client/client.d.ts +3 -3
- package/dist/api-client/client.js +2 -2
- package/dist/api-client/index.cjs +9 -2
- package/dist/api-client/index.d.cts +4 -4
- package/dist/api-client/index.d.ts +5 -5
- package/dist/api-client/index.js +5 -5
- package/dist/api-client/schema.cjs +8 -1
- package/dist/api-client/schema.d.cts +2 -2
- package/dist/api-client/schema.d.ts +2 -2
- package/dist/api-client/schema.js +2 -2
- package/dist/api-client/types.d.cts +3 -3
- package/dist/api-client/types.d.ts +3 -3
- package/dist/api-client/types.js +1 -1
- package/dist/api-utils-C6QJAzFL.js +31 -0
- package/dist/api-utils-C6QJAzFL.js.map +1 -0
- package/dist/api-utils-d36iteNO.cjs +36 -0
- package/dist/api-utils-d36iteNO.cjs.map +1 -0
- package/dist/{client-4jq_wVgn.d.ts → client-BCN17Wbp.d.ts} +43 -11
- package/dist/client-BCN17Wbp.d.ts.map +1 -0
- package/dist/{client-DkY0ifZf.d.cts → client-CILwfx6G.d.cts} +43 -11
- package/dist/client-CILwfx6G.d.cts.map +1 -0
- package/dist/{client-CAoHZbyK.js → client-DOYWNvVM.js} +75 -18
- package/dist/client-DOYWNvVM.js.map +1 -0
- package/dist/{client-B7vZ6JMk.cjs → client-Dkw5iYu3.cjs} +75 -18
- package/dist/client-Dkw5iYu3.cjs.map +1 -0
- package/dist/constants-ClkMK29-.cjs +182 -0
- package/dist/constants-ClkMK29-.cjs.map +1 -0
- package/dist/constants-S7AU45oQ.js +164 -0
- package/dist/constants-S7AU45oQ.js.map +1 -0
- package/dist/constants.cjs +5 -0
- package/dist/constants.d.cts +23 -0
- package/dist/constants.d.cts.map +1 -0
- package/dist/constants.d.ts +23 -0
- package/dist/constants.d.ts.map +1 -0
- package/dist/constants.js +3 -0
- package/dist/create-dsn-CDcL2DLD.js +59 -0
- package/dist/create-dsn-CDcL2DLD.js.map +1 -0
- package/dist/create-dsn-fESUtX3R.cjs +65 -0
- package/dist/create-dsn-fESUtX3R.cjs.map +1 -0
- package/dist/create-project-Bg5uDkc4.cjs +82 -0
- package/dist/create-project-Bg5uDkc4.cjs.map +1 -0
- package/dist/create-project-DY5mFznV.js +76 -0
- package/dist/create-project-DY5mFznV.js.map +1 -0
- package/dist/create-team-5purh64V.cjs +53 -0
- package/dist/create-team-5purh64V.cjs.map +1 -0
- package/dist/create-team-C2R7EUC3.js +47 -0
- package/dist/create-team-C2R7EUC3.js.map +1 -0
- package/dist/defineTool-77H4nSna.js +8 -0
- package/dist/defineTool-77H4nSna.js.map +1 -0
- package/dist/defineTool-lWNTzWl_.cjs +14 -0
- package/dist/defineTool-lWNTzWl_.cjs.map +1 -0
- package/dist/{errors-BJSrT6Ou.js → errors-CIoxzIug.js} +1 -1
- package/dist/{errors-BJSrT6Ou.js.map → errors-CIoxzIug.js.map} +1 -1
- package/dist/{errors-B9fwS-aP.cjs → errors-YmiXLOyx.cjs} +1 -1
- package/dist/{errors-B9fwS-aP.cjs.map → errors-YmiXLOyx.cjs.map} +1 -1
- package/dist/errors.cjs +1 -1
- package/dist/errors.js +1 -1
- package/dist/fetch-utils-BMKjO-cc.js +29 -0
- package/dist/fetch-utils-BMKjO-cc.js.map +1 -0
- package/dist/fetch-utils-Bv9WjUp0.d.ts +14 -0
- package/dist/fetch-utils-Bv9WjUp0.d.ts.map +1 -0
- package/dist/fetch-utils-DlPjrSk2.js +0 -0
- package/dist/fetch-utils-DzdRW4Yd.d.cts +14 -0
- package/dist/fetch-utils-DzdRW4Yd.d.cts.map +1 -0
- package/dist/fetch-utils-oab6uNp3.cjs +35 -0
- package/dist/fetch-utils-oab6uNp3.cjs.map +1 -0
- package/dist/find-dsns-CvfcLB9Z.js +52 -0
- package/dist/find-dsns-CvfcLB9Z.js.map +1 -0
- package/dist/find-dsns-ZZ-thiNk.cjs +58 -0
- package/dist/find-dsns-ZZ-thiNk.cjs.map +1 -0
- package/dist/find-errors-CuRm4PzL.js +91 -0
- package/dist/find-errors-CuRm4PzL.js.map +1 -0
- package/dist/find-errors-Drzv7hzM.cjs +97 -0
- package/dist/find-errors-Drzv7hzM.cjs.map +1 -0
- package/dist/find-issues-C3uk59rn.cjs +98 -0
- package/dist/find-issues-C3uk59rn.cjs.map +1 -0
- package/dist/find-issues-CAtNGBly.js +92 -0
- package/dist/find-issues-CAtNGBly.js.map +1 -0
- package/dist/find-organizations-BrdMfZRO.cjs +50 -0
- package/dist/find-organizations-BrdMfZRO.cjs.map +1 -0
- package/dist/find-organizations-ojXwWWzk.js +45 -0
- package/dist/find-organizations-ojXwWWzk.js.map +1 -0
- package/dist/find-projects-BZWhlYJh.cjs +45 -0
- package/dist/find-projects-BZWhlYJh.cjs.map +1 -0
- package/dist/find-projects-fcLG4KpT.js +39 -0
- package/dist/find-projects-fcLG4KpT.js.map +1 -0
- package/dist/find-releases-BUozr0Z-.js +93 -0
- package/dist/find-releases-BUozr0Z-.js.map +1 -0
- package/dist/find-releases-CZCVEOHZ.cjs +99 -0
- package/dist/find-releases-CZCVEOHZ.cjs.map +1 -0
- package/dist/find-tags-Byk4d3oZ.cjs +45 -0
- package/dist/find-tags-Byk4d3oZ.cjs.map +1 -0
- package/dist/find-tags-d-wF1Se8.js +39 -0
- package/dist/find-tags-d-wF1Se8.js.map +1 -0
- package/dist/find-teams-BZ118EIK.js +39 -0
- package/dist/find-teams-BZ118EIK.js.map +1 -0
- package/dist/find-teams-CnU5x9rQ.cjs +45 -0
- package/dist/find-teams-CnU5x9rQ.cjs.map +1 -0
- package/dist/find-transactions-DIJ80wkd.cjs +89 -0
- package/dist/find-transactions-DIJ80wkd.cjs.map +1 -0
- package/dist/find-transactions-DZCj81jP.js +83 -0
- package/dist/find-transactions-DZCj81jP.js.map +1 -0
- package/dist/formatting-BlMiQa9i.cjs +388 -0
- package/dist/formatting-BlMiQa9i.cjs.map +1 -0
- package/dist/formatting-CHh9Q_OW.d.cts +47 -0
- package/dist/formatting-CHh9Q_OW.d.cts.map +1 -0
- package/dist/formatting-kdIeURER.d.ts +47 -0
- package/dist/formatting-kdIeURER.d.ts.map +1 -0
- package/dist/formatting-pUm38KOj.js +370 -0
- package/dist/formatting-pUm38KOj.js.map +1 -0
- package/dist/formatting-utils-C3sej5ER.js +14 -0
- package/dist/formatting-utils-C3sej5ER.js.map +1 -0
- package/dist/formatting-utils-DDz14xeB.cjs +20 -0
- package/dist/formatting-utils-DDz14xeB.cjs.map +1 -0
- package/dist/get-doc-DaTCenOE.cjs +86 -0
- package/dist/get-doc-DaTCenOE.cjs.map +1 -0
- package/dist/get-doc-YTiQznr1.js +80 -0
- package/dist/get-doc-YTiQznr1.js.map +1 -0
- package/dist/get-event-attachment-ChRw3jlQ.cjs +144 -0
- package/dist/get-event-attachment-ChRw3jlQ.cjs.map +1 -0
- package/dist/get-event-attachment-CuU-_5T6.js +138 -0
- package/dist/get-event-attachment-CuU-_5T6.js.map +1 -0
- package/dist/get-issue-details-CxChU4U9.js +104 -0
- package/dist/get-issue-details-CxChU4U9.js.map +1 -0
- package/dist/get-issue-details-DFwZRbmU.cjs +110 -0
- package/dist/get-issue-details-DFwZRbmU.cjs.map +1 -0
- package/dist/index.cjs +73 -23
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +75 -25
- package/dist/index.js.map +1 -1
- package/dist/internal/fetch-utils.cjs +3 -0
- package/dist/internal/fetch-utils.d.cts +2 -0
- package/dist/internal/fetch-utils.d.ts +2 -0
- package/dist/internal/fetch-utils.js +3 -0
- package/dist/internal/formatting.cjs +1 -1
- package/dist/internal/formatting.d.cts +5 -25
- package/dist/internal/formatting.d.ts +6 -26
- package/dist/internal/formatting.js +1 -1
- package/dist/internal/issue-helpers.cjs +1 -1
- package/dist/internal/issue-helpers.d.cts +2 -52
- package/dist/internal/issue-helpers.d.ts +2 -52
- package/dist/internal/issue-helpers.js +1 -1
- package/dist/internal/test-fixtures.cjs +214 -0
- package/dist/internal/test-fixtures.cjs.map +1 -0
- package/dist/internal/test-fixtures.d.cts +2138 -0
- package/dist/internal/test-fixtures.d.cts.map +1 -0
- package/dist/internal/test-fixtures.d.ts +2138 -0
- package/dist/internal/test-fixtures.d.ts.map +1 -0
- package/dist/internal/test-fixtures.js +205 -0
- package/dist/internal/test-fixtures.js.map +1 -0
- package/dist/issue-helpers-BJffpNoO.d.ts +52 -0
- package/dist/issue-helpers-BJffpNoO.d.ts.map +1 -0
- package/dist/{issue-helpers-BMVLc3mR.js → issue-helpers-CqqYnwYE.js} +1 -1
- package/dist/{issue-helpers-BMVLc3mR.js.map → issue-helpers-CqqYnwYE.js.map} +1 -1
- package/dist/issue-helpers-Cz01Ipvl.d.cts +52 -0
- package/dist/issue-helpers-Cz01Ipvl.d.cts.map +1 -0
- package/dist/{issue-helpers-D712fGT2.cjs → issue-helpers-DyAIO0w6.cjs} +1 -1
- package/dist/{issue-helpers-D712fGT2.cjs.map → issue-helpers-DyAIO0w6.cjs.map} +1 -1
- package/dist/issue-utils-BVAB6I-Z.js +0 -0
- package/dist/issue-utils-pdbo-5LW.cjs +0 -0
- package/dist/{logging-CXLD0FFB.js → logging-LnQMFw-_.js} +1 -1
- package/dist/{logging-CXLD0FFB.js.map → logging-LnQMFw-_.js.map} +1 -1
- package/dist/{logging-ByvSjT6V.cjs → logging-oIouXrcb.cjs} +1 -1
- package/dist/{logging-ByvSjT6V.cjs.map → logging-oIouXrcb.cjs.map} +1 -1
- package/dist/logging.cjs +1 -1
- package/dist/logging.js +1 -1
- package/dist/{promptDefinitions-BTLIBcGt.cjs → promptDefinitions-C29BWGYg.cjs} +4 -4
- package/dist/promptDefinitions-C29BWGYg.cjs.map +1 -0
- package/dist/{promptDefinitions-D8yow1m0.js → promptDefinitions-CSKE8T0a.js} +4 -4
- package/dist/{promptDefinitions-D8yow1m0.js.map → promptDefinitions-CSKE8T0a.js.map} +1 -1
- package/dist/{promptDefinitions-CF2VWdQ6.d.cts → promptDefinitions-CVHtYaj8.d.cts} +3 -3
- package/dist/promptDefinitions-CVHtYaj8.d.cts.map +1 -0
- package/dist/{promptDefinitions-D5FSQckL.d.ts → promptDefinitions-D3GTBGLr.d.ts} +3 -3
- package/dist/promptDefinitions-D3GTBGLr.d.ts.map +1 -0
- package/dist/promptDefinitions.cjs +3 -2
- package/dist/promptDefinitions.d.cts +1 -1
- package/dist/promptDefinitions.d.ts +1 -1
- package/dist/promptDefinitions.js +3 -2
- package/dist/{prompts-Dt3A8Qfl.js → prompts-C8Y9w5c4.js} +7 -7
- package/dist/{prompts-Dt3A8Qfl.js.map → prompts-C8Y9w5c4.js.map} +1 -1
- package/dist/{prompts-CDbQrutV.cjs → prompts-Df3i1XSB.cjs} +7 -7
- package/dist/{prompts-CDbQrutV.cjs.map → prompts-Df3i1XSB.cjs.map} +1 -1
- package/dist/prompts.cjs +2 -2
- package/dist/prompts.d.cts +4 -5
- package/dist/prompts.d.cts.map +1 -1
- package/dist/prompts.d.ts +4 -5
- package/dist/prompts.d.ts.map +1 -1
- package/dist/prompts.js +2 -2
- package/dist/resources-BHF8a1ZB.js +92 -0
- package/dist/resources-BHF8a1ZB.js.map +1 -0
- package/dist/resources-BM_YQGcb.cjs +104 -0
- package/dist/resources-BM_YQGcb.cjs.map +1 -0
- package/dist/resources.cjs +5 -2
- package/dist/resources.d.cts +26 -12
- package/dist/resources.d.cts.map +1 -1
- package/dist/resources.d.ts +26 -12
- package/dist/resources.d.ts.map +1 -1
- package/dist/resources.js +4 -2
- package/dist/{schema-BnxGHL_i.d.ts → schema--5m4KI84.d.ts} +3678 -619
- package/dist/schema--5m4KI84.d.ts.map +1 -0
- package/dist/{schema-BsvGMALe.cjs → schema-B_cMyyJJ.cjs} +94 -8
- package/dist/schema-B_cMyyJJ.cjs.map +1 -0
- package/dist/{schema-BTfISwFu.cjs → schema-BpJVmev8.cjs} +23 -1
- package/dist/{schema-Dv6aLZgz.js.map → schema-BpJVmev8.cjs.map} +1 -1
- package/dist/{schema-Dv6aLZgz.js → schema-DtsnsxMl.js} +6 -2
- package/dist/schema-DtsnsxMl.js.map +1 -0
- package/dist/{schema-C_hp0BR7.js → schema-WDk5Yqww.js} +53 -9
- package/dist/schema-WDk5Yqww.js.map +1 -0
- package/dist/{schema-BJv7kREf.d.cts → schema-ya35hkEL.d.cts} +3614 -555
- package/dist/schema-ya35hkEL.d.cts.map +1 -0
- package/dist/schema.cjs +5 -1
- package/dist/schema.d.cts +4 -1
- package/dist/schema.d.cts.map +1 -1
- package/dist/schema.d.ts +4 -1
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +3 -2
- package/dist/search-docs-BLbB_GV2.js +102 -0
- package/dist/search-docs-BLbB_GV2.js.map +1 -0
- package/dist/search-docs-D5Foht_0.cjs +108 -0
- package/dist/search-docs-D5Foht_0.cjs.map +1 -0
- package/dist/seer-utils-Ckr8nYlz.js +87 -0
- package/dist/seer-utils-Ckr8nYlz.js.map +1 -0
- package/dist/seer-utils-CzYEEZb2.cjs +129 -0
- package/dist/seer-utils-CzYEEZb2.cjs.map +1 -0
- package/dist/{server-DeutbO8v.cjs → server-BpEIZVaZ.cjs} +104 -57
- package/dist/server-BpEIZVaZ.cjs.map +1 -0
- package/dist/{server-C7cHq_pc.js → server-DOy-M9Ko.js} +104 -57
- package/dist/server-DOy-M9Ko.js.map +1 -0
- package/dist/server.cjs +40 -13
- package/dist/server.d.cts +2 -3
- package/dist/server.d.cts.map +1 -1
- package/dist/server.d.ts +2 -3
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +42 -15
- package/dist/{stdio-ZQLC-i5Q.js → stdio-B2NDq7Ax.js} +17 -7
- package/dist/stdio-B2NDq7Ax.js.map +1 -0
- package/dist/{stdio-B73CCTly.cjs → stdio-DMEgJ_fG.cjs} +17 -7
- package/dist/stdio-DMEgJ_fG.cjs.map +1 -0
- package/dist/test-setup.cjs +1420 -1230
- package/dist/test-setup.cjs.map +1 -1
- package/dist/test-setup.js +1262 -1045
- package/dist/test-setup.js.map +1 -1
- package/dist/toolDefinitions.d.ts +25 -2
- package/dist/toolDefinitions.js +1059 -4
- package/dist/tools/analyze-issue-with-seer.cjs +16 -0
- package/dist/tools/analyze-issue-with-seer.d.cts +16 -0
- package/dist/tools/analyze-issue-with-seer.d.cts.map +1 -0
- package/dist/tools/analyze-issue-with-seer.d.ts +16 -0
- package/dist/tools/analyze-issue-with-seer.d.ts.map +1 -0
- package/dist/tools/analyze-issue-with-seer.js +16 -0
- package/dist/tools/create-dsn.cjs +12 -0
- package/dist/tools/create-dsn.d.cts +15 -0
- package/dist/tools/create-dsn.d.cts.map +1 -0
- package/dist/tools/create-dsn.d.ts +15 -0
- package/dist/tools/create-dsn.d.ts.map +1 -0
- package/dist/tools/create-dsn.js +12 -0
- package/dist/tools/create-project.cjs +13 -0
- package/dist/tools/create-project.d.cts +16 -0
- package/dist/tools/create-project.d.cts.map +1 -0
- package/dist/tools/create-project.d.ts +16 -0
- package/dist/tools/create-project.d.ts.map +1 -0
- package/dist/tools/create-project.js +13 -0
- package/dist/tools/create-team.cjs +12 -0
- package/dist/tools/create-team.d.cts +14 -0
- package/dist/tools/create-team.d.cts.map +1 -0
- package/dist/tools/create-team.d.ts +14 -0
- package/dist/tools/create-team.d.ts.map +1 -0
- package/dist/tools/create-team.js +12 -0
- package/dist/tools/find-dsns.cjs +12 -0
- package/dist/tools/find-dsns.d.cts +14 -0
- package/dist/tools/find-dsns.d.cts.map +1 -0
- package/dist/tools/find-dsns.d.ts +14 -0
- package/dist/tools/find-dsns.d.ts.map +1 -0
- package/dist/tools/find-dsns.js +12 -0
- package/dist/tools/find-errors.cjs +12 -0
- package/dist/tools/find-errors.d.cts +18 -0
- package/dist/tools/find-errors.d.cts.map +1 -0
- package/dist/tools/find-errors.d.ts +18 -0
- package/dist/tools/find-errors.d.ts.map +1 -0
- package/dist/tools/find-errors.js +12 -0
- package/dist/tools/find-issues.cjs +12 -0
- package/dist/tools/find-issues.d.cts +16 -0
- package/dist/tools/find-issues.d.cts.map +1 -0
- package/dist/tools/find-issues.d.ts +16 -0
- package/dist/tools/find-issues.d.ts.map +1 -0
- package/dist/tools/find-issues.js +12 -0
- package/dist/tools/find-organizations.cjs +10 -0
- package/dist/tools/find-organizations.d.cts +9 -0
- package/dist/tools/find-organizations.d.cts.map +1 -0
- package/dist/tools/find-organizations.d.ts +9 -0
- package/dist/tools/find-organizations.d.ts.map +1 -0
- package/dist/tools/find-organizations.js +10 -0
- package/dist/tools/find-projects.cjs +12 -0
- package/dist/tools/find-projects.d.cts +13 -0
- package/dist/tools/find-projects.d.cts.map +1 -0
- package/dist/tools/find-projects.d.ts +13 -0
- package/dist/tools/find-projects.d.ts.map +1 -0
- package/dist/tools/find-projects.js +12 -0
- package/dist/tools/find-releases.cjs +12 -0
- package/dist/tools/find-releases.d.cts +15 -0
- package/dist/tools/find-releases.d.cts.map +1 -0
- package/dist/tools/find-releases.d.ts +15 -0
- package/dist/tools/find-releases.d.ts.map +1 -0
- package/dist/tools/find-releases.js +12 -0
- package/dist/tools/find-tags.cjs +12 -0
- package/dist/tools/find-tags.d.cts +13 -0
- package/dist/tools/find-tags.d.cts.map +1 -0
- package/dist/tools/find-tags.d.ts +13 -0
- package/dist/tools/find-tags.d.ts.map +1 -0
- package/dist/tools/find-tags.js +12 -0
- package/dist/tools/find-teams.cjs +12 -0
- package/dist/tools/find-teams.d.cts +13 -0
- package/dist/tools/find-teams.d.cts.map +1 -0
- package/dist/tools/find-teams.d.ts +13 -0
- package/dist/tools/find-teams.d.ts.map +1 -0
- package/dist/tools/find-teams.js +12 -0
- package/dist/tools/find-transactions.cjs +12 -0
- package/dist/tools/find-transactions.d.cts +17 -0
- package/dist/tools/find-transactions.d.cts.map +1 -0
- package/dist/tools/find-transactions.d.ts +17 -0
- package/dist/tools/find-transactions.d.ts.map +1 -0
- package/dist/tools/find-transactions.js +12 -0
- package/dist/tools/get-doc.cjs +11 -0
- package/dist/tools/get-doc.d.cts +12 -0
- package/dist/tools/get-doc.d.cts.map +1 -0
- package/dist/tools/get-doc.d.ts +12 -0
- package/dist/tools/get-doc.d.ts.map +1 -0
- package/dist/tools/get-doc.js +11 -0
- package/dist/tools/get-event-attachment.cjs +12 -0
- package/dist/tools/get-event-attachment.d.cts +16 -0
- package/dist/tools/get-event-attachment.d.cts.map +1 -0
- package/dist/tools/get-event-attachment.d.ts +16 -0
- package/dist/tools/get-event-attachment.d.ts.map +1 -0
- package/dist/tools/get-event-attachment.js +12 -0
- package/dist/tools/get-issue-details.cjs +15 -0
- package/dist/tools/get-issue-details.d.cts +16 -0
- package/dist/tools/get-issue-details.d.cts.map +1 -0
- package/dist/tools/get-issue-details.d.ts +16 -0
- package/dist/tools/get-issue-details.d.ts.map +1 -0
- package/dist/tools/get-issue-details.js +15 -0
- package/dist/tools/index.cjs +40 -0
- package/dist/tools/index.d.cts +127 -0
- package/dist/tools/index.d.cts.map +1 -0
- package/dist/tools/index.d.ts +127 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +40 -0
- package/dist/tools/search-docs.cjs +12 -0
- package/dist/tools/search-docs.d.cts +14 -0
- package/dist/tools/search-docs.d.cts.map +1 -0
- package/dist/tools/search-docs.d.ts +14 -0
- package/dist/tools/search-docs.d.ts.map +1 -0
- package/dist/tools/search-docs.js +12 -0
- package/dist/tools/types.cjs +0 -0
- package/dist/tools/types.d.cts +4 -0
- package/dist/tools/types.d.ts +4 -0
- package/dist/tools/types.js +0 -0
- package/dist/tools/update-issue.cjs +16 -0
- package/dist/tools/update-issue.d.cts +17 -0
- package/dist/tools/update-issue.d.cts.map +1 -0
- package/dist/tools/update-issue.d.ts +17 -0
- package/dist/tools/update-issue.d.ts.map +1 -0
- package/dist/tools/update-issue.js +16 -0
- package/dist/tools/update-project.cjs +13 -0
- package/dist/tools/update-project.d.cts +18 -0
- package/dist/tools/update-project.d.cts.map +1 -0
- package/dist/tools/update-project.d.ts +18 -0
- package/dist/tools/update-project.d.ts.map +1 -0
- package/dist/tools/update-project.js +13 -0
- package/dist/tools/utils/api-utils.cjs +8 -0
- package/dist/tools/utils/api-utils.d.cts +24 -0
- package/dist/tools/utils/api-utils.d.cts.map +1 -0
- package/dist/tools/utils/api-utils.d.ts +24 -0
- package/dist/tools/utils/api-utils.d.ts.map +1 -0
- package/dist/tools/utils/api-utils.js +8 -0
- package/dist/tools/utils/defineTool.cjs +3 -0
- package/dist/tools/utils/defineTool.d.cts +12 -0
- package/dist/tools/utils/defineTool.d.cts.map +1 -0
- package/dist/tools/utils/defineTool.d.ts +12 -0
- package/dist/tools/utils/defineTool.d.ts.map +1 -0
- package/dist/tools/utils/defineTool.js +3 -0
- package/dist/tools/utils/fetch-utils.cjs +4 -0
- package/dist/tools/utils/fetch-utils.d.cts +2 -0
- package/dist/tools/utils/fetch-utils.d.ts +2 -0
- package/dist/tools/utils/fetch-utils.js +4 -0
- package/dist/tools/utils/formatting-utils.cjs +3 -0
- package/dist/tools/utils/formatting-utils.d.cts +15 -0
- package/dist/tools/utils/formatting-utils.d.cts.map +1 -0
- package/dist/tools/utils/formatting-utils.d.ts +15 -0
- package/dist/tools/utils/formatting-utils.d.ts.map +1 -0
- package/dist/tools/utils/formatting-utils.js +3 -0
- package/dist/tools/utils/issue-utils.cjs +6 -0
- package/dist/tools/utils/issue-utils.d.cts +7 -0
- package/dist/tools/utils/issue-utils.d.ts +7 -0
- package/dist/tools/utils/issue-utils.js +5 -0
- package/dist/tools/utils/seer-utils.cjs +9 -0
- package/dist/tools/utils/seer-utils.d.cts +28 -0
- package/dist/tools/utils/seer-utils.d.cts.map +1 -0
- package/dist/tools/utils/seer-utils.d.ts +28 -0
- package/dist/tools/utils/seer-utils.d.ts.map +1 -0
- package/dist/tools/utils/seer-utils.js +3 -0
- package/dist/tools/whoami.cjs +10 -0
- package/dist/tools/whoami.d.cts +9 -0
- package/dist/tools/whoami.d.cts.map +1 -0
- package/dist/tools/whoami.d.ts +9 -0
- package/dist/tools/whoami.d.ts.map +1 -0
- package/dist/tools/whoami.js +10 -0
- package/dist/tools-19Ms1kck.cjs +53 -0
- package/dist/tools-19Ms1kck.cjs.map +1 -0
- package/dist/tools-mThAUo_3.js +48 -0
- package/dist/tools-mThAUo_3.js.map +1 -0
- package/dist/transports/stdio.cjs +42 -14
- package/dist/transports/stdio.d.cts +2 -3
- package/dist/transports/stdio.d.cts.map +1 -1
- package/dist/transports/stdio.d.ts +2 -3
- package/dist/transports/stdio.d.ts.map +1 -1
- package/dist/transports/stdio.js +44 -16
- package/dist/{types-NIQW7KyF.d.cts → types-Bg17IGWJ.d.cts} +5 -3
- package/dist/types-Bg17IGWJ.d.cts.map +1 -0
- package/dist/types-CCHsZshF.js +0 -0
- package/dist/types-CUN-2OSS.d.cts +29 -0
- package/dist/types-CUN-2OSS.d.cts.map +1 -0
- package/dist/{types-Daq2fm0E.d.ts → types-CtTBwGbw.d.ts} +5 -3
- package/dist/types-CtTBwGbw.d.ts.map +1 -0
- package/dist/types-D_mx318Q.d.cts +29 -0
- package/dist/types-D_mx318Q.d.cts.map +1 -0
- package/dist/types-DkJtNDXU.d.ts +29 -0
- package/dist/types-DkJtNDXU.d.ts.map +1 -0
- package/dist/types-qB8a4WQT.d.ts +29 -0
- package/dist/types-qB8a4WQT.d.ts.map +1 -0
- package/dist/types.d.cts +3 -4
- package/dist/types.d.ts +3 -4
- package/dist/update-issue-B6eZhAPJ.cjs +115 -0
- package/dist/update-issue-B6eZhAPJ.cjs.map +1 -0
- package/dist/update-issue-DmLElHPS.js +109 -0
- package/dist/update-issue-DmLElHPS.js.map +1 -0
- package/dist/update-project-BNPev7W8.js +120 -0
- package/dist/update-project-BNPev7W8.js.map +1 -0
- package/dist/update-project-CijYCtG1.cjs +126 -0
- package/dist/update-project-CijYCtG1.cjs.map +1 -0
- package/dist/url-utils-C9hykWmk.cjs +106 -0
- package/dist/url-utils-C9hykWmk.cjs.map +1 -0
- package/dist/url-utils-DvZYfzPM.js +82 -0
- package/dist/url-utils-DvZYfzPM.js.map +1 -0
- package/dist/utils/url-utils.cjs +6 -0
- package/dist/utils/url-utils.d.cts +37 -0
- package/dist/utils/url-utils.d.cts.map +1 -0
- package/dist/utils/url-utils.d.ts +37 -0
- package/dist/utils/url-utils.d.ts.map +1 -0
- package/dist/utils/url-utils.js +3 -0
- package/dist/version-C4uvMmw0.js +6 -0
- package/dist/version-C4uvMmw0.js.map +1 -0
- package/dist/{version-BNmubeQI.cjs → version-Ddz4xg_q.cjs} +2 -2
- package/dist/version-Ddz4xg_q.cjs.map +1 -0
- package/dist/version.cjs +1 -1
- package/dist/version.js +1 -1
- package/dist/whoami-CEgbTUqt.cjs +28 -0
- package/dist/whoami-CEgbTUqt.cjs.map +1 -0
- package/dist/whoami-DesNZnaQ.js +23 -0
- package/dist/whoami-DesNZnaQ.js.map +1 -0
- package/package.json +24 -14
- package/dist/api-client/client.test.cjs +0 -33
- package/dist/api-client/client.test.cjs.map +0 -1
- package/dist/api-client/client.test.d.ts +0 -1
- package/dist/api-client/client.test.js +0 -33
- package/dist/api-client/client.test.js.map +0 -1
- package/dist/chunk-BLXvPPr8.js +0 -30
- package/dist/client-4jq_wVgn.d.ts.map +0 -1
- package/dist/client-B7vZ6JMk.cjs.map +0 -1
- package/dist/client-CAoHZbyK.js.map +0 -1
- package/dist/client-DkY0ifZf.d.cts.map +0 -1
- package/dist/dist-BlIWGSIM.cjs +0 -8197
- package/dist/dist-BlIWGSIM.cjs.map +0 -1
- package/dist/dist-DDpQABxe.js +0 -8054
- package/dist/dist-DDpQABxe.js.map +0 -1
- package/dist/errors.test.cjs +0 -24
- package/dist/errors.test.cjs.map +0 -1
- package/dist/errors.test.d.cts +0 -1
- package/dist/errors.test.d.ts +0 -1
- package/dist/errors.test.js +0 -24
- package/dist/errors.test.js.map +0 -1
- package/dist/formatting-BaARL2gT.js +0 -68
- package/dist/formatting-BaARL2gT.js.map +0 -1
- package/dist/formatting-C2kN0ok6.cjs +0 -86
- package/dist/formatting-C2kN0ok6.cjs.map +0 -1
- package/dist/index-h64gcVNJ.d.ts +0 -1
- package/dist/internal/formatting.d.cts.map +0 -1
- package/dist/internal/formatting.d.ts.map +0 -1
- package/dist/internal/issue-helpers.d.cts.map +0 -1
- package/dist/internal/issue-helpers.d.ts.map +0 -1
- package/dist/internal/issue-helpers.test.cjs +0 -110
- package/dist/internal/issue-helpers.test.cjs.map +0 -1
- package/dist/internal/issue-helpers.test.d.cts +0 -1
- package/dist/internal/issue-helpers.test.d.ts +0 -1
- package/dist/internal/issue-helpers.test.js +0 -110
- package/dist/internal/issue-helpers.test.js.map +0 -1
- package/dist/magic-string.es-CybcVAw7.cjs +0 -1016
- package/dist/magic-string.es-CybcVAw7.cjs.map +0 -1
- package/dist/magic-string.es-DY8GVHw9.js +0 -1015
- package/dist/magic-string.es-DY8GVHw9.js.map +0 -1
- package/dist/promptDefinitions-BTLIBcGt.cjs.map +0 -1
- package/dist/promptDefinitions-CF2VWdQ6.d.cts.map +0 -1
- package/dist/promptDefinitions-D5FSQckL.d.ts.map +0 -1
- package/dist/resources-Bol20Xuo.js +0 -38
- package/dist/resources-Bol20Xuo.js.map +0 -1
- package/dist/resources-DNyoutxH.cjs +0 -44
- package/dist/resources-DNyoutxH.cjs.map +0 -1
- package/dist/schema-BJv7kREf.d.cts.map +0 -1
- package/dist/schema-BTfISwFu.cjs.map +0 -1
- package/dist/schema-BnxGHL_i.d.ts.map +0 -1
- package/dist/schema-BsvGMALe.cjs.map +0 -1
- package/dist/schema-C_hp0BR7.js.map +0 -1
- package/dist/server-C7cHq_pc.js.map +0 -1
- package/dist/server-DeutbO8v.cjs.map +0 -1
- package/dist/stdio-B73CCTly.cjs.map +0 -1
- package/dist/stdio-ZQLC-i5Q.js.map +0 -1
- package/dist/toolDefinitions-BOMF-zIC.d.ts +0 -394
- package/dist/toolDefinitions-BOMF-zIC.d.ts.map +0 -1
- package/dist/toolDefinitions-CUegGcWU.cjs +0 -547
- package/dist/toolDefinitions-CUegGcWU.cjs.map +0 -1
- package/dist/toolDefinitions-DFAxp3nr.js +0 -541
- package/dist/toolDefinitions-DFAxp3nr.js.map +0 -1
- package/dist/toolDefinitions-Ipvr4Acw.d.cts +0 -394
- package/dist/toolDefinitions-Ipvr4Acw.d.cts.map +0 -1
- package/dist/toolDefinitions.cjs +0 -4
- package/dist/toolDefinitions.d.cts +0 -2
- package/dist/toolDefinitions.test.cjs +0 -15
- package/dist/toolDefinitions.test.cjs.map +0 -1
- package/dist/toolDefinitions.test.d.cts +0 -1
- package/dist/toolDefinitions.test.d.ts +0 -1
- package/dist/toolDefinitions.test.js +0 -15
- package/dist/toolDefinitions.test.js.map +0 -1
- package/dist/tools-DpiQwSTY.js +0 -596
- package/dist/tools-DpiQwSTY.js.map +0 -1
- package/dist/tools-DyOqlsCW.cjs +0 -602
- package/dist/tools-DyOqlsCW.cjs.map +0 -1
- package/dist/tools.cjs +0 -11
- package/dist/tools.d.cts +0 -335
- package/dist/tools.d.cts.map +0 -1
- package/dist/tools.d.ts +0 -335
- package/dist/tools.d.ts.map +0 -1
- package/dist/tools.js +0 -11
- package/dist/tools.test.cjs +0 -1298
- package/dist/tools.test.cjs.map +0 -1
- package/dist/tools.test.d.cts +0 -1
- package/dist/tools.test.d.ts +0 -1
- package/dist/tools.test.js +0 -1298
- package/dist/tools.test.js.map +0 -1
- package/dist/types-D5TPcOfv.d.ts +0 -39
- package/dist/types-D5TPcOfv.d.ts.map +0 -1
- package/dist/types-DRF2IoP_.d.cts +0 -39
- package/dist/types-DRF2IoP_.d.cts.map +0 -1
- package/dist/types-Daq2fm0E.d.ts.map +0 -1
- package/dist/types-NIQW7KyF.d.cts.map +0 -1
- package/dist/version-BNmubeQI.cjs.map +0 -1
- package/dist/version-CRto5Sn_.js +0 -6
- package/dist/version-CRto5Sn_.js.map +0 -1
- package/dist/vi.bdSIJ99Y-BfJr7I2s.js +0 -6349
- package/dist/vi.bdSIJ99Y-BfJr7I2s.js.map +0 -1
- package/dist/vi.bdSIJ99Y-Dft_B_Ta.cjs +0 -6355
- package/dist/vi.bdSIJ99Y-Dft_B_Ta.cjs.map +0 -1
- /package/dist/{api-client-CNv_hbPO.js → api-client-ChL_0F2u.js} +0 -0
- /package/dist/{types-6zHoEWAx.js → fetch-utils-C0F4eH6S.cjs} +0 -0
- /package/dist/{api-client/client.test.d.cts → index-DVGDAddE.d.ts} +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { ApiErrorSchema, AssignedToSchema, AutofixRunSchema, AutofixRunStateSchema, AutofixRunStepDefaultSchema, AutofixRunStepRootCauseAnalysisSchema, AutofixRunStepSchema, AutofixRunStepSolutionSchema, ClientKeyListSchema, ClientKeySchema, ErrorEntrySchema, ErrorEventSchema, ErrorsSearchResponseSchema, EventSchema, EventsResponseSchema, ExceptionInterface, FrameInterface, IssueListSchema, IssueSchema, OrganizationListSchema, OrganizationSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, ReleaseSchema, RequestEntrySchema, SpansSearchResponseSchema, TagListSchema, TagSchema, TeamListSchema, TeamSchema, TransactionEventSchema, UnknownEventSchema, UserRegionsSchema, UserSchema } from "../schema-
|
|
1
|
+
import { ApiErrorSchema, AssignedToSchema, AutofixRunSchema, AutofixRunStateSchema, AutofixRunStepDefaultSchema, AutofixRunStepRootCauseAnalysisSchema, AutofixRunStepSchema, AutofixRunStepSolutionSchema, BreadcrumbSchema, BreadcrumbsEntrySchema, ClientKeyListSchema, ClientKeySchema, ErrorEntrySchema, ErrorEventSchema, ErrorsSearchResponseSchema, EventAttachmentListSchema, EventAttachmentSchema, EventSchema, EventsResponseSchema, ExceptionInterface, FrameInterface, IssueListSchema, IssueSchema, MessageEntrySchema, OrganizationListSchema, OrganizationSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, ReleaseSchema, RequestEntrySchema, SpansSearchResponseSchema, TagListSchema, TagSchema, TeamListSchema, TeamSchema, ThreadEntrySchema, ThreadsEntrySchema, TransactionEventSchema, UnknownEventSchema, UserRegionsSchema, UserSchema } from "../schema-WDk5Yqww.js";
|
|
2
2
|
|
|
3
|
-
export { ApiErrorSchema, AssignedToSchema, AutofixRunSchema, AutofixRunStateSchema, AutofixRunStepDefaultSchema, AutofixRunStepRootCauseAnalysisSchema, AutofixRunStepSchema, AutofixRunStepSolutionSchema, ClientKeyListSchema, ClientKeySchema, ErrorEntrySchema, ErrorEventSchema, ErrorsSearchResponseSchema, EventSchema, EventsResponseSchema, ExceptionInterface, FrameInterface, IssueListSchema, IssueSchema, OrganizationListSchema, OrganizationSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, ReleaseSchema, RequestEntrySchema, SpansSearchResponseSchema, TagListSchema, TagSchema, TeamListSchema, TeamSchema, TransactionEventSchema, UnknownEventSchema, UserRegionsSchema, UserSchema };
|
|
3
|
+
export { ApiErrorSchema, AssignedToSchema, AutofixRunSchema, AutofixRunStateSchema, AutofixRunStepDefaultSchema, AutofixRunStepRootCauseAnalysisSchema, AutofixRunStepSchema, AutofixRunStepSolutionSchema, BreadcrumbSchema, BreadcrumbsEntrySchema, ClientKeyListSchema, ClientKeySchema, ErrorEntrySchema, ErrorEventSchema, ErrorsSearchResponseSchema, EventAttachmentListSchema, EventAttachmentSchema, EventSchema, EventsResponseSchema, ExceptionInterface, FrameInterface, IssueListSchema, IssueSchema, MessageEntrySchema, OrganizationListSchema, OrganizationSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, ReleaseSchema, RequestEntrySchema, SpansSearchResponseSchema, TagListSchema, TagSchema, TeamListSchema, TeamSchema, ThreadEntrySchema, ThreadsEntrySchema, TransactionEventSchema, UnknownEventSchema, UserRegionsSchema, UserSchema };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../schema-
|
|
2
|
-
import { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User } from "../types-
|
|
3
|
-
export { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User };
|
|
1
|
+
import "../schema-ya35hkEL.cjs";
|
|
2
|
+
import { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User } from "../types-Bg17IGWJ.cjs";
|
|
3
|
+
export { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../schema
|
|
2
|
-
import { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User } from "../types-
|
|
3
|
-
export { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User };
|
|
1
|
+
import "../schema--5m4KI84.js";
|
|
2
|
+
import { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User } from "../types-CtTBwGbw.js";
|
|
3
|
+
export { AssignedTo, AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, Organization, OrganizationList, Project, ProjectList, Release, ReleaseList, Tag, TagList, Team, TeamList, User };
|
package/dist/api-client/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import "../types-
|
|
1
|
+
import "../types-CCHsZshF.js";
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { UserInputError } from "./errors-CIoxzIug.js";
|
|
2
|
+
import { SentryApiService } from "./client-DOYWNvVM.js";
|
|
3
|
+
|
|
4
|
+
//#region src/tools/utils/api-utils.ts
|
|
5
|
+
/**
|
|
6
|
+
* Create a Sentry API service from server context with optional region override
|
|
7
|
+
* @param context - Server context containing host and access token
|
|
8
|
+
* @param opts - Options object containing optional regionUrl override
|
|
9
|
+
* @returns Configured SentryApiService instance (always uses HTTPS)
|
|
10
|
+
* @throws {UserInputError} When regionUrl is provided but invalid
|
|
11
|
+
*/
|
|
12
|
+
function apiServiceFromContext(context, opts = {}) {
|
|
13
|
+
let host = context.sentryHost;
|
|
14
|
+
if (opts.regionUrl?.trim()) try {
|
|
15
|
+
const parsedUrl = new URL(opts.regionUrl);
|
|
16
|
+
if (!["http:", "https:"].includes(parsedUrl.protocol)) throw new UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. Must include protocol (http:// or https://).`);
|
|
17
|
+
if (parsedUrl.host === "https" || parsedUrl.host === "http") throw new UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. The host cannot be just a protocol name.`);
|
|
18
|
+
host = parsedUrl.host;
|
|
19
|
+
} catch (error) {
|
|
20
|
+
if (error instanceof UserInputError) throw error;
|
|
21
|
+
throw new UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. Must be a valid URL.`);
|
|
22
|
+
}
|
|
23
|
+
return new SentryApiService({
|
|
24
|
+
host,
|
|
25
|
+
accessToken: context.accessToken
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
//#endregion
|
|
30
|
+
export { apiServiceFromContext };
|
|
31
|
+
//# sourceMappingURL=api-utils-C6QJAzFL.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-utils-C6QJAzFL.js","names":["context: ServerContext","opts: { regionUrl?: string }"],"sources":["../src/tools/utils/api-utils.ts"],"sourcesContent":["import { SentryApiService } from \"../../api-client/index\";\nimport { UserInputError } from \"../../errors\";\nimport type { ServerContext } from \"../../types\";\n\n/**\n * Create a Sentry API service from server context with optional region override\n * @param context - Server context containing host and access token\n * @param opts - Options object containing optional regionUrl override\n * @returns Configured SentryApiService instance (always uses HTTPS)\n * @throws {UserInputError} When regionUrl is provided but invalid\n */\nexport function apiServiceFromContext(\n context: ServerContext,\n opts: { regionUrl?: string } = {},\n) {\n let host = context.sentryHost;\n\n if (opts.regionUrl?.trim()) {\n try {\n const parsedUrl = new URL(opts.regionUrl);\n\n // Validate that the URL has a proper protocol\n if (![\"http:\", \"https:\"].includes(parsedUrl.protocol)) {\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. Must include protocol (http:// or https://).`,\n );\n }\n\n // Validate that the host is not just the protocol name\n if (parsedUrl.host === \"https\" || parsedUrl.host === \"http\") {\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. The host cannot be just a protocol name.`,\n );\n }\n\n host = parsedUrl.host;\n } catch (error) {\n if (error instanceof UserInputError) {\n throw error;\n }\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. Must be a valid URL.`,\n );\n }\n }\n\n return new SentryApiService({\n host,\n accessToken: context.accessToken,\n });\n}\n"],"mappings":";;;;;;;;;;;AAWA,SAAgB,sBACdA,SACAC,OAA+B,CAAE,GACjC;CACA,IAAI,OAAO,QAAQ;AAEnB,KAAI,KAAK,WAAW,MAAM,CACxB,KAAI;EACF,MAAM,YAAY,IAAI,IAAI,KAAK;AAG/B,OAAK,CAAC,SAAS,QAAS,EAAC,SAAS,UAAU,SAAS,CACnD,OAAM,IAAI,gBACP,8BAA8B,KAAK,UAAU;AAKlD,MAAI,UAAU,SAAS,WAAW,UAAU,SAAS,OACnD,OAAM,IAAI,gBACP,8BAA8B,KAAK,UAAU;AAIlD,SAAO,UAAU;CAClB,SAAQ,OAAO;AACd,MAAI,iBAAiB,eACnB,OAAM;AAER,QAAM,IAAI,gBACP,8BAA8B,KAAK,UAAU;CAEjD;AAGH,QAAO,IAAI,iBAAiB;EAC1B;EACA,aAAa,QAAQ;CACtB;AACF"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
const require_errors = require('./errors-YmiXLOyx.cjs');
|
|
2
|
+
const require_client = require('./client-Dkw5iYu3.cjs');
|
|
3
|
+
|
|
4
|
+
//#region src/tools/utils/api-utils.ts
|
|
5
|
+
/**
|
|
6
|
+
* Create a Sentry API service from server context with optional region override
|
|
7
|
+
* @param context - Server context containing host and access token
|
|
8
|
+
* @param opts - Options object containing optional regionUrl override
|
|
9
|
+
* @returns Configured SentryApiService instance (always uses HTTPS)
|
|
10
|
+
* @throws {UserInputError} When regionUrl is provided but invalid
|
|
11
|
+
*/
|
|
12
|
+
function apiServiceFromContext(context, opts = {}) {
|
|
13
|
+
let host = context.sentryHost;
|
|
14
|
+
if (opts.regionUrl?.trim()) try {
|
|
15
|
+
const parsedUrl = new URL(opts.regionUrl);
|
|
16
|
+
if (!["http:", "https:"].includes(parsedUrl.protocol)) throw new require_errors.UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. Must include protocol (http:// or https://).`);
|
|
17
|
+
if (parsedUrl.host === "https" || parsedUrl.host === "http") throw new require_errors.UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. The host cannot be just a protocol name.`);
|
|
18
|
+
host = parsedUrl.host;
|
|
19
|
+
} catch (error) {
|
|
20
|
+
if (error instanceof require_errors.UserInputError) throw error;
|
|
21
|
+
throw new require_errors.UserInputError(`Invalid regionUrl provided: ${opts.regionUrl}. Must be a valid URL.`);
|
|
22
|
+
}
|
|
23
|
+
return new require_client.SentryApiService({
|
|
24
|
+
host,
|
|
25
|
+
accessToken: context.accessToken
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
//#endregion
|
|
30
|
+
Object.defineProperty(exports, 'apiServiceFromContext', {
|
|
31
|
+
enumerable: true,
|
|
32
|
+
get: function () {
|
|
33
|
+
return apiServiceFromContext;
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
//# sourceMappingURL=api-utils-d36iteNO.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-utils-d36iteNO.cjs","names":["context: ServerContext","opts: { regionUrl?: string }","UserInputError","SentryApiService"],"sources":["../src/tools/utils/api-utils.ts"],"sourcesContent":["import { SentryApiService } from \"../../api-client/index\";\nimport { UserInputError } from \"../../errors\";\nimport type { ServerContext } from \"../../types\";\n\n/**\n * Create a Sentry API service from server context with optional region override\n * @param context - Server context containing host and access token\n * @param opts - Options object containing optional regionUrl override\n * @returns Configured SentryApiService instance (always uses HTTPS)\n * @throws {UserInputError} When regionUrl is provided but invalid\n */\nexport function apiServiceFromContext(\n context: ServerContext,\n opts: { regionUrl?: string } = {},\n) {\n let host = context.sentryHost;\n\n if (opts.regionUrl?.trim()) {\n try {\n const parsedUrl = new URL(opts.regionUrl);\n\n // Validate that the URL has a proper protocol\n if (![\"http:\", \"https:\"].includes(parsedUrl.protocol)) {\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. Must include protocol (http:// or https://).`,\n );\n }\n\n // Validate that the host is not just the protocol name\n if (parsedUrl.host === \"https\" || parsedUrl.host === \"http\") {\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. The host cannot be just a protocol name.`,\n );\n }\n\n host = parsedUrl.host;\n } catch (error) {\n if (error instanceof UserInputError) {\n throw error;\n }\n throw new UserInputError(\n `Invalid regionUrl provided: ${opts.regionUrl}. Must be a valid URL.`,\n );\n }\n }\n\n return new SentryApiService({\n host,\n accessToken: context.accessToken,\n });\n}\n"],"mappings":";;;;;;;;;;;AAWA,SAAgB,sBACdA,SACAC,OAA+B,CAAE,GACjC;CACA,IAAI,OAAO,QAAQ;AAEnB,KAAI,KAAK,WAAW,MAAM,CACxB,KAAI;EACF,MAAM,YAAY,IAAI,IAAI,KAAK;AAG/B,OAAK,CAAC,SAAS,QAAS,EAAC,SAAS,UAAU,SAAS,CACnD,OAAM,IAAIC,+BACP,8BAA8B,KAAK,UAAU;AAKlD,MAAI,UAAU,SAAS,WAAW,UAAU,SAAS,OACnD,OAAM,IAAIA,+BACP,8BAA8B,KAAK,UAAU;AAIlD,SAAO,UAAU;CAClB,SAAQ,OAAO;AACd,MAAI,iBAAiBA,8BACnB,OAAM;AAER,QAAM,IAAIA,+BACP,8BAA8B,KAAK,UAAU;CAEjD;AAGH,QAAO,IAAIC,gCAAiB;EAC1B;EACA,aAAa,QAAQ;CACtB;AACF"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, OrganizationList, Project, ProjectList, ReleaseList, TagList, Team, TeamList, User } from "./types-
|
|
1
|
+
import { AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, OrganizationList, Project, ProjectList, ReleaseList, TagList, Team, TeamList, User } from "./types-CtTBwGbw.js";
|
|
2
2
|
|
|
3
3
|
//#region src/api-client/client.d.ts
|
|
4
4
|
|
|
@@ -39,6 +39,7 @@ type RequestOptions = {
|
|
|
39
39
|
* - Enhanced error handling with LLM-friendly messages
|
|
40
40
|
* - URL generation for Sentry resources (issues, traces)
|
|
41
41
|
* - Bearer token authentication
|
|
42
|
+
* - Always uses HTTPS for secure connections
|
|
42
43
|
*
|
|
43
44
|
* @example Basic Usage
|
|
44
45
|
* ```typescript
|
|
@@ -56,7 +57,7 @@ type RequestOptions = {
|
|
|
56
57
|
*
|
|
57
58
|
* @example Multi-Region Support
|
|
58
59
|
* ```typescript
|
|
59
|
-
* // Self-hosted instance
|
|
60
|
+
* // Self-hosted instance with hostname
|
|
60
61
|
* const selfHosted = new SentryApiService({
|
|
61
62
|
* accessToken: "token",
|
|
62
63
|
* host: "sentry.company.com"
|
|
@@ -76,9 +77,11 @@ declare class SentryApiService {
|
|
|
76
77
|
/**
|
|
77
78
|
* Creates a new Sentry API service instance.
|
|
78
79
|
*
|
|
80
|
+
* Always uses HTTPS for secure connections.
|
|
81
|
+
*
|
|
79
82
|
* @param config Configuration object
|
|
80
83
|
* @param config.accessToken OAuth access token for authentication (optional for some endpoints)
|
|
81
|
-
* @param config.host Sentry
|
|
84
|
+
* @param config.host Sentry hostname (e.g. "sentry.io", "sentry.example.com")
|
|
82
85
|
*/
|
|
83
86
|
constructor({
|
|
84
87
|
accessToken,
|
|
@@ -91,8 +94,9 @@ declare class SentryApiService {
|
|
|
91
94
|
* Updates the host for API requests.
|
|
92
95
|
*
|
|
93
96
|
* Used for multi-region support or switching between Sentry instances.
|
|
97
|
+
* Always uses HTTPS protocol.
|
|
94
98
|
*
|
|
95
|
-
* @param host New
|
|
99
|
+
* @param host New hostname to use for API requests
|
|
96
100
|
*/
|
|
97
101
|
setHost(host: string): void;
|
|
98
102
|
/**
|
|
@@ -116,10 +120,11 @@ declare class SentryApiService {
|
|
|
116
120
|
* Generates a Sentry issue URL for browser navigation.
|
|
117
121
|
*
|
|
118
122
|
* Handles both SaaS (subdomain-based) and self-hosted URL formats.
|
|
123
|
+
* Always uses HTTPS protocol.
|
|
119
124
|
*
|
|
120
125
|
* @param organizationSlug Organization identifier
|
|
121
126
|
* @param issueId Issue identifier (short ID or numeric ID)
|
|
122
|
-
* @returns Full
|
|
127
|
+
* @returns Full URL to the issue in Sentry UI
|
|
123
128
|
*
|
|
124
129
|
* @example
|
|
125
130
|
* ```typescript
|
|
@@ -134,6 +139,8 @@ declare class SentryApiService {
|
|
|
134
139
|
/**
|
|
135
140
|
* Generates a Sentry trace URL for performance investigation.
|
|
136
141
|
*
|
|
142
|
+
* Always uses HTTPS protocol.
|
|
143
|
+
*
|
|
137
144
|
* @param organizationSlug Organization identifier
|
|
138
145
|
* @param traceId Trace identifier (hex string)
|
|
139
146
|
* @returns Full HTTPS URL to the trace in Sentry UI
|
|
@@ -443,6 +450,31 @@ declare class SentryApiService {
|
|
|
443
450
|
organizationSlug: string;
|
|
444
451
|
issueId: string;
|
|
445
452
|
}, opts?: RequestOptions): Promise<Event>;
|
|
453
|
+
listEventAttachments({
|
|
454
|
+
organizationSlug,
|
|
455
|
+
projectSlug,
|
|
456
|
+
eventId
|
|
457
|
+
}: {
|
|
458
|
+
organizationSlug: string;
|
|
459
|
+
projectSlug: string;
|
|
460
|
+
eventId: string;
|
|
461
|
+
}, opts?: RequestOptions): Promise<EventAttachmentList>;
|
|
462
|
+
getEventAttachment({
|
|
463
|
+
organizationSlug,
|
|
464
|
+
projectSlug,
|
|
465
|
+
eventId,
|
|
466
|
+
attachmentId
|
|
467
|
+
}: {
|
|
468
|
+
organizationSlug: string;
|
|
469
|
+
projectSlug: string;
|
|
470
|
+
eventId: string;
|
|
471
|
+
attachmentId: string;
|
|
472
|
+
}, opts?: RequestOptions): Promise<{
|
|
473
|
+
attachment: EventAttachment;
|
|
474
|
+
downloadUrl: string;
|
|
475
|
+
filename: string;
|
|
476
|
+
blob: Blob;
|
|
477
|
+
}>;
|
|
446
478
|
updateIssue({
|
|
447
479
|
organizationSlug,
|
|
448
480
|
issueId,
|
|
@@ -470,9 +502,9 @@ declare class SentryApiService {
|
|
|
470
502
|
sortBy?: "last_seen" | "count";
|
|
471
503
|
}, opts?: RequestOptions): Promise<{
|
|
472
504
|
issue: string;
|
|
473
|
-
title: string;
|
|
474
|
-
project: string;
|
|
475
505
|
"issue.id": string | number;
|
|
506
|
+
project: string;
|
|
507
|
+
title: string;
|
|
476
508
|
"count()": number;
|
|
477
509
|
"last_seen()": string;
|
|
478
510
|
}[]>;
|
|
@@ -489,14 +521,14 @@ declare class SentryApiService {
|
|
|
489
521
|
query?: string;
|
|
490
522
|
sortBy?: "timestamp" | "duration";
|
|
491
523
|
}, opts?: RequestOptions): Promise<{
|
|
492
|
-
id: string;
|
|
493
524
|
project: string;
|
|
494
|
-
|
|
495
|
-
timestamp: string;
|
|
525
|
+
id: string;
|
|
496
526
|
trace: string;
|
|
497
527
|
"span.op": string;
|
|
498
528
|
"span.description": string;
|
|
499
529
|
"span.duration": number;
|
|
530
|
+
transaction: string;
|
|
531
|
+
timestamp: string;
|
|
500
532
|
}[]>;
|
|
501
533
|
startAutofix({
|
|
502
534
|
organizationSlug,
|
|
@@ -519,4 +551,4 @@ declare class SentryApiService {
|
|
|
519
551
|
}
|
|
520
552
|
//#endregion
|
|
521
553
|
export { ApiError, SentryApiService };
|
|
522
|
-
//# sourceMappingURL=client-
|
|
554
|
+
//# sourceMappingURL=client-BCN17Wbp.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client-BCN17Wbp.d.ts","names":[],"sources":["../src/api-client/client.ts"],"sourcesContent":[],"mappings":";;;;;;AA0EA;AAkBC;AAkDD;;;;;;;;;;;;;AA0RM,cA9VO,QAAA,SAAiB,KAAK,CA8V7B;EAAgB,MAChB,EAAA,MAAA;EAAI,WAKC,CAAA,OAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA;;KAhVN,cAAA,GAiVA;EAAO,IAsBD,CAAA,EAAA,MAAA;CAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiVnB,cAxoBO,gBAAA,CAwoBP;EAAW,QACX,WAAA;EAAK,UACL,IAAA,EAAA,MAAA;EAAM,UAOD,SAAA,EAAA,MAAA;EAAc;;;;;;;;;EAiDZ,WACP,CAAA;IAAA,WAAA;IAAA;EAOY,CAPZ,EAAA;IAMK,WAAA,CAAA,EAAA,MAAA,GAAA,IAAA;IACE,IAAA,CAAA,EAAA,MAAA;EAAK,CAAA;EAAN;;;;;;;;EAmCC,OAMF,CAAA,IAAA,EAAA,MAAA,CAAA,EAAA,IAAA;EAAc;;;;;;;;;;;;;;;;EAmFP,QAAb,OAAA;EAAO;;;;;;;;;;;;;;;;;;;EA2JU,WAOX,CAAA,gBAAA,EAAA,MAAA,EAAA,OAAA,EAAA,MAAA,CAAA,EAAA,MAAA;EAAc;;;;;;;AA2Bb;;;;;;;;;;;;;;;;8BAzzBwB,iBAAiB,QAAQ;;;;;;;;;;;;;;;;;;;2BAwB5B,iBAAiB,QAAQ;;;;;;;;6CAgC/C,iBACN,QAAQ;;;;;;;;;;;;;;;;;YA6BF,iBACN,QAAQ;;;;;;;;gDAsBF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;YAkCF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;YAyCF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;YAoCF,iBACN;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA2CM,iBACN,QAAQ;;;;;;;;;;;;;;;;YA+BF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA2CF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;YAgDF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA8DF,iBACN,QAAQ;;;;;;;YAiCF,iBACN,QAAQ;;;;;;;;;YAqBF,iBACN,QAAQ;;;;;;;YAmBF,iBACN,QAAQ;;;;;;;;;YAqBF,iBACN,QAAQ;;;;;;;;;;;YAuBF,iBACN;gBACW;;;UAGN;;;;;;;;;;;;YAqDC,iBACN,QAAQ;;;;;;;;;;;;;;;YAkDF,iBAAc;;;;;;;;;;;;;;;;;;;;YAyDd,iBAAc;;;;;;;;;;;;;;;;;;;;YAuDd,iBACN,QAAQ;;;;;;;YAyBF,iBACN,QAAQ"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, Issue, IssueList, OrganizationList, Project, ProjectList, ReleaseList, TagList, Team, TeamList, User } from "./types-
|
|
1
|
+
import { AutofixRun, AutofixRunState, ClientKey, ClientKeyList, Event, EventAttachment, EventAttachmentList, Issue, IssueList, OrganizationList, Project, ProjectList, ReleaseList, TagList, Team, TeamList, User } from "./types-Bg17IGWJ.cjs";
|
|
2
2
|
|
|
3
3
|
//#region src/api-client/client.d.ts
|
|
4
4
|
|
|
@@ -39,6 +39,7 @@ type RequestOptions = {
|
|
|
39
39
|
* - Enhanced error handling with LLM-friendly messages
|
|
40
40
|
* - URL generation for Sentry resources (issues, traces)
|
|
41
41
|
* - Bearer token authentication
|
|
42
|
+
* - Always uses HTTPS for secure connections
|
|
42
43
|
*
|
|
43
44
|
* @example Basic Usage
|
|
44
45
|
* ```typescript
|
|
@@ -56,7 +57,7 @@ type RequestOptions = {
|
|
|
56
57
|
*
|
|
57
58
|
* @example Multi-Region Support
|
|
58
59
|
* ```typescript
|
|
59
|
-
* // Self-hosted instance
|
|
60
|
+
* // Self-hosted instance with hostname
|
|
60
61
|
* const selfHosted = new SentryApiService({
|
|
61
62
|
* accessToken: "token",
|
|
62
63
|
* host: "sentry.company.com"
|
|
@@ -76,9 +77,11 @@ declare class SentryApiService {
|
|
|
76
77
|
/**
|
|
77
78
|
* Creates a new Sentry API service instance.
|
|
78
79
|
*
|
|
80
|
+
* Always uses HTTPS for secure connections.
|
|
81
|
+
*
|
|
79
82
|
* @param config Configuration object
|
|
80
83
|
* @param config.accessToken OAuth access token for authentication (optional for some endpoints)
|
|
81
|
-
* @param config.host Sentry
|
|
84
|
+
* @param config.host Sentry hostname (e.g. "sentry.io", "sentry.example.com")
|
|
82
85
|
*/
|
|
83
86
|
constructor({
|
|
84
87
|
accessToken,
|
|
@@ -91,8 +94,9 @@ declare class SentryApiService {
|
|
|
91
94
|
* Updates the host for API requests.
|
|
92
95
|
*
|
|
93
96
|
* Used for multi-region support or switching between Sentry instances.
|
|
97
|
+
* Always uses HTTPS protocol.
|
|
94
98
|
*
|
|
95
|
-
* @param host New
|
|
99
|
+
* @param host New hostname to use for API requests
|
|
96
100
|
*/
|
|
97
101
|
setHost(host: string): void;
|
|
98
102
|
/**
|
|
@@ -116,10 +120,11 @@ declare class SentryApiService {
|
|
|
116
120
|
* Generates a Sentry issue URL for browser navigation.
|
|
117
121
|
*
|
|
118
122
|
* Handles both SaaS (subdomain-based) and self-hosted URL formats.
|
|
123
|
+
* Always uses HTTPS protocol.
|
|
119
124
|
*
|
|
120
125
|
* @param organizationSlug Organization identifier
|
|
121
126
|
* @param issueId Issue identifier (short ID or numeric ID)
|
|
122
|
-
* @returns Full
|
|
127
|
+
* @returns Full URL to the issue in Sentry UI
|
|
123
128
|
*
|
|
124
129
|
* @example
|
|
125
130
|
* ```typescript
|
|
@@ -134,6 +139,8 @@ declare class SentryApiService {
|
|
|
134
139
|
/**
|
|
135
140
|
* Generates a Sentry trace URL for performance investigation.
|
|
136
141
|
*
|
|
142
|
+
* Always uses HTTPS protocol.
|
|
143
|
+
*
|
|
137
144
|
* @param organizationSlug Organization identifier
|
|
138
145
|
* @param traceId Trace identifier (hex string)
|
|
139
146
|
* @returns Full HTTPS URL to the trace in Sentry UI
|
|
@@ -443,6 +450,31 @@ declare class SentryApiService {
|
|
|
443
450
|
organizationSlug: string;
|
|
444
451
|
issueId: string;
|
|
445
452
|
}, opts?: RequestOptions): Promise<Event>;
|
|
453
|
+
listEventAttachments({
|
|
454
|
+
organizationSlug,
|
|
455
|
+
projectSlug,
|
|
456
|
+
eventId
|
|
457
|
+
}: {
|
|
458
|
+
organizationSlug: string;
|
|
459
|
+
projectSlug: string;
|
|
460
|
+
eventId: string;
|
|
461
|
+
}, opts?: RequestOptions): Promise<EventAttachmentList>;
|
|
462
|
+
getEventAttachment({
|
|
463
|
+
organizationSlug,
|
|
464
|
+
projectSlug,
|
|
465
|
+
eventId,
|
|
466
|
+
attachmentId
|
|
467
|
+
}: {
|
|
468
|
+
organizationSlug: string;
|
|
469
|
+
projectSlug: string;
|
|
470
|
+
eventId: string;
|
|
471
|
+
attachmentId: string;
|
|
472
|
+
}, opts?: RequestOptions): Promise<{
|
|
473
|
+
attachment: EventAttachment;
|
|
474
|
+
downloadUrl: string;
|
|
475
|
+
filename: string;
|
|
476
|
+
blob: Blob;
|
|
477
|
+
}>;
|
|
446
478
|
updateIssue({
|
|
447
479
|
organizationSlug,
|
|
448
480
|
issueId,
|
|
@@ -470,9 +502,9 @@ declare class SentryApiService {
|
|
|
470
502
|
sortBy?: "last_seen" | "count";
|
|
471
503
|
}, opts?: RequestOptions): Promise<{
|
|
472
504
|
issue: string;
|
|
473
|
-
title: string;
|
|
474
|
-
project: string;
|
|
475
505
|
"issue.id": string | number;
|
|
506
|
+
project: string;
|
|
507
|
+
title: string;
|
|
476
508
|
"count()": number;
|
|
477
509
|
"last_seen()": string;
|
|
478
510
|
}[]>;
|
|
@@ -489,14 +521,14 @@ declare class SentryApiService {
|
|
|
489
521
|
query?: string;
|
|
490
522
|
sortBy?: "timestamp" | "duration";
|
|
491
523
|
}, opts?: RequestOptions): Promise<{
|
|
492
|
-
id: string;
|
|
493
524
|
project: string;
|
|
494
|
-
|
|
495
|
-
timestamp: string;
|
|
525
|
+
id: string;
|
|
496
526
|
trace: string;
|
|
497
527
|
"span.op": string;
|
|
498
528
|
"span.description": string;
|
|
499
529
|
"span.duration": number;
|
|
530
|
+
transaction: string;
|
|
531
|
+
timestamp: string;
|
|
500
532
|
}[]>;
|
|
501
533
|
startAutofix({
|
|
502
534
|
organizationSlug,
|
|
@@ -519,4 +551,4 @@ declare class SentryApiService {
|
|
|
519
551
|
}
|
|
520
552
|
//#endregion
|
|
521
553
|
export { ApiError, SentryApiService };
|
|
522
|
-
//# sourceMappingURL=client-
|
|
554
|
+
//# sourceMappingURL=client-CILwfx6G.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client-CILwfx6G.d.cts","names":[],"sources":["../src/api-client/client.ts"],"sourcesContent":[],"mappings":";;;;;;AA0EA;AAkBC;AAkDD;;;;;;;;;;;;;AA0RM,cA9VO,QAAA,SAAiB,KAAK,CA8V7B;EAAgB,MAChB,EAAA,MAAA;EAAI,WAKC,CAAA,OAAA,EAAA,MAAA,EAAA,MAAA,EAAA,MAAA;;KAhVN,cAAA,GAiVA;EAAO,IAsBD,CAAA,EAAA,MAAA;CAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAiVnB,cAxoBO,gBAAA,CAwoBP;EAAW,QACX,WAAA;EAAK,UACL,IAAA,EAAA,MAAA;EAAM,UAOD,SAAA,EAAA,MAAA;EAAc;;;;;;;;;EAiDZ,WACP,CAAA;IAAA,WAAA;IAAA;EAOY,CAPZ,EAAA;IAMK,WAAA,CAAA,EAAA,MAAA,GAAA,IAAA;IACE,IAAA,CAAA,EAAA,MAAA;EAAK,CAAA;EAAN;;;;;;;;EAmCC,OAMF,CAAA,IAAA,EAAA,MAAA,CAAA,EAAA,IAAA;EAAc;;;;;;;;;;;;;;;;EAmFP,QAAb,OAAA;EAAO;;;;;;;;;;;;;;;;;;;EA2JU,WAOX,CAAA,gBAAA,EAAA,MAAA,EAAA,OAAA,EAAA,MAAA,CAAA,EAAA,MAAA;EAAc;;;;;;;AA2Bb;;;;;;;;;;;;;;;;8BAzzBwB,iBAAiB,QAAQ;;;;;;;;;;;;;;;;;;;2BAwB5B,iBAAiB,QAAQ;;;;;;;;6CAgC/C,iBACN,QAAQ;;;;;;;;;;;;;;;;;YA6BF,iBACN,QAAQ;;;;;;;;gDAsBF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;YAkCF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;YAyCF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;YAoCF,iBACN;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA2CM,iBACN,QAAQ;;;;;;;;;;;;;;;;YA+BF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA2CF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;YAgDF,iBACN,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA8DF,iBACN,QAAQ;;;;;;;YAiCF,iBACN,QAAQ;;;;;;;;;YAqBF,iBACN,QAAQ;;;;;;;YAmBF,iBACN,QAAQ;;;;;;;;;YAqBF,iBACN,QAAQ;;;;;;;;;;;YAuBF,iBACN;gBACW;;;UAGN;;;;;;;;;;;;YAqDC,iBACN,QAAQ;;;;;;;;;;;;;;;YAkDF,iBAAc;;;;;;;;;;;;;;;;;;;;YAyDd,iBAAc;;;;;;;;;;;;;;;;;;;;YAuDd,iBACN,QAAQ;;;;;;;YAyBF,iBACN,QAAQ"}
|
|
@@ -1,7 +1,18 @@
|
|
|
1
|
-
import { ApiErrorSchema, AutofixRunSchema, AutofixRunStateSchema, ClientKeyListSchema, ClientKeySchema, ErrorsSearchResponseSchema, EventSchema, IssueListSchema, IssueSchema, OrganizationListSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, SpansSearchResponseSchema, TagListSchema, TeamListSchema, TeamSchema, UserRegionsSchema, UserSchema } from "./schema-
|
|
1
|
+
import { ApiErrorSchema, AutofixRunSchema, AutofixRunStateSchema, ClientKeyListSchema, ClientKeySchema, ErrorsSearchResponseSchema, EventAttachmentListSchema, EventSchema, IssueListSchema, IssueSchema, OrganizationListSchema, ProjectListSchema, ProjectSchema, ReleaseListSchema, SpansSearchResponseSchema, TagListSchema, TeamListSchema, TeamSchema, UserRegionsSchema, UserSchema } from "./schema-WDk5Yqww.js";
|
|
2
2
|
|
|
3
3
|
//#region src/api-client/client.ts
|
|
4
4
|
/**
|
|
5
|
+
* Mapping of common network error codes to user-friendly messages.
|
|
6
|
+
* These help users understand and resolve connection issues.
|
|
7
|
+
*/
|
|
8
|
+
const NETWORK_ERROR_MESSAGES = {
|
|
9
|
+
EAI_AGAIN: "DNS temporarily unavailable. Check your internet connection.",
|
|
10
|
+
ENOTFOUND: "Hostname not found. Verify the URL is correct.",
|
|
11
|
+
ECONNREFUSED: "Connection refused. Ensure the service is accessible.",
|
|
12
|
+
ETIMEDOUT: "Connection timed out. Check network connectivity.",
|
|
13
|
+
ECONNRESET: "Connection reset. Try again in a moment."
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
5
16
|
* Custom error class for Sentry API responses.
|
|
6
17
|
*
|
|
7
18
|
* Provides enhanced error messages for LLM consumption and handles
|
|
@@ -39,6 +50,7 @@ var ApiError = class extends Error {
|
|
|
39
50
|
* - Enhanced error handling with LLM-friendly messages
|
|
40
51
|
* - URL generation for Sentry resources (issues, traces)
|
|
41
52
|
* - Bearer token authentication
|
|
53
|
+
* - Always uses HTTPS for secure connections
|
|
42
54
|
*
|
|
43
55
|
* @example Basic Usage
|
|
44
56
|
* ```typescript
|
|
@@ -56,7 +68,7 @@ var ApiError = class extends Error {
|
|
|
56
68
|
*
|
|
57
69
|
* @example Multi-Region Support
|
|
58
70
|
* ```typescript
|
|
59
|
-
* // Self-hosted instance
|
|
71
|
+
* // Self-hosted instance with hostname
|
|
60
72
|
* const selfHosted = new SentryApiService({
|
|
61
73
|
* accessToken: "token",
|
|
62
74
|
* host: "sentry.company.com"
|
|
@@ -76,25 +88,28 @@ var SentryApiService = class {
|
|
|
76
88
|
/**
|
|
77
89
|
* Creates a new Sentry API service instance.
|
|
78
90
|
*
|
|
91
|
+
* Always uses HTTPS for secure connections.
|
|
92
|
+
*
|
|
79
93
|
* @param config Configuration object
|
|
80
94
|
* @param config.accessToken OAuth access token for authentication (optional for some endpoints)
|
|
81
|
-
* @param config.host Sentry
|
|
95
|
+
* @param config.host Sentry hostname (e.g. "sentry.io", "sentry.example.com")
|
|
82
96
|
*/
|
|
83
|
-
constructor({ accessToken = null, host =
|
|
97
|
+
constructor({ accessToken = null, host = "sentry.io" }) {
|
|
84
98
|
this.accessToken = accessToken;
|
|
85
|
-
this.host = host
|
|
86
|
-
this.apiPrefix =
|
|
99
|
+
this.host = host;
|
|
100
|
+
this.apiPrefix = `https://${host}/api/0`;
|
|
87
101
|
}
|
|
88
102
|
/**
|
|
89
103
|
* Updates the host for API requests.
|
|
90
104
|
*
|
|
91
105
|
* Used for multi-region support or switching between Sentry instances.
|
|
106
|
+
* Always uses HTTPS protocol.
|
|
92
107
|
*
|
|
93
|
-
* @param host New
|
|
108
|
+
* @param host New hostname to use for API requests
|
|
94
109
|
*/
|
|
95
110
|
setHost(host) {
|
|
96
111
|
this.host = host;
|
|
97
|
-
this.apiPrefix =
|
|
112
|
+
this.apiPrefix = `https://${this.host}/api/0`;
|
|
98
113
|
}
|
|
99
114
|
/**
|
|
100
115
|
* Internal method for making authenticated requests to Sentry API.
|
|
@@ -113,14 +128,29 @@ var SentryApiService = class {
|
|
|
113
128
|
* @throws {Error} Network or parsing errors
|
|
114
129
|
*/
|
|
115
130
|
async request(path, options = {}, { host } = {}) {
|
|
116
|
-
const url = host ?
|
|
117
|
-
const headers = {
|
|
131
|
+
const url = host ? `https://${host}/api/0${path}` : `${this.apiPrefix}${path}`;
|
|
132
|
+
const headers = {
|
|
133
|
+
"Content-Type": "application/json",
|
|
134
|
+
"User-Agent": "Sentry MCP Server"
|
|
135
|
+
};
|
|
118
136
|
if (this.accessToken) headers.Authorization = `Bearer ${this.accessToken}`;
|
|
119
137
|
if (typeof globalThis.fetch === "undefined") throw new Error("fetch is not available. Please use Node.js >= 18 or ensure fetch is available in your environment.");
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
138
|
+
let response;
|
|
139
|
+
try {
|
|
140
|
+
response = await fetch(url, {
|
|
141
|
+
...options,
|
|
142
|
+
headers
|
|
143
|
+
});
|
|
144
|
+
} catch (error) {
|
|
145
|
+
let rootCause = error;
|
|
146
|
+
while (rootCause instanceof Error && rootCause.cause) rootCause = rootCause.cause;
|
|
147
|
+
const errorMessage = rootCause instanceof Error ? rootCause.message : String(rootCause);
|
|
148
|
+
let friendlyMessage = `Unable to connect to ${url}`;
|
|
149
|
+
const errorCode = Object.keys(NETWORK_ERROR_MESSAGES).find((code) => errorMessage.includes(code));
|
|
150
|
+
if (errorCode) friendlyMessage += ` - ${NETWORK_ERROR_MESSAGES[errorCode]}`;
|
|
151
|
+
else friendlyMessage += ` - ${errorMessage}`;
|
|
152
|
+
throw new Error(friendlyMessage, { cause: error });
|
|
153
|
+
}
|
|
124
154
|
if (!response.ok) {
|
|
125
155
|
const errorText = await response.text();
|
|
126
156
|
let parsed;
|
|
@@ -142,10 +172,11 @@ var SentryApiService = class {
|
|
|
142
172
|
* Generates a Sentry issue URL for browser navigation.
|
|
143
173
|
*
|
|
144
174
|
* Handles both SaaS (subdomain-based) and self-hosted URL formats.
|
|
175
|
+
* Always uses HTTPS protocol.
|
|
145
176
|
*
|
|
146
177
|
* @param organizationSlug Organization identifier
|
|
147
178
|
* @param issueId Issue identifier (short ID or numeric ID)
|
|
148
|
-
* @returns Full
|
|
179
|
+
* @returns Full URL to the issue in Sentry UI
|
|
149
180
|
*
|
|
150
181
|
* @example
|
|
151
182
|
* ```typescript
|
|
@@ -157,11 +188,14 @@ var SentryApiService = class {
|
|
|
157
188
|
* ```
|
|
158
189
|
*/
|
|
159
190
|
getIssueUrl(organizationSlug, issueId) {
|
|
160
|
-
|
|
191
|
+
const isSaas = this.host === "sentry.io";
|
|
192
|
+
return isSaas ? `https://${organizationSlug}.${this.host}/issues/${issueId}` : `https://${this.host}/organizations/${organizationSlug}/issues/${issueId}`;
|
|
161
193
|
}
|
|
162
194
|
/**
|
|
163
195
|
* Generates a Sentry trace URL for performance investigation.
|
|
164
196
|
*
|
|
197
|
+
* Always uses HTTPS protocol.
|
|
198
|
+
*
|
|
165
199
|
* @param organizationSlug Organization identifier
|
|
166
200
|
* @param traceId Trace identifier (hex string)
|
|
167
201
|
* @returns Full HTTPS URL to the trace in Sentry UI
|
|
@@ -173,7 +207,8 @@ var SentryApiService = class {
|
|
|
173
207
|
* ```
|
|
174
208
|
*/
|
|
175
209
|
getTraceUrl(organizationSlug, traceId) {
|
|
176
|
-
|
|
210
|
+
const isSaas = this.host === "sentry.io";
|
|
211
|
+
return isSaas ? `https://${organizationSlug}.${this.host}/explore/traces/trace/${traceId}` : `https://${this.host}/organizations/${organizationSlug}/explore/traces/trace/${traceId}`;
|
|
177
212
|
}
|
|
178
213
|
/**
|
|
179
214
|
* Retrieves the authenticated user's profile information.
|
|
@@ -478,6 +513,28 @@ var SentryApiService = class {
|
|
|
478
513
|
eventId: "latest"
|
|
479
514
|
}, opts);
|
|
480
515
|
}
|
|
516
|
+
async listEventAttachments({ organizationSlug, projectSlug, eventId }, opts) {
|
|
517
|
+
const response = await this.request(`/projects/${organizationSlug}/${projectSlug}/events/${eventId}/attachments/`, void 0, opts);
|
|
518
|
+
const body = await response.json();
|
|
519
|
+
return EventAttachmentListSchema.parse(body);
|
|
520
|
+
}
|
|
521
|
+
async getEventAttachment({ organizationSlug, projectSlug, eventId, attachmentId }, opts) {
|
|
522
|
+
const attachmentsResponse = await this.request(`/projects/${organizationSlug}/${projectSlug}/events/${eventId}/attachments/`, void 0, opts);
|
|
523
|
+
const attachments = EventAttachmentListSchema.parse(await attachmentsResponse.json());
|
|
524
|
+
const attachment = attachments.find((att) => att.id === attachmentId);
|
|
525
|
+
if (!attachment) throw new Error(`Attachment with ID ${attachmentId} not found for event ${eventId}`);
|
|
526
|
+
const downloadUrl = `/projects/${organizationSlug}/${projectSlug}/events/${eventId}/attachments/${attachmentId}/?download=1`;
|
|
527
|
+
const downloadResponse = await this.request(downloadUrl, {
|
|
528
|
+
method: "GET",
|
|
529
|
+
headers: { Accept: "application/octet-stream" }
|
|
530
|
+
}, opts);
|
|
531
|
+
return {
|
|
532
|
+
attachment,
|
|
533
|
+
downloadUrl: downloadResponse.url,
|
|
534
|
+
filename: attachment.name,
|
|
535
|
+
blob: await downloadResponse.blob()
|
|
536
|
+
};
|
|
537
|
+
}
|
|
481
538
|
async updateIssue({ organizationSlug, issueId, status, assignedTo }, opts) {
|
|
482
539
|
const updateData = {};
|
|
483
540
|
if (status !== void 0) updateData.status = status;
|
|
@@ -558,4 +615,4 @@ var SentryApiService = class {
|
|
|
558
615
|
|
|
559
616
|
//#endregion
|
|
560
617
|
export { ApiError, SentryApiService };
|
|
561
|
-
//# sourceMappingURL=client-
|
|
618
|
+
//# sourceMappingURL=client-DOYWNvVM.js.map
|