@sentio/protos 2.3.1 → 2.3.2-rc.1

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sentio/protos",
3
3
  "license": "Apache-2.0",
4
- "version": "2.3.1",
4
+ "version": "2.3.2-rc.1",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "compile": "tsc",
@@ -22,5 +22,5 @@
22
22
  "!{lib,src}/tests",
23
23
  "!**/*.test.{js,ts}"
24
24
  ],
25
- "gitHead": "563d5df7771eb677356142ebd83836e469eb246e"
25
+ "gitHead": "e009009439a4b3cec12aa9cc6ac7e869a1cac1ef"
26
26
  }
@@ -80,6 +80,17 @@ export interface EvmQueryResponse {
80
80
  executionSummary?: QueryExecutionSummary | undefined;
81
81
  }
82
82
 
83
+ export interface SuiGetCheckpointTimeRequest {
84
+ network: string;
85
+ checkpointSequenceNumber: bigint;
86
+ }
87
+
88
+ export interface SuiGetCheckpointTimeResponse {
89
+ checkpointTimestampMs?: bigint | undefined;
90
+ transactionMinTimestampMs?: bigint | undefined;
91
+ transactionMaxTimestampMs?: bigint | undefined;
92
+ }
93
+
83
94
  export interface RemoteResultRequest {
84
95
  token: string;
85
96
  position: number;
@@ -1049,6 +1060,153 @@ export const EvmQueryResponse = {
1049
1060
  },
1050
1061
  };
1051
1062
 
