From f93e4349e5dec46b708dcf61da67e042a0863f91 Mon Sep 17 00:00:00 2001 From: rodion Date: Wed, 20 Oct 2021 11:39:57 +0300 Subject: [PATCH] fix: sentry-plugin corrected api parameter name according to documentation https://docs.sentry.io/api/events/list-a-projects-issues/ Signed-off-by: rodion --- .changeset/large-dragons-design.md | 5 +++++ plugins/sentry/src/api/production-api.ts | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .changeset/large-dragons-design.md diff --git a/.changeset/large-dragons-design.md b/.changeset/large-dragons-design.md new file mode 100644 index 0000000000..e1d5a913fe --- /dev/null +++ b/.changeset/large-dragons-design.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-sentry': patch +--- + +fix: parameter name on call to sentry api diff --git a/plugins/sentry/src/api/production-api.ts b/plugins/sentry/src/api/production-api.ts index 0e7f5b784d..e634650f96 100644 --- a/plugins/sentry/src/api/production-api.ts +++ b/plugins/sentry/src/api/production-api.ts @@ -32,7 +32,7 @@ export class ProductionSentryApi implements SentryApi { const apiUrl = `${await this.discoveryApi.getBaseUrl('proxy')}/sentry/api`; const response = await fetch( - `${apiUrl}/0/projects/${this.organization}/${project}/issues/?statsFor=${statsFor}`, + `${apiUrl}/0/projects/${this.organization}/${project}/issues/?statsPeriod=${statsFor}`, ); if (response.status >= 400 && response.status < 600) {