@miradorlabs/web-grpc 3.28.0 → 3.29.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/google/api/field_behavior.ts +1 -1
- package/google/protobuf/descriptor.ts +24 -14
- package/google/protobuf/duration.ts +1 -1
- package/google/protobuf/timestamp.ts +1 -1
- package/package.json +1 -1
- package/proto/gateway/common/v1/attribute_value.ts +6 -2
- package/proto/gateway/common/v1/status.ts +1 -1
- package/proto/gateway/common/v1/types.ts +1 -1
- package/proto/gateway/web/v1/account_gateway.ts +6 -2
- package/proto/gateway/web/v1/admin_gateway.ts +1 -1
- package/proto/gateway/web/v1/ai_gateway.ts +44 -40
- package/proto/gateway/web/v1/attribute_value.ts +6 -2
- package/proto/gateway/web/v1/beta_gateway.ts +1 -1
- package/proto/gateway/web/v1/chain_gateway.ts +6 -2
- package/proto/gateway/web/v1/common.ts +1 -1
- package/proto/gateway/web/v1/derived_metric_gateway.ts +6 -2
- package/proto/gateway/web/v1/github_connector.ts +65 -824
- package/proto/gateway/web/v1/github_connector_grpc_pb.js +0 -69
- package/proto/gateway/web/v1/github_connector_pb.js +0 -1430
- package/proto/gateway/web/v1/integration_gateway.ts +1 -1
- package/proto/gateway/web/v1/log_gateway.ts +1 -1
- package/proto/gateway/web/v1/market_gateway.ts +6 -2
- package/proto/gateway/web/v1/metric_gateway.ts +6 -2
- package/proto/gateway/web/v1/oauth_gateway.ts +1 -1
- package/proto/gateway/web/v1/plan_gateway.ts +1 -1
- package/proto/gateway/web/v1/policy_gateway.ts +1 -1
- package/proto/gateway/web/v1/reference_gateway.ts +1 -1
- package/proto/gateway/web/v1/rule_gateway.ts +7 -3
- package/proto/gateway/web/v1/slo_gateway.ts +12 -8
- package/proto/gateway/web/v1/trace_gateway.ts +21 -15
- package/proto/gateway/web/v1/trace_measure_gateway.ts +6 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: google/protobuf/descriptor.proto
|
|
6
6
|
|
|
@@ -4585,7 +4585,7 @@ export const UninterpretedOption: MessageFns<UninterpretedOption> = {
|
|
|
4585
4585
|
obj.negativeIntValue = Math.round(message.negativeIntValue);
|
|
4586
4586
|
}
|
|
4587
4587
|
if (message.doubleValue !== undefined && message.doubleValue !== 0) {
|
|
4588
|
-
obj.doubleValue = message.doubleValue;
|
|
4588
|
+
obj.doubleValue = floatToJson(message.doubleValue);
|
|
4589
4589
|
}
|
|
4590
4590
|
if (message.stringValue !== undefined && message.stringValue.length !== 0) {
|
|
4591
4591
|
obj.stringValue = base64FromBytes(message.stringValue);
|
|
@@ -4782,16 +4782,20 @@ function createBaseSourceCodeInfo_Location(): SourceCodeInfo_Location {
|
|
|
4782
4782
|
|
|
4783
4783
|
export const SourceCodeInfo_Location: MessageFns<SourceCodeInfo_Location> = {
|
|
4784
4784
|
encode(message: SourceCodeInfo_Location, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
4785
|
-
|
|
4786
|
-
|
|
4787
|
-
|
|
4785
|
+
if (message.path.length !== 0) {
|
|
4786
|
+
writer.uint32(10).fork();
|
|
4787
|
+
for (const v of message.path) {
|
|
4788
|
+
writer.int32(v);
|
|
4789
|
+
}
|
|
4790
|
+
writer.join();
|
|
4788
4791
|
}
|
|
4789
|
-
|
|
4790
|
-
|
|
4791
|
-
|
|
4792
|
-
|
|
4792
|
+
if (message.span.length !== 0) {
|
|
4793
|
+
writer.uint32(18).fork();
|
|
4794
|
+
for (const v of message.span) {
|
|
4795
|
+
writer.int32(v);
|
|
4796
|
+
}
|
|
4797
|
+
writer.join();
|
|
4793
4798
|
}
|
|
4794
|
-
writer.join();
|
|
4795
4799
|
if (message.leadingComments !== undefined && message.leadingComments !== "") {
|
|
4796
4800
|
writer.uint32(26).string(message.leadingComments);
|
|
4797
4801
|
}
|
|
@@ -5022,11 +5026,13 @@ function createBaseGeneratedCodeInfo_Annotation(): GeneratedCodeInfo_Annotation
|
|
|
5022
5026
|
|
|
5023
5027
|
export const GeneratedCodeInfo_Annotation: MessageFns<GeneratedCodeInfo_Annotation> = {
|
|
5024
5028
|
encode(message: GeneratedCodeInfo_Annotation, writer: BinaryWriter = new BinaryWriter()): BinaryWriter {
|
|
5025
|
-
|
|
5026
|
-
|
|
5027
|
-
|
|
5029
|
+
if (message.path.length !== 0) {
|
|
5030
|
+
writer.uint32(10).fork();
|
|
5031
|
+
for (const v of message.path) {
|
|
5032
|
+
writer.int32(v);
|
|
5033
|
+
}
|
|
5034
|
+
writer.join();
|
|
5028
5035
|
}
|
|
5029
|
-
writer.join();
|
|
5030
5036
|
if (message.sourceFile !== undefined && message.sourceFile !== "") {
|
|
5031
5037
|
writer.uint32(18).string(message.sourceFile);
|
|
5032
5038
|
}
|
|
@@ -5174,6 +5180,10 @@ function base64FromBytes(arr: Uint8Array): string {
|
|
|
5174
5180
|
}
|
|
5175
5181
|
}
|
|
5176
5182
|
|
|
5183
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
5184
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
5185
|
+
}
|
|
5186
|
+
|
|
5177
5187
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
5178
5188
|
|
|
5179
5189
|
export type DeepPartial<T> = T extends Builtin ? T
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/common/v1/attribute_value.proto
|
|
6
6
|
|
|
@@ -209,7 +209,7 @@ export const AttributeValue: MessageFns<AttributeValue> = {
|
|
|
209
209
|
obj.intValue = Math.round(message.intValue);
|
|
210
210
|
}
|
|
211
211
|
if (message.doubleValue !== undefined) {
|
|
212
|
-
obj.doubleValue = message.doubleValue;
|
|
212
|
+
obj.doubleValue = floatToJson(message.doubleValue);
|
|
213
213
|
}
|
|
214
214
|
if (message.bytesValue !== undefined) {
|
|
215
215
|
obj.bytesValue = base64FromBytes(message.bytesValue);
|
|
@@ -495,6 +495,10 @@ function base64FromBytes(arr: Uint8Array): string {
|
|
|
495
495
|
}
|
|
496
496
|
}
|
|
497
497
|
|
|
498
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
499
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
500
|
+
}
|
|
501
|
+
|
|
498
502
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
499
503
|
|
|
500
504
|
export type DeepPartial<T> = T extends Builtin ? T
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/web/v1/account_gateway.proto
|
|
6
6
|
|
|
@@ -8328,7 +8328,7 @@ export const ProjectStats: MessageFns<ProjectStats> = {
|
|
|
8328
8328
|
obj.activeTraceCount = Math.round(message.activeTraceCount);
|
|
8329
8329
|
}
|
|
8330
8330
|
if (message.successRate !== 0) {
|
|
8331
|
-
obj.successRate = message.successRate;
|
|
8331
|
+
obj.successRate = floatToJson(message.successRate);
|
|
8332
8332
|
}
|
|
8333
8333
|
if (message.avgDurationMs !== 0) {
|
|
8334
8334
|
obj.avgDurationMs = Math.round(message.avgDurationMs);
|
|
@@ -9602,6 +9602,10 @@ interface Rpc {
|
|
|
9602
9602
|
): Observable<Uint8Array>;
|
|
9603
9603
|
}
|
|
9604
9604
|
|
|
9605
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
9606
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
9607
|
+
}
|
|
9608
|
+
|
|
9605
9609
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
9606
9610
|
|
|
9607
9611
|
export type DeepPartial<T> = T extends Builtin ? T
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/web/v1/ai_gateway.proto
|
|
6
6
|
|
|
@@ -9693,7 +9693,7 @@ export const TokenActivityMeasures: MessageFns<TokenActivityMeasures> = {
|
|
|
9693
9693
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
9694
9694
|
}
|
|
9695
9695
|
if (message.costUsd !== 0) {
|
|
9696
|
-
obj.costUsd = message.costUsd;
|
|
9696
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
9697
9697
|
}
|
|
9698
9698
|
if (message.modelCalls !== 0) {
|
|
9699
9699
|
obj.modelCalls = Math.round(message.modelCalls);
|
|
@@ -10490,10 +10490,10 @@ export const BurnRateMeasures: MessageFns<BurnRateMeasures> = {
|
|
|
10490
10490
|
toJSON(message: BurnRateMeasures): unknown {
|
|
10491
10491
|
const obj: any = {};
|
|
10492
10492
|
if (message.usdPerHour !== 0) {
|
|
10493
|
-
obj.usdPerHour = message.usdPerHour;
|
|
10493
|
+
obj.usdPerHour = floatToJson(message.usdPerHour);
|
|
10494
10494
|
}
|
|
10495
10495
|
if (message.tokensPerMin !== 0) {
|
|
10496
|
-
obj.tokensPerMin = message.tokensPerMin;
|
|
10496
|
+
obj.tokensPerMin = floatToJson(message.tokensPerMin);
|
|
10497
10497
|
}
|
|
10498
10498
|
if (message.modelCalls !== 0) {
|
|
10499
10499
|
obj.modelCalls = Math.round(message.modelCalls);
|
|
@@ -10505,19 +10505,19 @@ export const BurnRateMeasures: MessageFns<BurnRateMeasures> = {
|
|
|
10505
10505
|
obj.usageUnavailableCount = Math.round(message.usageUnavailableCount);
|
|
10506
10506
|
}
|
|
10507
10507
|
if (message.subscriptionFacilityUsdPerHour !== 0) {
|
|
10508
|
-
obj.subscriptionFacilityUsdPerHour = message.subscriptionFacilityUsdPerHour;
|
|
10508
|
+
obj.subscriptionFacilityUsdPerHour = floatToJson(message.subscriptionFacilityUsdPerHour);
|
|
10509
10509
|
}
|
|
10510
10510
|
if (message.inputTokensPerMin !== 0) {
|
|
10511
|
-
obj.inputTokensPerMin = message.inputTokensPerMin;
|
|
10511
|
+
obj.inputTokensPerMin = floatToJson(message.inputTokensPerMin);
|
|
10512
10512
|
}
|
|
10513
10513
|
if (message.outputTokensPerMin !== 0) {
|
|
10514
|
-
obj.outputTokensPerMin = message.outputTokensPerMin;
|
|
10514
|
+
obj.outputTokensPerMin = floatToJson(message.outputTokensPerMin);
|
|
10515
10515
|
}
|
|
10516
10516
|
if (message.cacheReadTokensPerMin !== 0) {
|
|
10517
|
-
obj.cacheReadTokensPerMin = message.cacheReadTokensPerMin;
|
|
10517
|
+
obj.cacheReadTokensPerMin = floatToJson(message.cacheReadTokensPerMin);
|
|
10518
10518
|
}
|
|
10519
10519
|
if (message.cacheWriteTokensPerMin !== 0) {
|
|
10520
|
-
obj.cacheWriteTokensPerMin = message.cacheWriteTokensPerMin;
|
|
10520
|
+
obj.cacheWriteTokensPerMin = floatToJson(message.cacheWriteTokensPerMin);
|
|
10521
10521
|
}
|
|
10522
10522
|
return obj;
|
|
10523
10523
|
},
|
|
@@ -11595,7 +11595,7 @@ export const DailyActivityMeasures: MessageFns<DailyActivityMeasures> = {
|
|
|
11595
11595
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
11596
11596
|
}
|
|
11597
11597
|
if (message.costUsd !== 0) {
|
|
11598
|
-
obj.costUsd = message.costUsd;
|
|
11598
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
11599
11599
|
}
|
|
11600
11600
|
if (message.modelCalls !== 0) {
|
|
11601
11601
|
obj.modelCalls = Math.round(message.modelCalls);
|
|
@@ -11637,7 +11637,7 @@ export const DailyActivityMeasures: MessageFns<DailyActivityMeasures> = {
|
|
|
11637
11637
|
obj.subscriptionFacilityCacheWriteTokens = Math.round(message.subscriptionFacilityCacheWriteTokens);
|
|
11638
11638
|
}
|
|
11639
11639
|
if (message.subscriptionFacilityUsd !== 0) {
|
|
11640
|
-
obj.subscriptionFacilityUsd = message.subscriptionFacilityUsd;
|
|
11640
|
+
obj.subscriptionFacilityUsd = floatToJson(message.subscriptionFacilityUsd);
|
|
11641
11641
|
}
|
|
11642
11642
|
if (message.sessions !== 0) {
|
|
11643
11643
|
obj.sessions = Math.round(message.sessions);
|
|
@@ -12871,7 +12871,7 @@ export const ProjectOverviewTotals: MessageFns<ProjectOverviewTotals> = {
|
|
|
12871
12871
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
12872
12872
|
}
|
|
12873
12873
|
if (message.costUsd !== 0) {
|
|
12874
|
-
obj.costUsd = message.costUsd;
|
|
12874
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
12875
12875
|
}
|
|
12876
12876
|
if (message.distinctUsers !== 0) {
|
|
12877
12877
|
obj.distinctUsers = Math.round(message.distinctUsers);
|
|
@@ -12889,7 +12889,7 @@ export const ProjectOverviewTotals: MessageFns<ProjectOverviewTotals> = {
|
|
|
12889
12889
|
obj.lastActivityAt = message.lastActivityAt.toISOString();
|
|
12890
12890
|
}
|
|
12891
12891
|
if (message.subscriptionCostUsd !== 0) {
|
|
12892
|
-
obj.subscriptionCostUsd = message.subscriptionCostUsd;
|
|
12892
|
+
obj.subscriptionCostUsd = floatToJson(message.subscriptionCostUsd);
|
|
12893
12893
|
}
|
|
12894
12894
|
return obj;
|
|
12895
12895
|
},
|
|
@@ -13064,10 +13064,10 @@ export const ProjectOverviewSlice: MessageFns<ProjectOverviewSlice> = {
|
|
|
13064
13064
|
obj.outputTokens = Math.round(message.outputTokens);
|
|
13065
13065
|
}
|
|
13066
13066
|
if (message.costUsd !== 0) {
|
|
13067
|
-
obj.costUsd = message.costUsd;
|
|
13067
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
13068
13068
|
}
|
|
13069
13069
|
if (message.subscriptionCostUsd !== 0) {
|
|
13070
|
-
obj.subscriptionCostUsd = message.subscriptionCostUsd;
|
|
13070
|
+
obj.subscriptionCostUsd = floatToJson(message.subscriptionCostUsd);
|
|
13071
13071
|
}
|
|
13072
13072
|
return obj;
|
|
13073
13073
|
},
|
|
@@ -13339,7 +13339,7 @@ export const ProjectUsageBucket: MessageFns<ProjectUsageBucket> = {
|
|
|
13339
13339
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
13340
13340
|
}
|
|
13341
13341
|
if (message.costUsd !== 0) {
|
|
13342
|
-
obj.costUsd = message.costUsd;
|
|
13342
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
13343
13343
|
}
|
|
13344
13344
|
return obj;
|
|
13345
13345
|
},
|
|
@@ -14022,7 +14022,7 @@ export const ProjectSessionRef: MessageFns<ProjectSessionRef> = {
|
|
|
14022
14022
|
obj.sourceSystem = message.sourceSystem;
|
|
14023
14023
|
}
|
|
14024
14024
|
if (message.costUsd !== 0) {
|
|
14025
|
-
obj.costUsd = message.costUsd;
|
|
14025
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
14026
14026
|
}
|
|
14027
14027
|
if (message.modelCalls !== 0) {
|
|
14028
14028
|
obj.modelCalls = Math.round(message.modelCalls);
|
|
@@ -15211,10 +15211,10 @@ export const ModelActivity: MessageFns<ModelActivity> = {
|
|
|
15211
15211
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
15212
15212
|
}
|
|
15213
15213
|
if (message.costUsd !== 0) {
|
|
15214
|
-
obj.costUsd = message.costUsd;
|
|
15214
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
15215
15215
|
}
|
|
15216
15216
|
if (message.subscriptionCostUsd !== 0) {
|
|
15217
|
-
obj.subscriptionCostUsd = message.subscriptionCostUsd;
|
|
15217
|
+
obj.subscriptionCostUsd = floatToJson(message.subscriptionCostUsd);
|
|
15218
15218
|
}
|
|
15219
15219
|
if (message.sessions !== 0) {
|
|
15220
15220
|
obj.sessions = Math.round(message.sessions);
|
|
@@ -15448,7 +15448,7 @@ export const ModelActivityPrincipal: MessageFns<ModelActivityPrincipal> = {
|
|
|
15448
15448
|
obj.outputTokens = Math.round(message.outputTokens);
|
|
15449
15449
|
}
|
|
15450
15450
|
if (message.costUsd !== 0) {
|
|
15451
|
-
obj.costUsd = message.costUsd;
|
|
15451
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
15452
15452
|
}
|
|
15453
15453
|
return obj;
|
|
15454
15454
|
},
|
|
@@ -15948,7 +15948,7 @@ export const SessionUsageBucket: MessageFns<SessionUsageBucket> = {
|
|
|
15948
15948
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
15949
15949
|
}
|
|
15950
15950
|
if (message.costUsd !== 0) {
|
|
15951
|
-
obj.costUsd = message.costUsd;
|
|
15951
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
15952
15952
|
}
|
|
15953
15953
|
return obj;
|
|
15954
15954
|
},
|
|
@@ -17360,19 +17360,19 @@ export const AIFileRow: MessageFns<AIFileRow> = {
|
|
|
17360
17360
|
obj.sessions = message.sessions.map((e) => AISessionRef.toJSON(e));
|
|
17361
17361
|
}
|
|
17362
17362
|
if (message.unlandedCostUsd !== 0) {
|
|
17363
|
-
obj.unlandedCostUsd = message.unlandedCostUsd;
|
|
17363
|
+
obj.unlandedCostUsd = floatToJson(message.unlandedCostUsd);
|
|
17364
17364
|
}
|
|
17365
17365
|
if (message.unlandedOutputTokens !== 0) {
|
|
17366
17366
|
obj.unlandedOutputTokens = Math.round(message.unlandedOutputTokens);
|
|
17367
17367
|
}
|
|
17368
17368
|
if (message.totalCostUsd !== 0) {
|
|
17369
|
-
obj.totalCostUsd = message.totalCostUsd;
|
|
17369
|
+
obj.totalCostUsd = floatToJson(message.totalCostUsd);
|
|
17370
17370
|
}
|
|
17371
17371
|
if (message.subscriptionTotalCostUsd !== 0) {
|
|
17372
|
-
obj.subscriptionTotalCostUsd = message.subscriptionTotalCostUsd;
|
|
17372
|
+
obj.subscriptionTotalCostUsd = floatToJson(message.subscriptionTotalCostUsd);
|
|
17373
17373
|
}
|
|
17374
17374
|
if (message.subscriptionUnlandedCostUsd !== 0) {
|
|
17375
|
-
obj.subscriptionUnlandedCostUsd = message.subscriptionUnlandedCostUsd;
|
|
17375
|
+
obj.subscriptionUnlandedCostUsd = floatToJson(message.subscriptionUnlandedCostUsd);
|
|
17376
17376
|
}
|
|
17377
17377
|
return obj;
|
|
17378
17378
|
},
|
|
@@ -17802,10 +17802,10 @@ export const AIFileDirectory: MessageFns<AIFileDirectory> = {
|
|
|
17802
17802
|
obj.sessions = Math.round(message.sessions);
|
|
17803
17803
|
}
|
|
17804
17804
|
if (message.unlandedCostUsd !== 0) {
|
|
17805
|
-
obj.unlandedCostUsd = message.unlandedCostUsd;
|
|
17805
|
+
obj.unlandedCostUsd = floatToJson(message.unlandedCostUsd);
|
|
17806
17806
|
}
|
|
17807
17807
|
if (message.subscriptionUnlandedCostUsd !== 0) {
|
|
17808
|
-
obj.subscriptionUnlandedCostUsd = message.subscriptionUnlandedCostUsd;
|
|
17808
|
+
obj.subscriptionUnlandedCostUsd = floatToJson(message.subscriptionUnlandedCostUsd);
|
|
17809
17809
|
}
|
|
17810
17810
|
if (message.unlandedOutputTokens !== 0) {
|
|
17811
17811
|
obj.unlandedOutputTokens = Math.round(message.unlandedOutputTokens);
|
|
@@ -18505,7 +18505,7 @@ export const FileTierBucket: MessageFns<FileTierBucket> = {
|
|
|
18505
18505
|
obj.sessions = Math.round(message.sessions);
|
|
18506
18506
|
}
|
|
18507
18507
|
if (message.costUsd !== 0) {
|
|
18508
|
-
obj.costUsd = message.costUsd;
|
|
18508
|
+
obj.costUsd = floatToJson(message.costUsd);
|
|
18509
18509
|
}
|
|
18510
18510
|
if (message.outputTokens !== 0) {
|
|
18511
18511
|
obj.outputTokens = Math.round(message.outputTokens);
|
|
@@ -18514,7 +18514,7 @@ export const FileTierBucket: MessageFns<FileTierBucket> = {
|
|
|
18514
18514
|
obj.oldestAge = Duration.toJSON(message.oldestAge);
|
|
18515
18515
|
}
|
|
18516
18516
|
if (message.subscriptionCostUsd !== 0) {
|
|
18517
|
-
obj.subscriptionCostUsd = message.subscriptionCostUsd;
|
|
18517
|
+
obj.subscriptionCostUsd = floatToJson(message.subscriptionCostUsd);
|
|
18518
18518
|
}
|
|
18519
18519
|
return obj;
|
|
18520
18520
|
},
|
|
@@ -19602,16 +19602,16 @@ export const AIModelPrice: MessageFns<AIModelPrice> = {
|
|
|
19602
19602
|
obj.scrapedAt = message.scrapedAt.toISOString();
|
|
19603
19603
|
}
|
|
19604
19604
|
if (message.inputUsdPerMtok !== 0) {
|
|
19605
|
-
obj.inputUsdPerMtok = message.inputUsdPerMtok;
|
|
19605
|
+
obj.inputUsdPerMtok = floatToJson(message.inputUsdPerMtok);
|
|
19606
19606
|
}
|
|
19607
19607
|
if (message.outputUsdPerMtok !== 0) {
|
|
19608
|
-
obj.outputUsdPerMtok = message.outputUsdPerMtok;
|
|
19608
|
+
obj.outputUsdPerMtok = floatToJson(message.outputUsdPerMtok);
|
|
19609
19609
|
}
|
|
19610
19610
|
if (message.cacheReadUsdPerMtok !== 0) {
|
|
19611
|
-
obj.cacheReadUsdPerMtok = message.cacheReadUsdPerMtok;
|
|
19611
|
+
obj.cacheReadUsdPerMtok = floatToJson(message.cacheReadUsdPerMtok);
|
|
19612
19612
|
}
|
|
19613
19613
|
if (message.cacheWriteUsdPerMtok !== 0) {
|
|
19614
|
-
obj.cacheWriteUsdPerMtok = message.cacheWriteUsdPerMtok;
|
|
19614
|
+
obj.cacheWriteUsdPerMtok = floatToJson(message.cacheWriteUsdPerMtok);
|
|
19615
19615
|
}
|
|
19616
19616
|
if (message.providerRaw !== "") {
|
|
19617
19617
|
obj.providerRaw = message.providerRaw;
|
|
@@ -19806,7 +19806,7 @@ export const AITokenUsage: MessageFns<AITokenUsage> = {
|
|
|
19806
19806
|
obj.cacheWriteTokens = Math.round(message.cacheWriteTokens);
|
|
19807
19807
|
}
|
|
19808
19808
|
if (message.providerCostUsd !== 0) {
|
|
19809
|
-
obj.providerCostUsd = message.providerCostUsd;
|
|
19809
|
+
obj.providerCostUsd = floatToJson(message.providerCostUsd);
|
|
19810
19810
|
}
|
|
19811
19811
|
if (message.facilityCostBreakdown !== undefined) {
|
|
19812
19812
|
obj.facilityCostBreakdown = AIFacilityCostBreakdown.toJSON(message.facilityCostBreakdown);
|
|
@@ -19994,19 +19994,19 @@ export const AIFacilityCostBreakdown: MessageFns<AIFacilityCostBreakdown> = {
|
|
|
19994
19994
|
toJSON(message: AIFacilityCostBreakdown): unknown {
|
|
19995
19995
|
const obj: any = {};
|
|
19996
19996
|
if (message.notionalUsd !== 0) {
|
|
19997
|
-
obj.notionalUsd = message.notionalUsd;
|
|
19997
|
+
obj.notionalUsd = floatToJson(message.notionalUsd);
|
|
19998
19998
|
}
|
|
19999
19999
|
if (message.subscriptionFacilityUsd !== 0) {
|
|
20000
|
-
obj.subscriptionFacilityUsd = message.subscriptionFacilityUsd;
|
|
20000
|
+
obj.subscriptionFacilityUsd = floatToJson(message.subscriptionFacilityUsd);
|
|
20001
20001
|
}
|
|
20002
20002
|
if (message.prepaidCreditsFacilityUsd !== 0) {
|
|
20003
|
-
obj.prepaidCreditsFacilityUsd = message.prepaidCreditsFacilityUsd;
|
|
20003
|
+
obj.prepaidCreditsFacilityUsd = floatToJson(message.prepaidCreditsFacilityUsd);
|
|
20004
20004
|
}
|
|
20005
20005
|
if (message.apiMeteredFacilityUsd !== 0) {
|
|
20006
|
-
obj.apiMeteredFacilityUsd = message.apiMeteredFacilityUsd;
|
|
20006
|
+
obj.apiMeteredFacilityUsd = floatToJson(message.apiMeteredFacilityUsd);
|
|
20007
20007
|
}
|
|
20008
20008
|
if (message.unknownFacilityUsd !== 0) {
|
|
20009
|
-
obj.unknownFacilityUsd = message.unknownFacilityUsd;
|
|
20009
|
+
obj.unknownFacilityUsd = floatToJson(message.unknownFacilityUsd);
|
|
20010
20010
|
}
|
|
20011
20011
|
if (message.pricedCalls !== 0) {
|
|
20012
20012
|
obj.pricedCalls = Math.round(message.pricedCalls);
|
|
@@ -20695,7 +20695,7 @@ export const EntitlementWindow: MessageFns<EntitlementWindow> = {
|
|
|
20695
20695
|
obj.kind = message.kind;
|
|
20696
20696
|
}
|
|
20697
20697
|
if (message.usedPct !== undefined) {
|
|
20698
|
-
obj.usedPct = message.usedPct;
|
|
20698
|
+
obj.usedPct = floatToJson(message.usedPct);
|
|
20699
20699
|
}
|
|
20700
20700
|
if (message.resetsAt !== undefined) {
|
|
20701
20701
|
obj.resetsAt = message.resetsAt.toISOString();
|
|
@@ -21066,6 +21066,10 @@ interface Rpc {
|
|
|
21066
21066
|
): Observable<Uint8Array>;
|
|
21067
21067
|
}
|
|
21068
21068
|
|
|
21069
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
21070
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
21071
|
+
}
|
|
21072
|
+
|
|
21069
21073
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
21070
21074
|
|
|
21071
21075
|
export type DeepPartial<T> = T extends Builtin ? T
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/web/v1/attribute_value.proto
|
|
6
6
|
|
|
@@ -209,7 +209,7 @@ export const AttributeValue: MessageFns<AttributeValue> = {
|
|
|
209
209
|
obj.intValue = Math.round(message.intValue);
|
|
210
210
|
}
|
|
211
211
|
if (message.doubleValue !== undefined) {
|
|
212
|
-
obj.doubleValue = message.doubleValue;
|
|
212
|
+
obj.doubleValue = floatToJson(message.doubleValue);
|
|
213
213
|
}
|
|
214
214
|
if (message.bytesValue !== undefined) {
|
|
215
215
|
obj.bytesValue = base64FromBytes(message.bytesValue);
|
|
@@ -495,6 +495,10 @@ function base64FromBytes(arr: Uint8Array): string {
|
|
|
495
495
|
}
|
|
496
496
|
}
|
|
497
497
|
|
|
498
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
499
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
500
|
+
}
|
|
501
|
+
|
|
498
502
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
499
503
|
|
|
500
504
|
export type DeepPartial<T> = T extends Builtin ? T
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/web/v1/chain_gateway.proto
|
|
6
6
|
|
|
@@ -3445,7 +3445,7 @@ export const FiatValue: MessageFns<FiatValue> = {
|
|
|
3445
3445
|
obj.currency = message.currency;
|
|
3446
3446
|
}
|
|
3447
3447
|
if (message.amount !== 0) {
|
|
3448
|
-
obj.amount = message.amount;
|
|
3448
|
+
obj.amount = floatToJson(message.amount);
|
|
3449
3449
|
}
|
|
3450
3450
|
if (message.formatted !== "") {
|
|
3451
3451
|
obj.formatted = message.formatted;
|
|
@@ -4401,6 +4401,10 @@ interface Rpc {
|
|
|
4401
4401
|
): Observable<Uint8Array>;
|
|
4402
4402
|
}
|
|
4403
4403
|
|
|
4404
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
4405
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
4406
|
+
}
|
|
4407
|
+
|
|
4404
4408
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
4405
4409
|
|
|
4406
4410
|
export type DeepPartial<T> = T extends Builtin ? T
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Code generated by protoc-gen-ts_proto. DO NOT EDIT.
|
|
2
2
|
// versions:
|
|
3
|
-
// protoc-gen-ts_proto v2.
|
|
3
|
+
// protoc-gen-ts_proto v2.15.0
|
|
4
4
|
// protoc v3.21.12
|
|
5
5
|
// source: proto/gateway/web/v1/derived_metric_gateway.proto
|
|
6
6
|
|
|
@@ -2473,7 +2473,7 @@ export const DryRunEmission: MessageFns<DryRunEmission> = {
|
|
|
2473
2473
|
toJSON(message: DryRunEmission): unknown {
|
|
2474
2474
|
const obj: any = {};
|
|
2475
2475
|
if (message.value !== 0) {
|
|
2476
|
-
obj.value = message.value;
|
|
2476
|
+
obj.value = floatToJson(message.value);
|
|
2477
2477
|
}
|
|
2478
2478
|
if (message.resolvedDimensions) {
|
|
2479
2479
|
const entries = globalThis.Object.entries(message.resolvedDimensions) as [string, string][];
|
|
@@ -2833,6 +2833,10 @@ interface Rpc {
|
|
|
2833
2833
|
request(service: string, method: string, data: Uint8Array, metadata?: Metadata): Promise<Uint8Array>;
|
|
2834
2834
|
}
|
|
2835
2835
|
|
|
2836
|
+
function floatToJson(value: number | null | undefined): number | string | null | undefined {
|
|
2837
|
+
return typeof value === "number" && !globalThis.Number.isFinite(value) ? globalThis.String(value) : value;
|
|
2838
|
+
}
|
|
2839
|
+
|
|
2836
2840
|
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
2837
2841
|
|
|
2838
2842
|
export type DeepPartial<T> = T extends Builtin ? T
|