1063
+ function createBaseSuiGetCheckpointTimeRequest(): SuiGetCheckpointTimeRequest {
1064
+ return { network: "", checkpointSequenceNumber: BigInt("0") };
1065
+ }
1066
+
1067
+ export const SuiGetCheckpointTimeRequest = {
1068
+ encode(message: SuiGetCheckpointTimeRequest, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
1069
+ if (message.network !== "") {
1070
+ writer.uint32(10).string(message.network);
1071
+ }
1072
+ if (message.checkpointSequenceNumber !== BigInt("0")) {
1073
+ writer.uint32(16).uint64(message.checkpointSequenceNumber.toString());
1074
+ }
1075
+ return writer;
1076
+ },
1077
+
1078
+ decode(input: _m0.Reader | Uint8Array, length?: number): SuiGetCheckpointTimeRequest {
1079
+ const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
1080
+ let end = length === undefined ? reader.len : reader.pos + length;
1081
+ const message = createBaseSuiGetCheckpointTimeRequest();
1082
+ while (reader.pos < end) {
1083
+ const tag = reader.uint32();
1084
+ switch (tag >>> 3) {
1085
+ case 1:
1086
+ message.network = reader.string();
1087
+ break;
1088
+ case 2:
1089
+ message.checkpointSequenceNumber = longToBigint(reader.uint64() as Long);
1090
+ break;
1091
+ default:
1092
+ reader.skipType(tag & 7);
1093
+ break;
1094
+ }
1095
+ }
1096
+ return message;
1097
+ },
1098
+
1099
+ fromJSON(object: any): SuiGetCheckpointTimeRequest {
1100
+ return {
1101
+ network: isSet(object.network) ? String(object.network) : "",
1102
+ checkpointSequenceNumber: isSet(object.checkpointSequenceNumber)
1103
+ ? BigInt(object.checkpointSequenceNumber)
1104
+ : BigInt("0"),
1105
+ };
1106
+ },
1107
+
1108
+ toJSON(message: SuiGetCheckpointTimeRequest): unknown {
1109
+ const obj: any = {};
1110
+ message.network !== undefined && (obj.network = message.network);
1111
+ message.checkpointSequenceNumber !== undefined &&
1112
+ (obj.checkpointSequenceNumber = message.checkpointSequenceNumber.toString());
1113
+ return obj;
1114
+ },
1115
+
1116
+ create(base?: DeepPartial<SuiGetCheckpointTimeRequest>): SuiGetCheckpointTimeRequest {
1117
+ return SuiGetCheckpointTimeRequest.fromPartial(base ?? {});
1118
+ },
1119
+
1120
+ fromPartial(object: DeepPartial<SuiGetCheckpointTimeRequest>): SuiGetCheckpointTimeRequest {
1121
+ const message = createBaseSuiGetCheckpointTimeRequest();
1122
+ message.network = object.network ?? "";
1123
+ message.checkpointSequenceNumber = object.checkpointSequenceNumber ?? BigInt("0");
1124
+ return message;
1125
+ },
1126
+ };
1127
+
1128
+ function createBaseSuiGetCheckpointTimeResponse(): SuiGetCheckpointTimeResponse {
1129
+ return {
1130
+ checkpointTimestampMs: undefined,
1131
+ transactionMinTimestampMs: undefined,
1132
+ transactionMaxTimestampMs: undefined,
1133
+ };
1134
+ }
1135
+
1136
+ export const SuiGetCheckpointTimeResponse = {
1137
+ encode(message: SuiGetCheckpointTimeResponse, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
1138
+ if (message.checkpointTimestampMs !== undefined) {
1139
+ writer.uint32(8).uint64(message.checkpointTimestampMs.toString());
1140
+ }
1141
+ if (message.transactionMinTimestampMs !== undefined) {
1142
+ writer.uint32(16).uint64(message.transactionMinTimestampMs.toString());
1143
+ }
1144
+ if (message.transactionMaxTimestampMs !== undefined) {
1145
+ writer.uint32(24).uint64(message.transactionMaxTimestampMs.toString());
1146
+ }
1147
+ return writer;
1148
+ },
1149
+
1150
+ decode(input: _m0.Reader | Uint8Array, length?: number): SuiGetCheckpointTimeResponse {
1151
+ const reader = input instanceof _m0.Reader ? input : new _m0.Reader(input);
1152
+ let end = length === undefined ? reader.len : reader.pos + length;
1153
+ const message = createBaseSuiGetCheckpointTimeResponse();
1154
+ while (reader.pos < end) {
1155
+ const tag = reader.uint32();
1156
+ switch (tag >>> 3) {
1157
+ case 1:
1158
+ message.checkpointTimestampMs = longToBigint(reader.uint64() as Long);
1159
+ break;
1160
+ case 2:
1161
+ message.transactionMinTimestampMs = longToBigint(reader.uint64() as Long);
1162
+ break;
1163
+ case 3:
1164
+ message.transactionMaxTimestampMs = longToBigint(reader.uint64() as Long);
1165
+ break;
1166
+ default:
1167
+ reader.skipType(tag & 7);
1168
+ break;
1169
+ }
1170
+ }
1171
+ return message;
1172
+ },
1173
+
1174
+ fromJSON(object: any): SuiGetCheckpointTimeResponse {
1175
+ return {
1176
+ checkpointTimestampMs: isSet(object.checkpointTimestampMs) ? BigInt(object.checkpointTimestampMs) : undefined,
1177
+ transactionMinTimestampMs: isSet(object.transactionMinTimestampMs)
1178
+ ? BigInt(object.transactionMinTimestampMs)
1179
+ : undefined,
1180
+ transactionMaxTimestampMs: isSet(object.transactionMaxTimestampMs)
1181
+ ? BigInt(object.transactionMaxTimestampMs)
1182
+ : undefined,
1183
+ };
1184
+ },
1185
+
1186
+ toJSON(message: SuiGetCheckpointTimeResponse): unknown {
1187
+ const obj: any = {};
1188
+ message.checkpointTimestampMs !== undefined &&
1189
+ (obj.checkpointTimestampMs = message.checkpointTimestampMs.toString());
1190
+ message.transactionMinTimestampMs !== undefined &&
1191
+ (obj.transactionMinTimestampMs = message.transactionMinTimestampMs.toString());
1192
+ message.transactionMaxTimestampMs !== undefined &&
1193
+ (obj.transactionMaxTimestampMs = message.transactionMaxTimestampMs.toString());
1194
+ return obj;
1195
+ },
1196
+
1197
+ create(base?: DeepPartial<SuiGetCheckpointTimeResponse>): SuiGetCheckpointTimeResponse {
1198
+ return SuiGetCheckpointTimeResponse.fromPartial(base ?? {});
1199
+ },
1200
+
1201
+ fromPartial(object: DeepPartial<SuiGetCheckpointTimeResponse>): SuiGetCheckpointTimeResponse {
1202
+ const message = createBaseSuiGetCheckpointTimeResponse();
1203
+ message.checkpointTimestampMs = object.checkpointTimestampMs ?? undefined;
1204
+ message.transactionMinTimestampMs = object.transactionMinTimestampMs ?? undefined;
1205
+ message.transactionMaxTimestampMs = object.transactionMaxTimestampMs ?? undefined;
1206
+ return message;
1207
+ },
1208
+ };
1209
+
1052
1210
  function createBaseRemoteResultRequest(): RemoteResultRequest {
1053
1211
  return { token: "", position: 0, keepAlive: false };
1054
1212
  }
