@sentry/api 0.364.0 → 0.366.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/dist/sdk.gen.d.ts CHANGED
@@ -79,9 +79,11 @@ export declare const listOrganizationAiConversations: <ThrowOnError extends bool
79
79
  * Message, tool, and response attributes contain their recorded string values.
80
80
  * `stats.errors` counts spans whose status is not `ok`, `cancelled`, or `unknown`.
81
81
  * `stats.errorToolNames` lists tools used by those spans.
82
- * `stats.inputTokens` includes cache-read and cache-write tokens. Stats are returned
83
- * on the first page only. Without an explicit range, Sentry widens the search across
84
- * available retention. A missing conversation returns an empty `spans` list.
82
+ * `stats.inputTokens` includes cache-read and cache-write tokens. In `stats.usageByModel`,
83
+ * `inputCost` includes cache-read and cache-write costs, and `outputCost` includes
84
+ * reasoning cost. These cost breakdowns are not added to `totalCost`.
85
+ * Stats are returned on the first page only. Without an explicit range, Sentry widens
86
+ * the search across available retention. A missing conversation returns an empty `spans` list.
85
87
  */
86
88
  export declare const retrieveOrganizationAiConversation: <ThrowOnError extends boolean = false>(options: Options<RetrieveOrganizationAiConversationData, ThrowOnError>) => import("./client").RequestResult<RetrieveOrganizationAiConversationResponses, RetrieveOrganizationAiConversationErrors, ThrowOnError, "fields">;
87
89
  /**
@@ -75,9 +75,11 @@ export declare function createSentryClient(config?: Config): {
75
75
  * Message, tool, and response attributes contain their recorded string values.
76
76
  * `stats.errors` counts spans whose status is not `ok`, `cancelled`, or `unknown`.
77
77
  * `stats.errorToolNames` lists tools used by those spans.
78
- * `stats.inputTokens` includes cache-read and cache-write tokens. Stats are returned
79
- * on the first page only. Without an explicit range, Sentry widens the search across
80
- * available retention. A missing conversation returns an empty `spans` list.
78
+ * `stats.inputTokens` includes cache-read and cache-write tokens. In `stats.usageByModel`,
79
+ * `inputCost` includes cache-read and cache-write costs, and `outputCost` includes
80
+ * reasoning cost. These cost breakdowns are not added to `totalCost`.
81
+ * Stats are returned on the first page only. Without an explicit range, Sentry widens
82
+ * the search across available retention. A missing conversation returns an empty `spans` list.
81
83
  */
82
84
  readonly retrieveOrganizationAiConversation: <ThrowOnError extends boolean = false>(options: Omit<NonNullable<sdk.Options<types.RetrieveOrganizationAiConversationData, ThrowOnError>>, "client">) => import("./client").RequestResult<types.RetrieveOrganizationAiConversationResponses, types.RetrieveOrganizationAiConversationErrors, ThrowOnError, "fields">;
