@sentry/api 0.169.0 → 0.171.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.
@@ -0,0 +1,40 @@
1
+ /**
2
+ * Browser auth utilities for @sentry/api.
3
+ *
4
+ * Provides a fetch wrapper that handles cookie-based session auth and
5
+ * CSRF token injection, allowing the SDK to be used inside the Sentry
6
+ * frontend without a Bearer token.
7
+ */
8
+ /** Matches the standard fetch signature without Bun/Node runtime extensions. */
9
+ export type FetchFn = (input: RequestInfo | URL, init?: RequestInit) => Promise<Response>;
10
+ export type BrowserClientOptions = {
11
+ /** Cookie name to read the CSRF token from. Defaults to 'sc' (Sentry's Django default). */
12
+ csrfCookieName?: string;
13
+ /** Override the CSRF token getter — useful for testing. */
14
+ getCsrfToken?: () => string;
15
+ /** Base URL for all requests. Defaults to '' (same-origin relative URLs). */
16
+ baseUrl?: string;
17
+ };
18
+ /**
19
+ * Returns a fetch wrapper that injects X-CSRFToken on state-changing requests
20
+ * and sends session cookies via credentials: 'include'.
21
+ *
22
+ * Sentry's Django backend reads the CSRF token from the 'sc' cookie by default
23
+ * (configurable via window.csrfCookieName in the frontend).
24
+ *
25
+ * Note: always sets credentials: 'include'; any credentials value in init is overridden.
26
+ */
27
+ export declare function createBrowserFetch(opts?: BrowserClientOptions): FetchFn;
28
+ /**
29
+ * Returns options to spread into any @sentry/api SDK call from a browser context.
30
+ * Configures relative base URL and cookie+CSRF auth automatically.
31
+ *
32
+ * @example
33
+ * import {client} from '@sentry/api';
34
+ * import {createBrowserSdkConfig} from '@sentry/api/browser';
35
+ * client.setConfig(createBrowserSdkConfig());
36
+ */
37
+ export declare function createBrowserSdkConfig(opts?: BrowserClientOptions): {
38
+ readonly baseUrl: string;
39
+ readonly fetch: FetchFn;
40
+ };
@@ -0,0 +1 @@
1
+ export * from "./browser-client.ts";
@@ -0,0 +1,38 @@
1
+ // src/browser-client.ts
2
+ var SAFE_METHODS = new Set(["GET", "HEAD", "OPTIONS", "TRACE"]);
3
+ function readCookie(name) {
4
+ if (typeof document === "undefined")
5
+ return "";
6
+ const escapedName = name.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
7
+ const match = document.cookie.match(new RegExp(`(?:^|; )${escapedName}=([^;]*)`));
8
+ if (!match)
9
+ return "";
10
+ try {
11
+ return decodeURIComponent(match[1]);
12
+ } catch {
13
+ return match[1];
14
+ }
15
+ }
16
+ function createBrowserFetch(opts = {}) {
17
+ const getCsrf = opts.getCsrfToken ?? (() => readCookie(opts.csrfCookieName ?? "sc"));
18
+ return (input, init) => {
19
+ const method = (init?.method ?? (input instanceof Request ? input.method : "GET")).toUpperCase();
20
+ const headers = new Headers(init?.headers ?? (input instanceof Request ? input.headers : undefined));
21
+ if (!SAFE_METHODS.has(method)) {
22
+ const token = getCsrf();
23
+ if (token)
24
+ headers.set("X-CSRFToken", token);
25
+ }
26
+ return globalThis.fetch(input, { ...init, headers, credentials: "include" });
27
+ };
28
+ }
29
+ function createBrowserSdkConfig(opts = {}) {
30
+ return {
31
+ baseUrl: opts.baseUrl ?? "",
32
+ fetch: createBrowserFetch(opts)
33
+ };
34
+ }
35
+ export {
36
+ createBrowserSdkConfig,
37
+ createBrowserFetch
38
+ };
package/dist/zod.gen.d.ts CHANGED
@@ -4992,8 +4992,8 @@ export declare const zEventAttachmentDetailsResponse: z.ZodObject<{
4992
4992
  headers: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
4993
4993
  sha1: z.ZodUnion<[z.ZodString, z.ZodNull]>;
4994
4994
  }, "strip", z.ZodTypeAny, {
4995
- name: string;
4996
4995
  headers: Record<string, string | null>;
4996
+ name: string;
4997
4997
  id: string;
4998
4998
  event_id: string;
4999
4999
  type: string;
@@ -5002,8 +5002,8 @@ export declare const zEventAttachmentDetailsResponse: z.ZodObject<{
5002
5002
  size: number;
5003
5003
  sha1: string | null;
5004
5004
  }, {
5005
- name: string;
5006
5005
  headers: Record<string, string | null>;
5006
+ name: string;
5007
5007
  id: string;
5008
5008
  event_id: string;
5009
5009
  type: string;
@@ -9393,8 +9393,8 @@ export declare const zListEventAttachmentsResponse: z.ZodArray<z.ZodObject<{
9393
9393
  headers: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
9394
9394
  sha1: z.ZodUnion<[z.ZodString, z.ZodNull]>;
9395
9395
  }, "strip", z.ZodTypeAny, {
9396
- name: string;
9397
9396
  headers: Record<string, string | null>;
9397
+ name: string;
9398
9398
  id: string;
9399
9399
  event_id: string;
9400
9400
  type: string;
@@ -9403,8 +9403,8 @@ export declare const zListEventAttachmentsResponse: z.ZodArray<z.ZodObject<{
9403
9403
  size: number;
9404
9404
  sha1: string | null;
9405
9405
  }, {
9406
- name: string;
9407
9406
  headers: Record<string, string | null>;
9407
+ name: string;
9408
9408
  id: string;
9409
9409
  event_id: string;
9410
9410
  type: string;
@@ -34044,8 +34044,8 @@ export declare const zQueryExploreEventsInTableFormatData: z.ZodObject<{
34044
34044
  }, "strip", z.ZodTypeAny, {
34045
34045
  field: string[];
34046
34046
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34047
- query?: string | undefined;
34048
34047
  sort?: string | undefined;
34048
+ query?: string | undefined;
34049
34049
  environment?: string[] | undefined;
34050
34050
  project?: number[] | undefined;
34051
34051
  cursor?: string | undefined;
@@ -34056,8 +34056,8 @@ export declare const zQueryExploreEventsInTableFormatData: z.ZodObject<{
34056
34056
  }, {
34057
34057
  field: string[];
34058
34058
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34059
- query?: string | undefined;
34060
34059
  sort?: string | undefined;
34060
+ query?: string | undefined;
34061
34061
  environment?: string[] | undefined;
34062
34062
  project?: number[] | undefined;
34063
34063
  cursor?: string | undefined;
@@ -34070,8 +34070,8 @@ export declare const zQueryExploreEventsInTableFormatData: z.ZodObject<{
34070
34070
  query: {
34071
34071
  field: string[];
34072
34072
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34073
- query?: string | undefined;
34074
34073
  sort?: string | undefined;
34074
+ query?: string | undefined;
34075
34075
  environment?: string[] | undefined;
34076
34076
  project?: number[] | undefined;
34077
34077
  cursor?: string | undefined;
@@ -34088,8 +34088,8 @@ export declare const zQueryExploreEventsInTableFormatData: z.ZodObject<{
34088
34088
  query: {
34089
34089
  field: string[];
34090
34090
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34091
- query?: string | undefined;
34092
34091
  sort?: string | undefined;
34092
+ query?: string | undefined;
34093
34093
  environment?: string[] | undefined;
34094
34094
  project?: number[] | undefined;
34095
34095
  cursor?: string | undefined;
@@ -34166,8 +34166,8 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34166
34166
  excludeOther: z.ZodOptional<z.ZodEnum<["0", "1"]>>;
34167
34167
  }, "strip", z.ZodTypeAny, {
34168
34168
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34169
- query?: string | undefined;
34170
34169
  sort?: string | undefined;
34170
+ query?: string | undefined;
34171
34171
  interval?: number | undefined;
34172
34172
  environment?: string[] | undefined;
34173
34173
  project?: number[] | undefined;
@@ -34178,13 +34178,13 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34178
34178
  comparisonDelta?: number | undefined;
34179
34179
  groupBy?: string[] | undefined;
34180
34180
  yAxis?: string | undefined;
34181
- disableAggregateExtrapolation?: "1" | "0" | undefined;
34182
- preventMetricAggregates?: "1" | "0" | undefined;
34183
- excludeOther?: "1" | "0" | undefined;
34181
+ disableAggregateExtrapolation?: "0" | "1" | undefined;
34182
+ preventMetricAggregates?: "0" | "1" | undefined;
34183
+ excludeOther?: "0" | "1" | undefined;
34184
34184
  }, {
34185
34185
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34186
- query?: string | undefined;
34187
34186
  sort?: string | undefined;
34187
+ query?: string | undefined;
34188
34188
  interval?: number | undefined;
34189
34189
  environment?: string[] | undefined;
34190
34190
  project?: number[] | undefined;
@@ -34195,15 +34195,15 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34195
34195
  comparisonDelta?: number | undefined;
34196
34196
  groupBy?: string[] | undefined;
34197
34197
  yAxis?: string | undefined;
34198
- disableAggregateExtrapolation?: "1" | "0" | undefined;
34199
- preventMetricAggregates?: "1" | "0" | undefined;
34200
- excludeOther?: "1" | "0" | undefined;
34198
+ disableAggregateExtrapolation?: "0" | "1" | undefined;
34199
+ preventMetricAggregates?: "0" | "1" | undefined;
34200
+ excludeOther?: "0" | "1" | undefined;
34201
34201
  }>;
34202
34202
  }, "strip", z.ZodTypeAny, {
34203
34203
  query: {
34204
34204
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34205
- query?: string | undefined;
34206
34205
  sort?: string | undefined;
34206
+ query?: string | undefined;
34207
34207
  interval?: number | undefined;
34208
34208
  environment?: string[] | undefined;
34209
34209
  project?: number[] | undefined;
@@ -34214,9 +34214,9 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34214
34214
  comparisonDelta?: number | undefined;
34215
34215
  groupBy?: string[] | undefined;
34216
34216
  yAxis?: string | undefined;
34217
- disableAggregateExtrapolation?: "1" | "0" | undefined;
34218
- preventMetricAggregates?: "1" | "0" | undefined;
34219
- excludeOther?: "1" | "0" | undefined;
34217
+ disableAggregateExtrapolation?: "0" | "1" | undefined;
34218
+ preventMetricAggregates?: "0" | "1" | undefined;
34219
+ excludeOther?: "0" | "1" | undefined;
34220
34220
  };
34221
34221
  path: {
34222
34222
  organization_id_or_slug: string;
@@ -34225,8 +34225,8 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34225
34225
  }, {
34226
34226
  query: {
34227
34227
  dataset: "spans" | "logs" | "tracemetrics" | "errors" | "profile_functions" | "uptime_results";
34228
- query?: string | undefined;
34229
34228
  sort?: string | undefined;
34229
+ query?: string | undefined;
34230
34230
  interval?: number | undefined;
34231
34231
  environment?: string[] | undefined;
34232
34232
  project?: number[] | undefined;
@@ -34237,9 +34237,9 @@ export declare const zQueryExploreEventsInTimeseriesFormatData: z.ZodObject<{
34237
34237
  comparisonDelta?: number | undefined;
34238
34238
  groupBy?: string[] | undefined;
34239
34239
  yAxis?: string | undefined;
34240
- disableAggregateExtrapolation?: "1" | "0" | undefined;
34241
- preventMetricAggregates?: "1" | "0" | undefined;
34242
- excludeOther?: "1" | "0" | undefined;
34240
+ disableAggregateExtrapolation?: "0" | "1" | undefined;
34241
+ preventMetricAggregates?: "0" | "1" | undefined;
34242
+ excludeOther?: "0" | "1" | undefined;
34243
34243
  };
34244
34244
  path: {
34245
34245
  organization_id_or_slug: string;
@@ -35444,8 +35444,8 @@ export declare const zBulkRemoveAnOrganizationSissuesData: z.ZodObject<{
35444
35444
  project?: number[] | undefined;
35445
35445
  viewId?: string | undefined;
35446
35446
  }, {
35447
- query?: string | undefined;
35448
35447
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
35448
+ query?: string | undefined;
35449
35449
  environment?: string[] | undefined;
35450
35450
  id?: number[] | undefined;
35451
35451
  project?: number[] | undefined;
@@ -35471,8 +35471,8 @@ export declare const zBulkRemoveAnOrganizationSissuesData: z.ZodObject<{
35471
35471
  organization_id_or_slug: string;
35472
35472
  };
35473
35473
  query?: {
35474
- query?: string | undefined;
35475
35474
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
35475
+ query?: string | undefined;
35476
35476
  environment?: string[] | undefined;
35477
35477
  id?: number[] | undefined;
35478
35478
  project?: number[] | undefined;
@@ -35521,12 +35521,12 @@ export declare const zListAnOrganizationSissuesData: z.ZodObject<{
35521
35521
  statsPeriod?: string | undefined;
35522
35522
  viewId?: string | undefined;
35523
35523
  groupStatsPeriod?: "" | "auto" | "14d" | "24h" | undefined;
35524
- shortIdLookup?: "1" | "0" | undefined;
35524
+ shortIdLookup?: "0" | "1" | undefined;
35525
35525
  expand?: ("inbox" | "integrationIssues" | "latestEventHasAttachments" | "owners" | "pluginActions" | "pluginIssues" | "sentryAppIssues" | "sessions")[] | undefined;
35526
35526
  collapse?: ("base" | "filtered" | "lifetime" | "stats" | "unhandled")[] | undefined;
35527
35527
  }, {
35528
- query?: string | undefined;
35529
35528
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
35529
+ query?: string | undefined;
35530
35530
  environment?: string[] | undefined;
35531
35531
  project?: number[] | undefined;
35532
35532
  cursor?: string | undefined;
@@ -35536,7 +35536,7 @@ export declare const zListAnOrganizationSissuesData: z.ZodObject<{
35536
35536
  viewId?: string | undefined;
35537
35537
  limit?: number | undefined;
35538
35538
  groupStatsPeriod?: "" | "auto" | "14d" | "24h" | undefined;
35539
- shortIdLookup?: "1" | "0" | undefined;
35539
+ shortIdLookup?: "0" | "1" | undefined;
35540
35540
  expand?: ("inbox" | "integrationIssues" | "latestEventHasAttachments" | "owners" | "pluginActions" | "pluginIssues" | "sentryAppIssues" | "sessions")[] | undefined;
35541
35541
  collapse?: ("base" | "filtered" | "lifetime" | "stats" | "unhandled")[] | undefined;
35542
35542
  }>>;
@@ -35556,7 +35556,7 @@ export declare const zListAnOrganizationSissuesData: z.ZodObject<{
35556
35556
  statsPeriod?: string | undefined;
35557
35557
  viewId?: string | undefined;
35558
35558
  groupStatsPeriod?: "" | "auto" | "14d" | "24h" | undefined;
35559
- shortIdLookup?: "1" | "0" | undefined;
35559
+ shortIdLookup?: "0" | "1" | undefined;
35560
35560
  expand?: ("inbox" | "integrationIssues" | "latestEventHasAttachments" | "owners" | "pluginActions" | "pluginIssues" | "sentryAppIssues" | "sessions")[] | undefined;
35561
35561
  collapse?: ("base" | "filtered" | "lifetime" | "stats" | "unhandled")[] | undefined;
35562
35562
  } | undefined;
@@ -35566,8 +35566,8 @@ export declare const zListAnOrganizationSissuesData: z.ZodObject<{
35566
35566
  organization_id_or_slug: string;
35567
35567
  };
35568
35568
  query?: {
35569
- query?: string | undefined;
35570
35569
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
35570
+ query?: string | undefined;
35571
35571
  environment?: string[] | undefined;
35572
35572
  project?: number[] | undefined;
35573
35573
  cursor?: string | undefined;
@@ -35577,7 +35577,7 @@ export declare const zListAnOrganizationSissuesData: z.ZodObject<{
35577
35577
  viewId?: string | undefined;
35578
35578
  limit?: number | undefined;
35579
35579
  groupStatsPeriod?: "" | "auto" | "14d" | "24h" | undefined;
35580
- shortIdLookup?: "1" | "0" | undefined;
35580
+ shortIdLookup?: "0" | "1" | undefined;
35581
35581
  expand?: ("inbox" | "integrationIssues" | "latestEventHasAttachments" | "owners" | "pluginActions" | "pluginIssues" | "sentryAppIssues" | "sessions")[] | undefined;
35582
35582
  collapse?: ("base" | "filtered" | "lifetime" | "stats" | "unhandled")[] | undefined;
35583
35583
  } | undefined;
@@ -36468,8 +36468,8 @@ export declare const zBulkMutateAnOrganizationSissuesData: z.ZodObject<{
36468
36468
  project?: number[] | undefined;
36469
36469
  viewId?: string | undefined;
36470
36470
  }, {
36471
- query?: string | undefined;
36472
36471
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
36472
+ query?: string | undefined;
36473
36473
  environment?: string[] | undefined;
36474
36474
  id?: number[] | undefined;
36475
36475
  project?: number[] | undefined;
@@ -36546,8 +36546,8 @@ export declare const zBulkMutateAnOrganizationSissuesData: z.ZodObject<{
36546
36546
  organization_id_or_slug: string;
36547
36547
  };
36548
36548
  query?: {
36549
- query?: string | undefined;
36550
36549
  sort?: "user" | "new" | "date" | "freq" | "inbox" | "recommended" | "trends" | undefined;
36550
+ query?: string | undefined;
36551
36551
  environment?: string[] | undefined;
36552
36552
  id?: number[] | undefined;
36553
36553
  project?: number[] | undefined;
@@ -44679,8 +44679,8 @@ export declare const zRetrieveAnOrganizationSReleaseData: z.ZodObject<{
44679
44679
  status: z.ZodOptional<z.ZodEnum<["archived", "open"]>>;
44680
44680
  query: z.ZodOptional<z.ZodString>;
44681
44681
  }, "strip", z.ZodTypeAny, {
44682
- query?: string | undefined;
44683
44682
  sort?: "date" | "sessions" | "crash_free_sessions" | "crash_free_users" | "users" | undefined;
44683
+ query?: string | undefined;
44684
44684
  project_id?: string | undefined;
44685
44685
  status?: "archived" | "open" | undefined;
44686
44686
  health?: boolean | undefined;
@@ -44688,8 +44688,8 @@ export declare const zRetrieveAnOrganizationSReleaseData: z.ZodObject<{
44688
44688
  summaryStatsPeriod?: "14d" | "24h" | "1d" | "1h" | "2d" | "30d" | "48h" | "7d" | "90d" | undefined;
44689
44689
  healthStatsPeriod?: "14d" | "24h" | "1d" | "1h" | "2d" | "30d" | "48h" | "7d" | "90d" | undefined;
44690
44690
  }, {
44691
- query?: string | undefined;
44692
44691
  sort?: "date" | "sessions" | "crash_free_sessions" | "crash_free_users" | "users" | undefined;
44692
+ query?: string | undefined;
44693
44693
  project_id?: string | undefined;
44694
44694
  status?: "archived" | "open" | undefined;
44695
44695
  health?: boolean | undefined;
@@ -44703,8 +44703,8 @@ export declare const zRetrieveAnOrganizationSReleaseData: z.ZodObject<{
44703
44703
  version: string;
44704
44704
  };
44705
44705
  query?: {
44706
- query?: string | undefined;
44707
44706
  sort?: "date" | "sessions" | "crash_free_sessions" | "crash_free_users" | "users" | undefined;
44707
+ query?: string | undefined;
44708
44708
  project_id?: string | undefined;
44709
44709
  status?: "archived" | "open" | undefined;
44710
44710
  health?: boolean | undefined;
@@ -44719,8 +44719,8 @@ export declare const zRetrieveAnOrganizationSReleaseData: z.ZodObject<{
44719
44719
  version: string;
44720
44720
  };
44721
44721
  query?: {
44722
- query?: string | undefined;
44723
44722
  sort?: "date" | "sessions" | "crash_free_sessions" | "crash_free_users" | "users" | undefined;
44723
+ query?: string | undefined;
44724
44724
  project_id?: string | undefined;
44725
44725
  status?: "archived" | "open" | undefined;
44726
44726
  health?: boolean | undefined;
@@ -46327,8 +46327,8 @@ export declare const zListAnOrganizationSSelectorsData: z.ZodObject<{
46327
46327
  per_page: z.ZodOptional<z.ZodNumber>;
46328
46328
  query: z.ZodOptional<z.ZodString>;
46329
46329
  }, "strip", z.ZodTypeAny, {
46330
- query?: string | undefined;
46331
46330
  sort?: string | undefined;
46331
+ query?: string | undefined;
46332
46332
  environment?: string[] | undefined;
46333
46333
  project?: number[] | undefined;
46334
46334
  cursor?: string | undefined;
@@ -46340,8 +46340,8 @@ export declare const zListAnOrganizationSSelectorsData: z.ZodObject<{
46340
46340
  projectSlug?: string[] | undefined;
46341
46341
  orderBy?: string | undefined;
46342
46342
  }, {
46343
- query?: string | undefined;
46344
46343
  sort?: string | undefined;
46344
+ query?: string | undefined;
46345
46345
  environment?: string[] | undefined;
46346
46346
  project?: number[] | undefined;
46347
46347
  cursor?: string | undefined;
@@ -46358,8 +46358,8 @@ export declare const zListAnOrganizationSSelectorsData: z.ZodObject<{
46358
46358
  organization_id_or_slug: string;
46359
46359
  };
46360
46360
  query?: {
46361
- query?: string | undefined;
46362
46361
  sort?: string | undefined;
46362
+ query?: string | undefined;
46363
46363
  environment?: string[] | undefined;
46364
46364
  project?: number[] | undefined;
46365
46365
  cursor?: string | undefined;
@@ -46377,8 +46377,8 @@ export declare const zListAnOrganizationSSelectorsData: z.ZodObject<{
46377
46377
  organization_id_or_slug: string;
46378
46378
  };
46379
46379
  query?: {
46380
- query?: string | undefined;
46381
46380
  sort?: string | undefined;
46381
+ query?: string | undefined;
46382
46382
  environment?: string[] | undefined;
46383
46383
  project?: number[] | undefined;
46384
46384
  cursor?: string | undefined;
@@ -46523,8 +46523,8 @@ export declare const zListAnOrganizationSReplaysData: z.ZodObject<{
46523
46523
  per_page: z.ZodOptional<z.ZodNumber>;
46524
46524
  cursor: z.ZodOptional<z.ZodString>;
46525
46525
  }, "strip", z.ZodTypeAny, {
46526
- query?: string | undefined;
46527
46526
  sort?: string | undefined;
46527
+ query?: string | undefined;
46528
46528
  environment?: string | undefined;
46529
46529
  project?: number[] | undefined;
46530
46530
  cursor?: string | undefined;
@@ -46537,8 +46537,8 @@ export declare const zListAnOrganizationSReplaysData: z.ZodObject<{
46537
46537
  projectSlug?: string[] | undefined;
46538
46538
  orderBy?: string | undefined;
46539
46539
  }, {
46540
- query?: string | undefined;
46541
46540
  sort?: string | undefined;
46541
+ query?: string | undefined;
46542
46542
  environment?: string | undefined;
46543
46543
  project?: number[] | undefined;
46544
46544
  cursor?: string | undefined;
@@ -46556,8 +46556,8 @@ export declare const zListAnOrganizationSReplaysData: z.ZodObject<{
46556
46556
  organization_id_or_slug: string;
46557
46557
  };
46558
46558
  query?: {
46559
- query?: string | undefined;
46560
46559
  sort?: string | undefined;
46560
+ query?: string | undefined;
46561
46561
  environment?: string | undefined;
46562
46562
  project?: number[] | undefined;
46563
46563
  cursor?: string | undefined;
@@ -46576,8 +46576,8 @@ export declare const zListAnOrganizationSReplaysData: z.ZodObject<{
46576
46576
  organization_id_or_slug: string;
46577
46577
  };
46578
46578
  query?: {
46579
- query?: string | undefined;
46580
46579
  sort?: string | undefined;
46580
+ query?: string | undefined;
46581
46581
  environment?: string | undefined;
46582
46582
  project?: number[] | undefined;
46583
46583
  cursor?: string | undefined;
@@ -46876,8 +46876,8 @@ export declare const zRetrieveAReplayInstanceData: z.ZodObject<{
46876
46876
  per_page: z.ZodOptional<z.ZodNumber>;
46877
46877
  cursor: z.ZodOptional<z.ZodString>;
46878
46878
  }, "strip", z.ZodTypeAny, {
46879
- query?: string | undefined;
46880
46879
  sort?: string | undefined;
46880
+ query?: string | undefined;
46881
46881
  environment?: string | undefined;
46882
46882
  project?: number[] | undefined;
46883
46883
  cursor?: string | undefined;
@@ -46890,8 +46890,8 @@ export declare const zRetrieveAReplayInstanceData: z.ZodObject<{
46890
46890
  projectSlug?: string[] | undefined;
46891
46891
  orderBy?: string | undefined;
46892
46892
  }, {
46893
- query?: string | undefined;
46894
46893
  sort?: string | undefined;
46894
+ query?: string | undefined;
46895
46895
  environment?: string | undefined;
46896
46896
  project?: number[] | undefined;
46897
46897
  cursor?: string | undefined;
@@ -46910,8 +46910,8 @@ export declare const zRetrieveAReplayInstanceData: z.ZodObject<{
46910
46910
  replay_id: string;
46911
46911
  };
46912
46912
  query?: {
46913
- query?: string | undefined;
46914
46913
  sort?: string | undefined;
46914
+ query?: string | undefined;
46915
46915
  environment?: string | undefined;
46916
46916
  project?: number[] | undefined;
46917
46917
  cursor?: string | undefined;
@@ -46931,8 +46931,8 @@ export declare const zRetrieveAReplayInstanceData: z.ZodObject<{
46931
46931
  replay_id: string;
46932
46932
  };
46933
46933
  query?: {
46934
- query?: string | undefined;
46935
46934
  sort?: string | undefined;
46935
+ query?: string | undefined;
46936
46936
  environment?: string | undefined;
46937
46937
  project?: number[] | undefined;
46938
46938
  cursor?: string | undefined;
@@ -51863,12 +51863,12 @@ export declare const zRetrieveTraceMetadataData: z.ZodObject<{
51863
51863
  end?: string | undefined;
51864
51864
  start?: string | undefined;
51865
51865
  statsPeriod?: string | undefined;
51866
- include_uptime?: "1" | "0" | undefined;
51866
+ include_uptime?: "0" | "1" | undefined;
51867
51867
  }, {
51868
51868
  end?: string | undefined;
51869
51869
  start?: string | undefined;
51870
51870
  statsPeriod?: string | undefined;
51871
- include_uptime?: "1" | "0" | undefined;
51871
+ include_uptime?: "0" | "1" | undefined;
51872
51872
  }>>;
51873
51873
  }, "strip", z.ZodTypeAny, {
51874
51874
  path: {
@@ -51879,7 +51879,7 @@ export declare const zRetrieveTraceMetadataData: z.ZodObject<{
51879
51879
  end?: string | undefined;
51880
51880
  start?: string | undefined;
51881
51881
  statsPeriod?: string | undefined;
51882
- include_uptime?: "1" | "0" | undefined;
51882
+ include_uptime?: "0" | "1" | undefined;
51883
51883
  } | undefined;
51884
51884
  body?: undefined;
51885
51885
  }, {
@@ -51891,7 +51891,7 @@ export declare const zRetrieveTraceMetadataData: z.ZodObject<{
51891
51891
  end?: string | undefined;
51892
51892
  start?: string | undefined;
51893
51893
  statsPeriod?: string | undefined;
51894
- include_uptime?: "1" | "0" | undefined;
51894
+ include_uptime?: "0" | "1" | undefined;
51895
51895
  } | undefined;
51896
51896
  body?: undefined;
51897
51897
  }>;
@@ -51948,7 +51948,7 @@ export declare const zRetrieveATraceData: z.ZodObject<{
51948
51948
  end?: string | undefined;
51949
51949
  start?: string | undefined;
51950
51950
  statsPeriod?: string | undefined;
51951
- include_uptime?: "1" | "0" | undefined;
51951
+ include_uptime?: "0" | "1" | undefined;
51952
51952
  errorId?: string | undefined;
51953
51953
  additional_attributes?: string[] | undefined;
51954
51954
  }, {
@@ -51956,7 +51956,7 @@ export declare const zRetrieveATraceData: z.ZodObject<{
51956
51956
  end?: string | undefined;
51957
51957
  start?: string | undefined;
51958
51958
  statsPeriod?: string | undefined;
51959
- include_uptime?: "1" | "0" | undefined;
51959
+ include_uptime?: "0" | "1" | undefined;
51960
51960
  errorId?: string | undefined;
51961
51961
  additional_attributes?: string[] | undefined;
51962
51962
  }>>;
@@ -51970,7 +51970,7 @@ export declare const zRetrieveATraceData: z.ZodObject<{
51970
51970
  end?: string | undefined;
51971
51971
  start?: string | undefined;
51972
51972
  statsPeriod?: string | undefined;
51973
- include_uptime?: "1" | "0" | undefined;
51973
+ include_uptime?: "0" | "1" | undefined;
51974
51974
  errorId?: string | undefined;
51975
51975
  additional_attributes?: string[] | undefined;
51976
51976
  } | undefined;
@@ -51985,7 +51985,7 @@ export declare const zRetrieveATraceData: z.ZodObject<{
51985
51985
  end?: string | undefined;
51986
51986
  start?: string | undefined;
51987
51987
  statsPeriod?: string | undefined;
51988
- include_uptime?: "1" | "0" | undefined;
51988
+ include_uptime?: "0" | "1" | undefined;
51989
51989
  errorId?: string | undefined;
51990
51990
  additional_attributes?: string[] | undefined;
51991
51991
  } | undefined;
@@ -57230,8 +57230,8 @@ export declare const zListAnEventSAttachmentsResponse: z.ZodArray<z.ZodObject<{
57230
57230
  headers: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
57231
57231
  sha1: z.ZodUnion<[z.ZodString, z.ZodNull]>;
57232
57232
  }, "strip", z.ZodTypeAny, {
57233
- name: string;
57234
57233
  headers: Record<string, string | null>;
57234
+ name: string;
57235
57235
  id: string;
57236
57236
  event_id: string;
57237
57237
  type: string;
@@ -57240,8 +57240,8 @@ export declare const zListAnEventSAttachmentsResponse: z.ZodArray<z.ZodObject<{
57240
57240
  size: number;
57241
57241
  sha1: string | null;
57242
57242
  }, {
57243
- name: string;
57244
57243
  headers: Record<string, string | null>;
57244
+ name: string;
57245
57245
  id: string;
57246
57246
  event_id: string;
57247
57247
  type: string;
@@ -57299,8 +57299,8 @@ export declare const zRetrieveAnEventAttachmentResponse: z.ZodObject<{
57299
57299
  headers: z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodNull]>>;
57300
57300
  sha1: z.ZodUnion<[z.ZodString, z.ZodNull]>;
57301
57301
  }, "strip", z.ZodTypeAny, {
57302
- name: string;
57303
57302
  headers: Record<string, string | null>;
57303
+ name: string;
57304
57304
  id: string;
57305
57305
  event_id: string;
57306
57306
  type: string;
@@ -57309,8 +57309,8 @@ export declare const zRetrieveAnEventAttachmentResponse: z.ZodObject<{
57309
57309
  size: number;
57310
57310
  sha1: string | null;
57311
57311
  }, {
57312
- name: string;
57313
57312
  headers: Record<string, string | null>;
57313
+ name: string;
57314
57314
  id: string;
57315
57315
  event_id: string;
57316
57316
  type: string;
@@ -69230,20 +69230,20 @@ export declare const zListAnOrganizationSReleaseFilesResponse: z.ZodArray<z.ZodO
69230
69230
  id: z.ZodString;
69231
69231
  size: z.ZodNumber;
69232
69232
  }, "strip", z.ZodTypeAny, {
69233
- name: string;
69234
69233
  headers: {
69235
69234
  'Content-Type'?: string | undefined;
69236
69235
  };
69236
+ name: string;
69237
69237
  dist: string | null;
69238
69238
  id: string;
69239
69239
  dateCreated: string;
69240
69240
  size: number;
69241
69241
  sha1: string;
69242
69242
  }, {
69243
- name: string;
69244
69243
  headers: {
69245
69244
  'Content-Type'?: string | undefined;
69246
69245
  };
69246
+ name: string;
69247
69247
  dist: string | null;
69248
69248
  id: string;
69249
69249
  dateCreated: string;
@@ -69364,20 +69364,20 @@ export declare const zListAProjectSReleaseFilesResponse: z.ZodArray<z.ZodObject<
69364
69364
  id: z.ZodString;
69365
69365
  size: z.ZodNumber;
69366
69366
  }, "strip", z.ZodTypeAny, {
69367
- name: string;
69368
69367
  headers: {
69369
69368
  'Content-Type'?: string | undefined;
69370
69369
  };
69370
+ name: string;
69371
69371
  dist: string | null;
69372
69372
  id: string;
69373
69373
  dateCreated: string;
69374
69374
  size: number;
69375
69375
  sha1: string;
69376
69376
  }, {
69377
- name: string;
69378
69377
  headers: {
69379
69378
  'Content-Type'?: string | undefined;
69380
69379
  };
69380
+ name: string;
69381
69381
  dist: string | null;
69382
69382
  id: string;
69383
69383
  dateCreated: string;
@@ -69460,20 +69460,20 @@ export declare const zUploadANewProjectReleaseFileResponse: z.ZodObject<{
69460
69460
  id: z.ZodString;
69461
69461
  size: z.ZodNumber;
69462
69462
  }, "strip", z.ZodTypeAny, {
69463
- name: string;
69464
69463
  headers: {
69465
69464
  'Content-Type'?: string | undefined;
69466
69465
  };
69466
+ name: string;
69467
69467
  dist: string | null;
69468
69468
  id: string;
69469
69469
  dateCreated: string;
69470
69470
  size: number;
69471
69471
  sha1: string;
69472
69472
  }, {
69473
- name: string;
69474
69473
  headers: {
69475
69474
  'Content-Type'?: string | undefined;
69476
69475
  };
69476
+ name: string;
69477
69477
  dist: string | null;
69478
69478
  id: string;
69479
69479
  dateCreated: string;
@@ -69578,20 +69578,20 @@ export declare const zRetrieveAnOrganizationReleaseSFileResponse: z.ZodObject<{
69578
69578
  id: z.ZodString;
69579
69579
  size: z.ZodNumber;
69580
69580
  }, "strip", z.ZodTypeAny, {
69581
- name: string;
69582
69581
  headers: {
69583
69582
  'Content-Type'?: string | undefined;
69584
69583
  };
69584
+ name: string;
69585
69585
  dist: string | null;
69586
69586
  id: string;
69587
69587
  dateCreated: string;
69588
69588
  size: number;
69589
69589
  sha1: string;
69590
69590
  }, {
69591
- name: string;
69592
69591
  headers: {
69593
69592
  'Content-Type'?: string | undefined;
69594
69593
  };
69594
+ name: string;
69595
69595
  dist: string | null;
69596
69596
  id: string;
69597
69597
  dateCreated: string;
@@ -69664,20 +69664,20 @@ export declare const zUpdateAnOrganizationReleaseFileResponse: z.ZodObject<{
69664
69664
  id: z.ZodString;
69665
69665
  size: z.ZodNumber;
69666
69666
  }, "strip", z.ZodTypeAny, {
69667
- name: string;
69668
69667
  headers: {
69669
69668
  'Content-Type'?: string | undefined;
69670
69669
  };
69670
+ name: string;
69671
69671
  dist: string | null;
69672
69672
  id: string;
69673
69673
  dateCreated: string;
69674
69674
  size: number;
69675
69675
  sha1: string;
69676
69676
  }, {
69677
- name: string;
69678
69677
  headers: {
69679
69678
  'Content-Type'?: string | undefined;
69680
69679
  };
69680
+ name: string;
69681
69681
  dist: string | null;
69682
69682
  id: string;
69683
69683
  dateCreated: string;
@@ -69792,20 +69792,20 @@ export declare const zRetrieveAProjectReleaseSFileResponse: z.ZodObject<{
69792
69792
  id: z.ZodString;
69793
69793
  size: z.ZodNumber;
69794
69794
  }, "strip", z.ZodTypeAny, {
69795
- name: string;
69796
69795
  headers: {
69797
69796
  'Content-Type'?: string | undefined;
69798
69797
  };
69798
+ name: string;
69799
69799
  dist: string | null;
69800
69800
  id: string;
69801
69801
  dateCreated: string;
69802
69802
  size: number;
69803
69803
  sha1: string;
69804
69804
  }, {
69805
- name: string;
69806
69805
  headers: {
69807
69806
  'Content-Type'?: string | undefined;
69808
69807
  };
69808
+ name: string;
69809
69809
  dist: string | null;
69810
69810
  id: string;
69811
69811
  dateCreated: string;
@@ -69883,20 +69883,20 @@ export declare const zUpdateAProjectReleaseFileResponse: z.ZodObject<{
69883
69883
  id: z.ZodString;
69884
69884
  size: z.ZodNumber;
69885
69885
  }, "strip", z.ZodTypeAny, {
69886
- name: string;
69887
69886
  headers: {
69888
69887
  'Content-Type'?: string | undefined;
69889
69888
  };
69889
+ name: string;
69890
69890
  dist: string | null;
69891
69891
  id: string;
69892
69892
  dateCreated: string;
69893
69893
  size: number;
69894
69894
  sha1: string;
69895
69895
  }, {
69896
- name: string;
69897
69896
  headers: {
69898
69897
  'Content-Type'?: string | undefined;
69899
69898
  };
69899
+ name: string;
69900
69900
  dist: string | null;
69901
69901
  id: string;
69902
69902
  dateCreated: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/api",
3
- "version": "0.169.0",
3
+ "version": "0.171.0",
4
4
  "description": "Official auto-generated TypeScript client for the Sentry public REST API",
5
5
  "keywords": [
6
6
  "sentry",
@@ -29,6 +29,10 @@
29
29
  "./zod": {
30
30
  "import": "./dist/zod.js",
31
31
  "types": "./dist/zod.d.ts"
32
+ },
33
+ "./browser": {
34
+ "import": "./dist/browser.js",
35
+ "types": "./dist/browser.d.ts"
32
36
  }
33
37
  },
34
38
  "homepage": "https://docs.sentry.io/api/",