@@ -1373,6 +1531,14 @@ export const SuiQueryDefinition = {
1373
1531
  responseStream: true,
1374
1532
  options: {},
1375
1533
  },
1534
+ getCheckpointTime: {
1535
+ name: "GetCheckpointTime",
1536
+ requestType: SuiGetCheckpointTimeRequest,
1537
+ requestStream: false,
1538
+ responseType: SuiGetCheckpointTimeResponse,
1539
+ responseStream: false,
1540
+ options: {},
1541
+ },
1376
1542
  },
1377
1543
  } as const;
1378
1544
 
@@ -1381,6 +1547,10 @@ export interface SuiQueryServiceImplementation<CallContextExt = {}> {
1381
1547
  request: EvmSQLQueryRequest,
1382
1548
  context: CallContext & CallContextExt,
1383
1549
  ): ServerStreamingMethodResult<DeepPartial<EvmQueryResponse>>;
1550
+ getCheckpointTime(
1551
+ request: SuiGetCheckpointTimeRequest,
1552
+ context: CallContext & CallContextExt,
1553
+ ): Promise<DeepPartial<SuiGetCheckpointTimeResponse>>;
1384
1554
  }
1385
1555
 
1386
1556
  export interface SuiQueryClient<CallOptionsExt = {}> {
@@ -1388,6 +1558,10 @@ export interface SuiQueryClient<CallOptionsExt = {}> {
1388
1558
  request: DeepPartial<EvmSQLQueryRequest>,
1389
1559
  options?: CallOptions & CallOptionsExt,
1390
1560
  ): AsyncIterable<EvmQueryResponse>;
1561
+ getCheckpointTime(
1562
+ request: DeepPartial<SuiGetCheckpointTimeRequest>,
1563
+ options?: CallOptions & CallOptionsExt,
1564
+ ): Promise<SuiGetCheckpointTimeResponse>;
1391
1565
  }
1392
1566
 
1393
1567
  export type RemoteResultTransferServiceDefinition = typeof RemoteResultTransferServiceDefinition;