83
85
  /**
@@ -4830,6 +4832,9 @@ export declare function createSentryClient(config?: Config): {
4830
4832
  cacheWriteTokens: number;
4831
4833
  errorToolNames: Array<string>;
4832
4834
  reasoningTokens: number;
4835
+ cacheReadCost: number;
4836
+ cacheWriteCost: number;
4837
+ reasoningCost: number;
4833
4838
  usageByModel: Array<{
4834
4839
  model: string | null;
4835
4840
  llmCalls: number;
@@ -4841,6 +4846,9 @@ export declare function createSentryClient(config?: Config): {
4841
4846
  reasoningTokens: number;
4842
4847
  inputCost: number;
4843
4848
  outputCost: number;
4849
+ cacheReadCost: number;
4850
+ cacheWriteCost: number;
4851
+ reasoningCost: number;
4844
4852
  totalCost: number;
4845
4853
  }>;
4846
4854
  } | null;
@@ -9799,6 +9799,9 @@ export type RetrieveOrganizationAiConversationResponse = {
9799
9799
  cacheWriteTokens: number;
9800
9800
  errorToolNames: Array<string>;
9801
9801
  reasoningTokens: number;
9802
+ cacheReadCost: number;
9803
+ cacheWriteCost: number;
9804
+ reasoningCost: number;
9802
9805
  usageByModel: Array<{
9803
9806
  model: string | null;
9804
9807
  llmCalls: number;
@@ -9810,6 +9813,9 @@ export type RetrieveOrganizationAiConversationResponse = {
9810
9813
  reasoningTokens: number;
9811
9814
  inputCost: number;
9812
9815
  outputCost: number;
9816
+ cacheReadCost: number;
9817
+ cacheWriteCost: number;
9818
+ reasoningCost: number;
9813
9819
  totalCost: number;
9814
9820
  }>;
9815
9821
  } | null;
@@ -13122,6 +13128,9 @@ export type RetrieveOrganizationAiConversationResponses = {
13122
13128
  cacheWriteTokens: number;
13123
13129
  errorToolNames: Array<string>;
13124
13130
  reasoningTokens: number;
13131
+ cacheReadCost: number;
13132
+ cacheWriteCost: number;
13133
+ reasoningCost: number;
13125
13134
  usageByModel: Array<{
13126
13135
  model: string | null;
13127
13136
  llmCalls: number;
@@ -13133,6 +13142,9 @@ export type RetrieveOrganizationAiConversationResponses = {
13133
13142
  reasoningTokens: number;
13134
13143
  inputCost: number;
13135
13144
  outputCost: number;
13145
+ cacheReadCost: number;
13146
+ cacheWriteCost: number;
13147
+ reasoningCost: number;
13136
13148
  totalCost: number;
13137
13149
  }>;
13138
13150
  } | null;
@@ -5968,6 +5968,9 @@ export declare const vRetrieveOrganizationAiConversationResponse: v.ObjectSchema
5968
5968
  readonly cacheWriteTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
5969
5969
  readonly errorToolNames: v.ArraySchema<v.StringSchema<undefined>, undefined>;
5970
5970
  readonly reasoningTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
5971
+ readonly cacheReadCost: v.NumberSchema<undefined>;
5972
+ readonly cacheWriteCost: v.NumberSchema<undefined>;
5973
+ readonly reasoningCost: v.NumberSchema<undefined>;
5971
5974
  readonly usageByModel: v.ArraySchema<v.ObjectSchema<{
5972
5975
  readonly model: v.UnionSchema<[v.StringSchema<undefined>, v.NullSchema<undefined>], undefined>;
5973
5976
  readonly llmCalls: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
@@ -5979,6 +5982,9 @@ export declare const vRetrieveOrganizationAiConversationResponse: v.ObjectSchema
5979
5982
  readonly reasoningTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
5980
5983
  readonly inputCost: v.NumberSchema<undefined>;
5981
5984
  readonly outputCost: v.NumberSchema<undefined>;
5985
+ readonly cacheReadCost: v.NumberSchema<undefined>;
5986
+ readonly cacheWriteCost: v.NumberSchema<undefined>;
5987
+ readonly reasoningCost: v.NumberSchema<undefined>;
5982
5988
  readonly totalCost: v.NumberSchema<undefined>;
5983
5989
  }, undefined>, undefined>;
5984
5990
  }, undefined>, v.NullSchema<undefined>], undefined>;
@@ -7575,6 +7581,9 @@ export declare const vRetrieveOrganizationAiConversationResponse2: v.ObjectSchem
7575
7581
  readonly cacheWriteTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
7576
7582
  readonly errorToolNames: v.ArraySchema<v.StringSchema<undefined>, undefined>;
7577
7583
  readonly reasoningTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
7584
+ readonly cacheReadCost: v.NumberSchema<undefined>;
7585
+ readonly cacheWriteCost: v.NumberSchema<undefined>;
7586
+ readonly reasoningCost: v.NumberSchema<undefined>;
7578
7587
  readonly usageByModel: v.ArraySchema<v.ObjectSchema<{
7579
7588
  readonly model: v.UnionSchema<[v.StringSchema<undefined>, v.NullSchema<undefined>], undefined>;
7580
7589
  readonly llmCalls: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
@@ -7586,6 +7595,9 @@ export declare const vRetrieveOrganizationAiConversationResponse2: v.ObjectSchem
7586
7595
  readonly reasoningTokens: v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>]>;
7587
7596
  readonly inputCost: v.NumberSchema<undefined>;
7588
7597
  readonly outputCost: v.NumberSchema<undefined>;
7598
+ readonly cacheReadCost: v.NumberSchema<undefined>;
7599
+ readonly cacheWriteCost: v.NumberSchema<undefined>;
7600
+ readonly reasoningCost: v.NumberSchema<undefined>;
7589
7601
  readonly totalCost: v.NumberSchema<undefined>;
7590
7602
  }, undefined>, undefined>;
7591
7603
  }, undefined>, v.NullSchema<undefined>], undefined>;
package/dist/valibot.js CHANGED
@@ -7553,6 +7553,9 @@ var vRetrieveOrganizationAiConversationResponse = v.object({
7553
7553
  cacheWriteTokens: v.pipe(v.number(), v.integer()),
7554
7554
  errorToolNames: v.array(v.string()),
7555
7555
  reasoningTokens: v.pipe(v.number(), v.integer()),
7556
+ cacheReadCost: v.number(),
7557
+ cacheWriteCost: v.number(),
7558
+ reasoningCost: v.number(),
7556
7559
  usageByModel: v.array(v.object({
7557
7560
  model: v.union([v.string(), v.null()]),
7558
7561
  llmCalls: v.pipe(v.number(), v.integer()),
@@ -7564,6 +7567,9 @@ var vRetrieveOrganizationAiConversationResponse = v.object({
7564
7567
  reasoningTokens: v.pipe(v.number(), v.integer()),
7565
7568
  inputCost: v.number(),
7566
7569
  outputCost: v.number(),
7570
+ cacheReadCost: v.number(),
7571
+ cacheWriteCost: v.number(),
7572
+ reasoningCost: v.number(),
7567
7573
  totalCost: v.number()
7568
7574
  }))
7569
7575
  }), v.null()])
@@ -9353,6 +9359,9 @@ var vRetrieveOrganizationAiConversationResponse2 = v.object({
9353
9359
  cacheWriteTokens: v.pipe(v.number(), v.integer()),
9354
9360
  errorToolNames: v.array(v.string()),
9355
9361
  reasoningTokens: v.pipe(v.number(), v.integer()),
9362
+ cacheReadCost: v.number(),
9363
+ cacheWriteCost: v.number(),
9364
+ reasoningCost: v.number(),
9356
9365
  usageByModel: v.array(v.object({
9357
9366
  model: v.union([v.string(), v.null()]),
9358
9367
  llmCalls: v.pipe(v.number(), v.integer()),
@@ -9364,6 +9373,9 @@ var vRetrieveOrganizationAiConversationResponse2 = v.object({
9364
9373
  reasoningTokens: v.pipe(v.number(), v.integer()),
9365
9374
  inputCost: v.number(),
9366
9375
  outputCost: v.number(),
9376
+ cacheReadCost: v.number(),
9377
+ cacheWriteCost: v.number(),
9378
+ reasoningCost: v.number(),
9367
9379
  totalCost: v.number()
9368
9380
  }))
9369
9381
  }), v.null()])
package/dist/zod.gen.d.ts CHANGED
@@ -29127,6 +29127,9 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29127
29127
  cacheWriteTokens: z.ZodNumber;
29128
29128
  errorToolNames: z.ZodArray<z.ZodString, "many">;
29129
29129
  reasoningTokens: z.ZodNumber;
29130
+ cacheReadCost: z.ZodNumber;
29131
+ cacheWriteCost: z.ZodNumber;
29132
+ reasoningCost: z.ZodNumber;
29130
29133
  usageByModel: z.ZodArray<z.ZodObject<{
29131
29134
  model: z.ZodUnion<[z.ZodString, z.ZodNull]>;
29132
29135
  llmCalls: z.ZodNumber;
@@ -29138,6 +29141,9 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29138
29141
  reasoningTokens: z.ZodNumber;
29139
29142
  inputCost: z.ZodNumber;
29140
29143
  outputCost: z.ZodNumber;
29144
+ cacheReadCost: z.ZodNumber;
29145
+ cacheWriteCost: z.ZodNumber;
29146
+ reasoningCost: z.ZodNumber;
29141
29147
  totalCost: z.ZodNumber;
29142
29148
  }, "strip", z.ZodTypeAny, {
29143
29149
  model: string | null;
@@ -29151,6 +29157,9 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29151
29157
  reasoningTokens: number;
29152
29158
  inputCost: number;
29153
29159
  outputCost: number;
29160
+ cacheReadCost: number;
29161
+ cacheWriteCost: number;
29162
+ reasoningCost: number;
29154
29163
  }, {
29155
29164
  model: string | null;
29156
29165
  inputTokens: number;
@@ -29163,6 +29172,9 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29163
29172
  reasoningTokens: number;
29164
29173
  inputCost: number;
29165
29174
  outputCost: number;
29175
+ cacheReadCost: number;
29176
+ cacheWriteCost: number;
29177
+ reasoningCost: number;
29166
29178
  }>, "many">;
29167
29179
  }, "strip", z.ZodTypeAny, {
29168
29180
  errors: number;
@@ -29193,7 +29205,13 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29193
29205
  reasoningTokens: number;
29194
29206
  inputCost: number;
29195
29207
  outputCost: number;
29208
+ cacheReadCost: number;
29209
+ cacheWriteCost: number;
29210
+ reasoningCost: number;
29196
29211
  }[];
29212
+ cacheReadCost: number;
29213
+ cacheWriteCost: number;
29214
+ reasoningCost: number;
29197
29215
  }, {
29198
29216
  errors: number;
29199
29217
  startTimestamp: number;
@@ -29223,7 +29241,13 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29223
29241
  reasoningTokens: number;
29224
29242
  inputCost: number;
29225
29243
  outputCost: number;
29244
+ cacheReadCost: number;
29245
+ cacheWriteCost: number;
29246
+ reasoningCost: number;
29226
29247
  }[];
29248
+ cacheReadCost: number;
29249
+ cacheWriteCost: number;
29250
+ reasoningCost: number;
29227
29251
  }>, z.ZodNull]>;
29228
29252
  }, "strip", z.ZodTypeAny, {
29229
29253
  spans: Record<string, unknown>[];
@@ -29256,7 +29280,13 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29256
29280
  reasoningTokens: number;
29257
29281
  inputCost: number;
29258
29282
  outputCost: number;
29283
+ cacheReadCost: number;
29284
+ cacheWriteCost: number;
29285
+ reasoningCost: number;
29259
29286
  }[];
29287
+ cacheReadCost: number;
29288
+ cacheWriteCost: number;
29289
+ reasoningCost: number;
29260
29290
  } | null;
29261
29291
  title: string | null;
29262
29292
  projects: {
@@ -29297,7 +29327,13 @@ export declare const zRetrieveOrganizationAiConversationResponse: z.ZodObject<{
29297
29327
  reasoningTokens: number;
29298
29328
  inputCost: number;
29299
29329
  outputCost: number;
29330
+ cacheReadCost: number;
29331
+ cacheWriteCost: number;
29332
+ reasoningCost: number;
29300
29333
  }[];
29334
+ cacheReadCost: number;
29335
+ cacheWriteCost: number;
29336
+ reasoningCost: number;
29301
29337
  } | null;
29302
29338
  title: string | null;
29303
29339
  projects: {
@@ -36956,6 +36992,9 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
36956
36992
  cacheWriteTokens: z.ZodNumber;
36957
36993
  errorToolNames: z.ZodArray<z.ZodString, "many">;
36958
36994
  reasoningTokens: z.ZodNumber;
36995
+ cacheReadCost: z.ZodNumber;
36996
+ cacheWriteCost: z.ZodNumber;
36997
+ reasoningCost: z.ZodNumber;
36959
36998
  usageByModel: z.ZodArray<z.ZodObject<{
36960
36999
  model: z.ZodUnion<[z.ZodString, z.ZodNull]>;
36961
37000
  llmCalls: z.ZodNumber;
@@ -36967,6 +37006,9 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
36967
37006
  reasoningTokens: z.ZodNumber;
36968
37007
  inputCost: z.ZodNumber;
36969
37008
  outputCost: z.ZodNumber;
37009
+ cacheReadCost: z.ZodNumber;
37010
+ cacheWriteCost: z.ZodNumber;
37011
+ reasoningCost: z.ZodNumber;
36970
37012
  totalCost: z.ZodNumber;
36971
37013
  }, "strip", z.ZodTypeAny, {
36972
37014
  model: string | null;
@@ -36980,6 +37022,9 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
36980
37022
  reasoningTokens: number;
36981
37023
  inputCost: number;
36982
37024
  outputCost: number;
37025
+ cacheReadCost: number;
37026
+ cacheWriteCost: number;
37027
+ reasoningCost: number;
36983
37028
  }, {
36984
37029
  model: string | null;
36985
37030
  inputTokens: number;
@@ -36992,6 +37037,9 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
36992
37037
  reasoningTokens: number;
36993
37038
  inputCost: number;
36994
37039
  outputCost: number;
37040
+ cacheReadCost: number;
37041
+ cacheWriteCost: number;
37042
+ reasoningCost: number;
36995
37043
  }>, "many">;
36996
37044
  }, "strip", z.ZodTypeAny, {
36997
37045
  errors: number;
@@ -37022,7 +37070,13 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
37022
37070
  reasoningTokens: number;
37023
37071
  inputCost: number;
37024
37072
  outputCost: number;
37073
+ cacheReadCost: number;
37074
+ cacheWriteCost: number;
37075
+ reasoningCost: number;
37025
37076
  }[];
37077
+ cacheReadCost: number;
37078
+ cacheWriteCost: number;
37079
+ reasoningCost: number;
37026
37080
  }, {
37027
37081
  errors: number;
37028
37082
  startTimestamp: number;
@@ -37052,7 +37106,13 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
37052
37106
  reasoningTokens: number;
37053
37107
  inputCost: number;
37054
37108
  outputCost: number;
37109
+ cacheReadCost: number;
37110
+ cacheWriteCost: number;
37111
+ reasoningCost: number;
37055
37112
  }[];
37113
+ cacheReadCost: number;
37114
+ cacheWriteCost: number;
37115
+ reasoningCost: number;
37056
37116
  }>, z.ZodNull]>;
37057
37117
  }, "strip", z.ZodTypeAny, {
37058
37118
  spans: Record<string, unknown>[];
@@ -37085,7 +37145,13 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
37085
37145
  reasoningTokens: number;
37086
37146
  inputCost: number;
37087
37147
  outputCost: number;
37148
+ cacheReadCost: number;
37149
+ cacheWriteCost: number;
37150
+ reasoningCost: number;
37088
37151
  }[];
37152
+ cacheReadCost: number;
37153
+ cacheWriteCost: number;
37154
+ reasoningCost: number;
37089
37155
  } | null;
37090
37156
  title: string | null;
37091
37157
  projects: {
@@ -37126,7 +37192,13 @@ export declare const zRetrieveOrganizationAiConversationResponse2: z.ZodObject<{
37126
37192
  reasoningTokens: number;
37127
37193
  inputCost: number;
37128
37194
  outputCost: number;
37195
+ cacheReadCost: number;
37196
+ cacheWriteCost: number;
37197
+ reasoningCost: number;
37129
37198
  }[];
37199
+ cacheReadCost: number;
37200
+ cacheWriteCost: number;
37201
+ reasoningCost: number;
37130
37202
  } | null;
37131
37203
  title: string | null;
37132
37204
  projects: {
package/dist/zod.js CHANGED
@@ -11625,6 +11625,9 @@ var zRetrieveOrganizationAiConversationResponse = z.object({
11625
11625
  cacheWriteTokens: z.number().int(),
11626
11626
  errorToolNames: z.array(z.string()),
11627
11627
  reasoningTokens: z.number().int(),
11628
+ cacheReadCost: z.number(),
11629
+ cacheWriteCost: z.number(),
11630
+ reasoningCost: z.number(),
11628
11631
  usageByModel: z.array(z.object({
11629
11632
  model: z.union([
11630
11633
  z.string(),
@@ -11639,6 +11642,9 @@ var zRetrieveOrganizationAiConversationResponse = z.object({
11639
11642
  reasoningTokens: z.number().int(),
11640
11643
  inputCost: z.number(),
11641
11644
  outputCost: z.number(),
11645
+ cacheReadCost: z.number(),
11646
+ cacheWriteCost: z.number(),
11647
+ reasoningCost: z.number(),
11642
11648
  totalCost: z.number()
11643
11649
  }))
11644
11650
  }),
@@ -14234,6 +14240,9 @@ var zRetrieveOrganizationAiConversationResponse2 = z.object({
14234
14240
  cacheWriteTokens: z.number().int(),
14235
14241
  errorToolNames: z.array(z.string()),
14236
14242
  reasoningTokens: z.number().int(),
14243
+ cacheReadCost: z.number(),
14244
+ cacheWriteCost: z.number(),
14245
+ reasoningCost: z.number(),
14237
14246
  usageByModel: z.array(z.object({
14238
14247
  model: z.union([
14239
14248
  z.string(),
@@ -14248,6 +14257,9 @@ var zRetrieveOrganizationAiConversationResponse2 = z.object({
14248
14257
  reasoningTokens: z.number().int(),
14249
14258
  inputCost: z.number(),
14250
14259
  outputCost: z.number(),
14260
+ cacheReadCost: z.number(),
14261
+ cacheWriteCost: z.number(),
14262
+ reasoningCost: z.number(),
14251
14263
  totalCost: z.number()
14252
14264
  }))
14253
14265
  }),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/api",
3
- "version": "0.364.0",
3
+ "version": "0.366.0",
4
4
  "description": "Official auto-generated TypeScript client for the Sentry public REST API",
5
5
  "keywords": [
6
6
  "sentry",