@@ -547,10 +547,14 @@ export interface Data_AptResource {
547
547
 
548
548
  export interface Data_SuiEvent {
549
549
  transaction: { [key: string]: any } | undefined;
550
+ timestamp: Date | undefined;
551
+ slot: bigint;
550
552
  }
551
553
 
552
554
  export interface Data_SuiCall {
553
555
  transaction: { [key: string]: any } | undefined;
556
+ timestamp: Date | undefined;
557
+ slot: bigint;
554
558
  }
555
559
 
556
560
  export interface DataBinding {
@@ -3951,7 +3955,7 @@ export const Data_AptResource = {
3951
3955
  };
3952
3956
 
3953
3957
  function createBaseData_SuiEvent(): Data_SuiEvent {
3954
- return { transaction: undefined };
3958
+ return { transaction: undefined, timestamp: undefined, slot: BigInt("0") };
3955
3959
  }
3956
3960
 
3957
3961
  export const Data_SuiEvent = {
@@ -3959,6 +3963,12 @@ export const Data_SuiEvent = {
3959
3963
  if (message.transaction !== undefined) {
3960
3964
  Struct.encode(Struct.wrap(message.transaction), writer.uint32(10).fork()).ldelim();
3961
3965
  }
3966
+ if (message.timestamp !== undefined) {
3967
+ Timestamp.encode(toTimestamp(message.timestamp), writer.uint32(18).fork()).ldelim();
3968
+ }
3969
+ if (message.slot !== BigInt("0")) {
3970
+ writer.uint32(24).uint64(message.slot.toString());
3971
+ }
3962
3972
  return writer;
3963
3973
  },
3964
3974
 
@@ -3972,6 +3982,12 @@ export const Data_SuiEvent = {
3972
3982
  case 1:
3973
3983
  message.transaction = Struct.unwrap(Struct.decode(reader, reader.uint32()));
3974
3984
  break;
3985
+ case 2:
3986
+ message.timestamp = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
3987
+ break;
3988
+ case 3:
3989
+ message.slot = longToBigint(reader.uint64() as Long);
3990
+ break;
3975
3991
  default:
3976
3992
  reader.skipType(tag & 7);
3977
3993
  break;
@@ -3981,12 +3997,18 @@ export const Data_SuiEvent = {
3981
3997
  },
3982
3998
 
3983
3999
  fromJSON(object: any): Data_SuiEvent {
3984
- return { transaction: isObject(object.transaction) ? object.transaction : undefined };
4000
+ return {
4001
+ transaction: isObject(object.transaction) ? object.transaction : undefined,
4002
+ timestamp: isSet(object.timestamp) ? fromJsonTimestamp(object.timestamp) : undefined,
4003
+ slot: isSet(object.slot) ? BigInt(object.slot) : BigInt("0"),
4004
+ };
3985
4005
  },
3986
4006
 
3987
4007
  toJSON(message: Data_SuiEvent): unknown {
3988
4008
  const obj: any = {};
3989
4009
  message.transaction !== undefined && (obj.transaction = message.transaction);
4010
+ message.timestamp !== undefined && (obj.timestamp = message.timestamp.toISOString());
4011
+ message.slot !== undefined && (obj.slot = message.slot.toString());
3990
4012
  return obj;
3991
4013
  },
3992
4014
 
@@ -3997,12 +4019,14 @@ export const Data_SuiEvent = {
3997
4019
  fromPartial(object: DeepPartial<Data_SuiEvent>): Data_SuiEvent {
3998
4020
  const message = createBaseData_SuiEvent();
3999
4021
  message.transaction = object.transaction ?? undefined;
4022
+ message.timestamp = object.timestamp ?? undefined;
4023
+ message.slot = object.slot ?? BigInt("0");
4000
4024
  return message;
4001
4025
  },
4002
4026
  };
4003
4027
 
4004
4028
  function createBaseData_SuiCall(): Data_SuiCall {
4005
- return { transaction: undefined };
4029
+ return { transaction: undefined, timestamp: undefined, slot: BigInt("0") };
4006
4030
  }
4007
4031
 
4008
4032
  export const Data_SuiCall = {
@@ -4010,6 +4034,12 @@ export const Data_SuiCall = {
4010
4034
  if (message.transaction !== undefined) {
4011
4035
  Struct.encode(Struct.wrap(message.transaction), writer.uint32(10).fork()).ldelim();
4012
4036
  }
4037
+ if (message.timestamp !== undefined) {
4038
+ Timestamp.encode(toTimestamp(message.timestamp), writer.uint32(18).fork()).ldelim();
4039
+ }
4040
+ if (message.slot !== BigInt("0")) {
4041
+ writer.uint32(24).uint64(message.slot.toString());
4042
+ }
4013
4043
  return writer;
4014
4044
  },
4015
4045
 
@@ -4023,6 +4053,12 @@ export const Data_SuiCall = {
4023
4053
  case 1:
4024
4054
  message.transaction = Struct.unwrap(Struct.decode(reader, reader.uint32()));
4025
4055
  break;
4056
+ case 2:
4057
+ message.timestamp = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
4058
+ break;
4059
+ case 3:
4060
+ message.slot = longToBigint(reader.uint64() as Long);
4061
+ break;
4026
4062
  default:
4027
4063
  reader.skipType(tag & 7);
4028
4064
  break;
@@ -4032,12 +4068,18 @@ export const Data_SuiCall = {
4032
4068
  },
4033
4069
 
4034
4070
  fromJSON(object: any): Data_SuiCall {
4035
- return { transaction: isObject(object.transaction) ? object.transaction : undefined };
4071
+ return {
4072
+ transaction: isObject(object.transaction) ? object.transaction : undefined,
4073
+ timestamp: isSet(object.timestamp) ? fromJsonTimestamp(object.timestamp) : undefined,
4074
+ slot: isSet(object.slot) ? BigInt(object.slot) : BigInt("0"),
4075
+ };
4036
4076
  },
4037
4077
 
4038
4078
  toJSON(message: Data_SuiCall): unknown {
4039
4079
  const obj: any = {};
4040
4080
  message.transaction !== undefined && (obj.transaction = message.transaction);
4081
+ message.timestamp !== undefined && (obj.timestamp = message.timestamp.toISOString());
4082
+ message.slot !== undefined && (obj.slot = message.slot.toString());
4041
4083
  return obj;
4042
4084
  },
4043
4085
 
@@ -4048,6 +4090,8 @@ export const Data_SuiCall = {
4048
4090
  fromPartial(object: DeepPartial<Data_SuiCall>): Data_SuiCall {
4049
4091
  const message = createBaseData_SuiCall();
4050
4092
  message.transaction = object.transaction ?? undefined;
4093
+ message.timestamp = object.timestamp ?? undefined;
4094
+ message.slot = object.slot ?? BigInt("0");
4051
4095
  return message;
4052
4096
  },
4053
4097
  };