@dashevo/dapi-grpc 1.8.0-rc.2 → 2.0.0-dev.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/.eslintrc +3 -0
- package/Cargo.toml +25 -14
- package/build.rs +80 -20
- package/clients/platform/v0/nodejs/platform_pbjs.js +21836 -132
- package/clients/platform/v0/nodejs/platform_protoc.js +38698 -17593
- package/clients/platform/v0/web/platform_pb.d.ts +2865 -99
- package/clients/platform/v0/web/platform_pb.js +38698 -17593
- package/clients/platform/v0/web/platform_pb_service.d.ts +209 -0
- package/clients/platform/v0/web/platform_pb_service.js +440 -0
- package/package.json +3 -3
- package/protos/platform/v0/platform.proto +588 -37
- package/src/lib.rs +19 -10
|
@@ -55,6 +55,17 @@ service Platform {
|
|
|
55
55
|
rpc getPathElements(GetPathElementsRequest) returns (GetPathElementsResponse);
|
|
56
56
|
rpc getStatus(GetStatusRequest) returns (GetStatusResponse);
|
|
57
57
|
rpc getCurrentQuorumsInfo(GetCurrentQuorumsInfoRequest) returns (GetCurrentQuorumsInfoResponse);
|
|
58
|
+
rpc getIdentityTokenBalances(GetIdentityTokenBalancesRequest) returns (GetIdentityTokenBalancesResponse);
|
|
59
|
+
rpc getIdentitiesTokenBalances(GetIdentitiesTokenBalancesRequest) returns (GetIdentitiesTokenBalancesResponse);
|
|
60
|
+
rpc getIdentityTokenInfos(GetIdentityTokenInfosRequest) returns (GetIdentityTokenInfosResponse);
|
|
61
|
+
rpc getIdentitiesTokenInfos(GetIdentitiesTokenInfosRequest) returns (GetIdentitiesTokenInfosResponse);
|
|
62
|
+
rpc getTokenStatuses(GetTokenStatusesRequest) returns (GetTokenStatusesResponse);
|
|
63
|
+
rpc getTokenPreProgrammedDistributions(GetTokenPreProgrammedDistributionsRequest) returns (GetTokenPreProgrammedDistributionsResponse);
|
|
64
|
+
rpc getTokenTotalSupply(GetTokenTotalSupplyRequest) returns (GetTokenTotalSupplyResponse);
|
|
65
|
+
rpc getGroupInfo(GetGroupInfoRequest) returns (GetGroupInfoResponse);
|
|
66
|
+
rpc getGroupInfos(GetGroupInfosRequest) returns (GetGroupInfosResponse);
|
|
67
|
+
rpc getGroupActions(GetGroupActionsRequest) returns (GetGroupActionsResponse);
|
|
68
|
+
rpc getGroupActionSigners(GetGroupActionSignersRequest) returns (GetGroupActionSignersResponse);
|
|
58
69
|
}
|
|
59
70
|
|
|
60
71
|
// Proof message includes cryptographic proofs for validating responses
|
|
@@ -69,12 +80,12 @@ message Proof {
|
|
|
69
80
|
|
|
70
81
|
// ResponseMetadata provides metadata about the blockchain state at the time of response
|
|
71
82
|
message ResponseMetadata {
|
|
72
|
-
uint64 height = 1;
|
|
73
|
-
uint32 core_chain_locked_height = 2;
|
|
74
|
-
uint32 epoch = 3;
|
|
75
|
-
uint64 time_ms = 4;
|
|
76
|
-
uint32 protocol_version = 5;
|
|
77
|
-
string chain_id = 6;
|
|
83
|
+
uint64 height = 1 [jstype = JS_STRING]; // Current blockchain height
|
|
84
|
+
uint32 core_chain_locked_height = 2; // Latest known core height in consensus
|
|
85
|
+
uint32 epoch = 3; // Current epoch number
|
|
86
|
+
uint64 time_ms = 4 [jstype = JS_STRING]; // Timestamp in milliseconds
|
|
87
|
+
uint32 protocol_version = 5; // Protocol version
|
|
88
|
+
string chain_id = 6; // Identifier of the blockchain
|
|
78
89
|
}
|
|
79
90
|
|
|
80
91
|
message StateTransitionBroadcastError {
|
|
@@ -164,7 +175,7 @@ message GetIdentityNonceResponse {
|
|
|
164
175
|
|
|
165
176
|
message GetIdentityNonceResponseV0 {
|
|
166
177
|
oneof result {
|
|
167
|
-
uint64 identity_nonce = 1;
|
|
178
|
+
uint64 identity_nonce = 1 [jstype = JS_STRING];
|
|
168
179
|
Proof proof = 2;
|
|
169
180
|
}
|
|
170
181
|
ResponseMetadata metadata = 3;
|
|
@@ -177,7 +188,7 @@ message GetIdentityContractNonceResponse {
|
|
|
177
188
|
|
|
178
189
|
message GetIdentityContractNonceResponseV0 {
|
|
179
190
|
oneof result {
|
|
180
|
-
uint64 identity_contract_nonce = 1;
|
|
191
|
+
uint64 identity_contract_nonce = 1 [jstype = JS_STRING];
|
|
181
192
|
Proof proof = 2;
|
|
182
193
|
}
|
|
183
194
|
ResponseMetadata metadata = 3;
|
|
@@ -190,7 +201,7 @@ message GetIdentityBalanceResponse {
|
|
|
190
201
|
|
|
191
202
|
message GetIdentityBalanceResponseV0 {
|
|
192
203
|
oneof result {
|
|
193
|
-
uint64 balance = 1; // The balance of the requested identity
|
|
204
|
+
uint64 balance = 1 [jstype = JS_STRING]; // The balance of the requested identity
|
|
194
205
|
Proof proof = 2; // Proof of the balance, if requested
|
|
195
206
|
}
|
|
196
207
|
ResponseMetadata metadata = 3; // Metadata about the blockchain state
|
|
@@ -203,8 +214,8 @@ message GetIdentityBalanceAndRevisionResponse {
|
|
|
203
214
|
|
|
204
215
|
message GetIdentityBalanceAndRevisionResponseV0 {
|
|
205
216
|
message BalanceAndRevision {
|
|
206
|
-
uint64 balance = 1; // Balance of the identity
|
|
207
|
-
uint64 revision = 2; // Revision number of the identity
|
|
217
|
+
uint64 balance = 1 [jstype = JS_STRING]; // Balance of the identity
|
|
218
|
+
uint64 revision = 2 [jstype = JS_STRING]; // Revision number of the identity
|
|
208
219
|
}
|
|
209
220
|
|
|
210
221
|
oneof result {
|
|
@@ -330,7 +341,7 @@ message GetEvonodesProposedEpochBlocksResponse {
|
|
|
330
341
|
message GetEvonodesProposedEpochBlocksResponseV0 {
|
|
331
342
|
message EvonodeProposedBlocks {
|
|
332
343
|
bytes pro_tx_hash = 1;
|
|
333
|
-
uint64 count = 2;
|
|
344
|
+
uint64 count = 2 [jstype = JS_STRING];
|
|
334
345
|
}
|
|
335
346
|
|
|
336
347
|
message EvonodesProposedBlocks {
|
|
@@ -376,7 +387,7 @@ message GetIdentitiesBalancesResponse {
|
|
|
376
387
|
message GetIdentitiesBalancesResponseV0 {
|
|
377
388
|
message IdentityBalance {
|
|
378
389
|
bytes identity_id = 1;
|
|
379
|
-
optional uint64 balance = 2;
|
|
390
|
+
optional uint64 balance = 2 [jstype = JS_STRING];
|
|
380
391
|
}
|
|
381
392
|
|
|
382
393
|
message IdentitiesBalances {
|
|
@@ -436,10 +447,27 @@ message GetProofsRequest {
|
|
|
436
447
|
oneof request_type { ContestedResourceVoteStatusRequest contested_resource_vote_status_request = 1; }
|
|
437
448
|
}
|
|
438
449
|
|
|
450
|
+
message IdentityTokenBalanceRequest {
|
|
451
|
+
bytes token_id = 1;
|
|
452
|
+
bytes identity_id = 2;
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
message IdentityTokenInfoRequest {
|
|
456
|
+
bytes token_id = 1;
|
|
457
|
+
bytes identity_id = 2;
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
message TokenStatusRequest {
|
|
461
|
+
bytes token_id = 1;
|
|
462
|
+
}
|
|
463
|
+
|
|
439
464
|
repeated IdentityRequest identities = 1; // List of identity requests
|
|
440
465
|
repeated ContractRequest contracts = 2; // List of contract requests
|
|
441
466
|
repeated DocumentRequest documents = 3; // List of document requests
|
|
442
467
|
repeated VoteStatusRequest votes = 4;
|
|
468
|
+
repeated IdentityTokenBalanceRequest identity_token_balances = 5;
|
|
469
|
+
repeated IdentityTokenInfoRequest identity_token_infos = 6;
|
|
470
|
+
repeated TokenStatusRequest token_statuses = 7;
|
|
443
471
|
}
|
|
444
472
|
|
|
445
473
|
oneof version { GetProofsRequestV0 v0 = 1; }
|
|
@@ -509,7 +537,7 @@ message GetDataContractHistoryRequest {
|
|
|
509
537
|
bytes id = 1; // The unique ID of the data contract
|
|
510
538
|
google.protobuf.UInt32Value limit = 2; // The maximum number of history entries to return
|
|
511
539
|
google.protobuf.UInt32Value offset = 3; // The offset for pagination through the contract history
|
|
512
|
-
uint64 start_at_ms = 4; // Only return results starting at this time in milliseconds
|
|
540
|
+
uint64 start_at_ms = 4 [jstype = JS_STRING]; // Only return results starting at this time in milliseconds
|
|
513
541
|
bool prove = 5; // Flag to request a proof as the response
|
|
514
542
|
}
|
|
515
543
|
oneof version { GetDataContractHistoryRequestV0 v0 = 1; }
|
|
@@ -519,7 +547,7 @@ message GetDataContractHistoryResponse {
|
|
|
519
547
|
message GetDataContractHistoryResponseV0 {
|
|
520
548
|
// Represents a single entry in the data contract's history
|
|
521
549
|
message DataContractHistoryEntry {
|
|
522
|
-
uint64 date = 1; // The date of the history entry
|
|
550
|
+
uint64 date = 1 [jstype = JS_STRING]; // The date of the history entry
|
|
523
551
|
bytes value = 2; // The value of the data contract at this point in history
|
|
524
552
|
}
|
|
525
553
|
|
|
@@ -735,9 +763,9 @@ message GetEpochsInfoResponse {
|
|
|
735
763
|
// EpochInfo represents information about a single epoch
|
|
736
764
|
message EpochInfo {
|
|
737
765
|
uint32 number = 1; // The number of the epoch
|
|
738
|
-
uint64 first_block_height = 2; // The height of the first block in this epoch
|
|
766
|
+
uint64 first_block_height = 2 [jstype = JS_STRING]; // The height of the first block in this epoch
|
|
739
767
|
uint32 first_core_block_height = 3; // The height of the first Core block in this epoch
|
|
740
|
-
uint64 start_time = 4; // The start time of the epoch
|
|
768
|
+
uint64 start_time = 4 [jstype = JS_STRING]; // The start time of the epoch
|
|
741
769
|
double fee_multiplier = 5; // The fee multiplier applicable in this epoch
|
|
742
770
|
uint32 protocol_version = 6;
|
|
743
771
|
}
|
|
@@ -798,11 +826,11 @@ message GetContestedResourcesResponse {
|
|
|
798
826
|
message GetVotePollsByEndDateRequest {
|
|
799
827
|
message GetVotePollsByEndDateRequestV0 {
|
|
800
828
|
message StartAtTimeInfo {
|
|
801
|
-
uint64 start_time_ms = 1;
|
|
829
|
+
uint64 start_time_ms = 1 [jstype = JS_STRING];
|
|
802
830
|
bool start_time_included = 2;
|
|
803
831
|
}
|
|
804
832
|
message EndAtTimeInfo {
|
|
805
|
-
uint64 end_time_ms = 1;
|
|
833
|
+
uint64 end_time_ms = 1 [jstype = JS_STRING];
|
|
806
834
|
bool end_time_included = 2;
|
|
807
835
|
}
|
|
808
836
|
optional StartAtTimeInfo start_time_info = 1;
|
|
@@ -821,7 +849,7 @@ message GetVotePollsByEndDateRequest {
|
|
|
821
849
|
message GetVotePollsByEndDateResponse {
|
|
822
850
|
message GetVotePollsByEndDateResponseV0 {
|
|
823
851
|
message SerializedVotePollsByTimestamp {
|
|
824
|
-
uint64 timestamp = 1;
|
|
852
|
+
uint64 timestamp = 1 [jstype = JS_STRING];
|
|
825
853
|
repeated bytes serialized_vote_polls = 2;
|
|
826
854
|
}
|
|
827
855
|
|
|
@@ -881,9 +909,9 @@ message GetContestedResourceVoteStateResponse {
|
|
|
881
909
|
}
|
|
882
910
|
FinishedVoteOutcome finished_vote_outcome = 1;
|
|
883
911
|
optional bytes won_by_identity_id = 2; // Only used when vote_choice_type is TOWARDS_IDENTITY
|
|
884
|
-
uint64 finished_at_block_height = 3;
|
|
912
|
+
uint64 finished_at_block_height = 3 [jstype = JS_STRING];
|
|
885
913
|
uint32 finished_at_core_block_height = 4;
|
|
886
|
-
uint64 finished_at_block_time_ms = 5;
|
|
914
|
+
uint64 finished_at_block_time_ms = 5 [jstype = JS_STRING];
|
|
887
915
|
uint32 finished_at_epoch = 6;
|
|
888
916
|
}
|
|
889
917
|
|
|
@@ -1024,7 +1052,7 @@ message GetPrefundedSpecializedBalanceResponse {
|
|
|
1024
1052
|
|
|
1025
1053
|
message GetPrefundedSpecializedBalanceResponseV0 {
|
|
1026
1054
|
oneof result {
|
|
1027
|
-
uint64 balance = 1;
|
|
1055
|
+
uint64 balance = 1 [jstype = JS_STRING];
|
|
1028
1056
|
Proof proof = 2;
|
|
1029
1057
|
}
|
|
1030
1058
|
ResponseMetadata metadata = 3;
|
|
@@ -1046,7 +1074,7 @@ message GetTotalCreditsInPlatformRequest {
|
|
|
1046
1074
|
message GetTotalCreditsInPlatformResponse {
|
|
1047
1075
|
message GetTotalCreditsInPlatformResponseV0 {
|
|
1048
1076
|
oneof result {
|
|
1049
|
-
uint64 credits = 1;
|
|
1077
|
+
uint64 credits = 1 [jstype = JS_STRING];
|
|
1050
1078
|
|
|
1051
1079
|
Proof proof = 2;
|
|
1052
1080
|
}
|
|
@@ -1128,11 +1156,11 @@ message GetStatusResponse {
|
|
|
1128
1156
|
}
|
|
1129
1157
|
|
|
1130
1158
|
message Time {
|
|
1131
|
-
uint64 local = 1;
|
|
1159
|
+
uint64 local = 1 [jstype = JS_STRING];
|
|
1132
1160
|
// It will be missing if Drive is not responding
|
|
1133
|
-
optional uint64 block = 2;
|
|
1161
|
+
optional uint64 block = 2 [jstype = JS_STRING];
|
|
1134
1162
|
// It will be missing if Drive is not responding
|
|
1135
|
-
optional uint64 genesis = 3;
|
|
1163
|
+
optional uint64 genesis = 3 [jstype = JS_STRING];
|
|
1136
1164
|
// It will be missing if Drive is not responding
|
|
1137
1165
|
optional uint32 epoch = 4;
|
|
1138
1166
|
}
|
|
@@ -1148,11 +1176,11 @@ message GetStatusResponse {
|
|
|
1148
1176
|
bool catching_up = 1;
|
|
1149
1177
|
bytes latest_block_hash = 2;
|
|
1150
1178
|
bytes latest_app_hash = 3;
|
|
1151
|
-
uint64 latest_block_height = 4;
|
|
1179
|
+
uint64 latest_block_height = 4 [jstype = JS_STRING];
|
|
1152
1180
|
bytes earliest_block_hash = 5;
|
|
1153
1181
|
bytes earliest_app_hash = 6;
|
|
1154
|
-
uint64 earliest_block_height = 7;
|
|
1155
|
-
uint64 max_peer_block_height = 9;
|
|
1182
|
+
uint64 earliest_block_height = 7 [jstype = JS_STRING];
|
|
1183
|
+
uint64 max_peer_block_height = 9 [jstype = JS_STRING];
|
|
1156
1184
|
// Latest known core height in consensus.
|
|
1157
1185
|
// It will be missing if Drive is not responding
|
|
1158
1186
|
optional uint32 core_chain_locked_height = 10;
|
|
@@ -1165,14 +1193,14 @@ message GetStatusResponse {
|
|
|
1165
1193
|
}
|
|
1166
1194
|
|
|
1167
1195
|
message StateSync {
|
|
1168
|
-
uint64 total_synced_time = 1;
|
|
1169
|
-
uint64 remaining_time = 2;
|
|
1196
|
+
uint64 total_synced_time = 1 [jstype = JS_STRING];
|
|
1197
|
+
uint64 remaining_time = 2 [jstype = JS_STRING];
|
|
1170
1198
|
uint32 total_snapshots = 3;
|
|
1171
|
-
uint64 chunk_process_avg_time = 4;
|
|
1172
|
-
uint64 snapshot_height = 5;
|
|
1173
|
-
uint64 snapshot_chunks_count = 6;
|
|
1174
|
-
uint64 backfilled_blocks = 7;
|
|
1175
|
-
uint64 backfill_blocks_total = 8;
|
|
1199
|
+
uint64 chunk_process_avg_time = 4 [jstype = JS_STRING];
|
|
1200
|
+
uint64 snapshot_height = 5 [jstype = JS_STRING];
|
|
1201
|
+
uint64 snapshot_chunks_count = 6 [jstype = JS_STRING];
|
|
1202
|
+
uint64 backfilled_blocks = 7 [jstype = JS_STRING];
|
|
1203
|
+
uint64 backfill_blocks_total = 8 [jstype = JS_STRING];
|
|
1176
1204
|
}
|
|
1177
1205
|
|
|
1178
1206
|
Version version = 1;
|
|
@@ -1215,3 +1243,526 @@ message GetCurrentQuorumsInfoResponse {
|
|
|
1215
1243
|
}
|
|
1216
1244
|
oneof version { GetCurrentQuorumsInfoResponseV0 v0 = 1; }
|
|
1217
1245
|
}
|
|
1246
|
+
|
|
1247
|
+
message GetIdentityTokenBalancesRequest {
|
|
1248
|
+
message GetIdentityTokenBalancesRequestV0 {
|
|
1249
|
+
bytes identity_id = 1; // ID of the identity
|
|
1250
|
+
repeated bytes token_ids = 2; // List of token IDs
|
|
1251
|
+
bool prove = 3; // Flag to request a proof as the response
|
|
1252
|
+
}
|
|
1253
|
+
oneof version {
|
|
1254
|
+
GetIdentityTokenBalancesRequestV0 v0 = 1;
|
|
1255
|
+
}
|
|
1256
|
+
}
|
|
1257
|
+
|
|
1258
|
+
message GetIdentityTokenBalancesResponse {
|
|
1259
|
+
message GetIdentityTokenBalancesResponseV0 {
|
|
1260
|
+
message TokenBalanceEntry {
|
|
1261
|
+
bytes token_id = 1; // Token ID
|
|
1262
|
+
optional uint64 balance = 2; // Token balance for the contract
|
|
1263
|
+
}
|
|
1264
|
+
|
|
1265
|
+
message TokenBalances {
|
|
1266
|
+
repeated TokenBalanceEntry token_balances = 1; // List of token balances
|
|
1267
|
+
}
|
|
1268
|
+
|
|
1269
|
+
oneof result {
|
|
1270
|
+
TokenBalances token_balances = 1; // Actual token balances
|
|
1271
|
+
Proof proof = 2; // Proof of the token balances, if requested
|
|
1272
|
+
}
|
|
1273
|
+
ResponseMetadata metadata = 3; // Metadata about the blockchain state
|
|
1274
|
+
}
|
|
1275
|
+
oneof version {
|
|
1276
|
+
GetIdentityTokenBalancesResponseV0 v0 = 1;
|
|
1277
|
+
}
|
|
1278
|
+
}
|
|
1279
|
+
|
|
1280
|
+
message GetIdentitiesTokenBalancesRequest {
|
|
1281
|
+
message GetIdentitiesTokenBalancesRequestV0 {
|
|
1282
|
+
bytes token_id = 1; // Token ID
|
|
1283
|
+
repeated bytes identity_ids = 2; // List of identity IDs
|
|
1284
|
+
bool prove = 3; // Flag to request a proof as the response
|
|
1285
|
+
}
|
|
1286
|
+
oneof version {
|
|
1287
|
+
GetIdentitiesTokenBalancesRequestV0 v0 = 1;
|
|
1288
|
+
}
|
|
1289
|
+
}
|
|
1290
|
+
|
|
1291
|
+
message GetIdentitiesTokenBalancesResponse {
|
|
1292
|
+
message GetIdentitiesTokenBalancesResponseV0 {
|
|
1293
|
+
message IdentityTokenBalanceEntry {
|
|
1294
|
+
bytes identity_id = 1; // Identity ID
|
|
1295
|
+
optional uint64 balance = 2; // Token balance for the identity
|
|
1296
|
+
}
|
|
1297
|
+
|
|
1298
|
+
message IdentityTokenBalances {
|
|
1299
|
+
repeated IdentityTokenBalanceEntry identity_token_balances = 1; // List of identity token balances
|
|
1300
|
+
}
|
|
1301
|
+
|
|
1302
|
+
oneof result {
|
|
1303
|
+
IdentityTokenBalances identity_token_balances = 1; // Actual identity token balances
|
|
1304
|
+
Proof proof = 2; // Proof of the balances, if requested
|
|
1305
|
+
}
|
|
1306
|
+
ResponseMetadata metadata = 3; // Metadata about the blockchain state
|
|
1307
|
+
}
|
|
1308
|
+
oneof version {
|
|
1309
|
+
GetIdentitiesTokenBalancesResponseV0 v0 = 1;
|
|
1310
|
+
}
|
|
1311
|
+
}
|
|
1312
|
+
|
|
1313
|
+
|
|
1314
|
+
|
|
1315
|
+
message GetIdentityTokenInfosRequest {
|
|
1316
|
+
message GetIdentityTokenInfosRequestV0 {
|
|
1317
|
+
bytes identity_id = 1;
|
|
1318
|
+
repeated bytes token_ids = 2;
|
|
1319
|
+
bool prove = 3;
|
|
1320
|
+
}
|
|
1321
|
+
oneof version {
|
|
1322
|
+
GetIdentityTokenInfosRequestV0 v0 = 1;
|
|
1323
|
+
}
|
|
1324
|
+
}
|
|
1325
|
+
|
|
1326
|
+
message GetIdentityTokenInfosResponse {
|
|
1327
|
+
message GetIdentityTokenInfosResponseV0 {
|
|
1328
|
+
message TokenIdentityInfoEntry {
|
|
1329
|
+
bool frozen = 1;
|
|
1330
|
+
}
|
|
1331
|
+
|
|
1332
|
+
message TokenInfoEntry {
|
|
1333
|
+
bytes token_id = 1;
|
|
1334
|
+
optional TokenIdentityInfoEntry info = 2;
|
|
1335
|
+
}
|
|
1336
|
+
|
|
1337
|
+
message TokenInfos {
|
|
1338
|
+
repeated TokenInfoEntry token_infos = 1;
|
|
1339
|
+
}
|
|
1340
|
+
|
|
1341
|
+
oneof result {
|
|
1342
|
+
TokenInfos token_infos = 1;
|
|
1343
|
+
Proof proof = 2;
|
|
1344
|
+
}
|
|
1345
|
+
ResponseMetadata metadata = 3;
|
|
1346
|
+
}
|
|
1347
|
+
oneof version {
|
|
1348
|
+
GetIdentityTokenInfosResponseV0 v0 = 1;
|
|
1349
|
+
}
|
|
1350
|
+
}
|
|
1351
|
+
|
|
1352
|
+
message GetIdentitiesTokenInfosRequest {
|
|
1353
|
+
message GetIdentitiesTokenInfosRequestV0 {
|
|
1354
|
+
bytes token_id = 1;
|
|
1355
|
+
repeated bytes identity_ids = 2;
|
|
1356
|
+
bool prove = 3;
|
|
1357
|
+
}
|
|
1358
|
+
oneof version {
|
|
1359
|
+
GetIdentitiesTokenInfosRequestV0 v0 = 1;
|
|
1360
|
+
}
|
|
1361
|
+
}
|
|
1362
|
+
|
|
1363
|
+
message GetIdentitiesTokenInfosResponse {
|
|
1364
|
+
message GetIdentitiesTokenInfosResponseV0 {
|
|
1365
|
+
message TokenIdentityInfoEntry {
|
|
1366
|
+
bool frozen = 1;
|
|
1367
|
+
}
|
|
1368
|
+
|
|
1369
|
+
message TokenInfoEntry {
|
|
1370
|
+
bytes identity_id = 1;
|
|
1371
|
+
optional TokenIdentityInfoEntry info = 2;
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
message IdentityTokenInfos {
|
|
1375
|
+
repeated TokenInfoEntry token_infos = 1;
|
|
1376
|
+
}
|
|
1377
|
+
|
|
1378
|
+
oneof result {
|
|
1379
|
+
IdentityTokenInfos identity_token_infos = 1;
|
|
1380
|
+
Proof proof = 2;
|
|
1381
|
+
}
|
|
1382
|
+
ResponseMetadata metadata = 3;
|
|
1383
|
+
}
|
|
1384
|
+
oneof version {
|
|
1385
|
+
GetIdentitiesTokenInfosResponseV0 v0 = 1;
|
|
1386
|
+
}
|
|
1387
|
+
}
|
|
1388
|
+
|
|
1389
|
+
message GetTokenStatusesRequest {
|
|
1390
|
+
message GetTokenStatusesRequestV0 {
|
|
1391
|
+
repeated bytes token_ids = 1;
|
|
1392
|
+
bool prove = 2;
|
|
1393
|
+
}
|
|
1394
|
+
oneof version {
|
|
1395
|
+
GetTokenStatusesRequestV0 v0 = 1;
|
|
1396
|
+
}
|
|
1397
|
+
}
|
|
1398
|
+
|
|
1399
|
+
message GetTokenStatusesResponse {
|
|
1400
|
+
message GetTokenStatusesResponseV0 {
|
|
1401
|
+
message TokenStatusEntry {
|
|
1402
|
+
bytes token_id = 1;
|
|
1403
|
+
optional bool paused = 2;
|
|
1404
|
+
}
|
|
1405
|
+
|
|
1406
|
+
message TokenStatuses {
|
|
1407
|
+
repeated TokenStatusEntry token_statuses = 1;
|
|
1408
|
+
}
|
|
1409
|
+
|
|
1410
|
+
oneof result {
|
|
1411
|
+
TokenStatuses token_statuses = 1;
|
|
1412
|
+
Proof proof = 2;
|
|
1413
|
+
}
|
|
1414
|
+
ResponseMetadata metadata = 3;
|
|
1415
|
+
}
|
|
1416
|
+
oneof version {
|
|
1417
|
+
GetTokenStatusesResponseV0 v0 = 1;
|
|
1418
|
+
}
|
|
1419
|
+
}
|
|
1420
|
+
|
|
1421
|
+
message GetTokenPreProgrammedDistributionsRequest {
|
|
1422
|
+
message GetTokenPreProgrammedDistributionsRequestV0 {
|
|
1423
|
+
bytes token_id = 1;
|
|
1424
|
+
message StartAtInfo {
|
|
1425
|
+
uint64 start_time_ms = 1;
|
|
1426
|
+
optional bytes start_recipient = 2;
|
|
1427
|
+
optional bool start_recipient_included = 3;
|
|
1428
|
+
}
|
|
1429
|
+
optional StartAtInfo start_at_info = 2;
|
|
1430
|
+
optional uint32 limit = 3;
|
|
1431
|
+
bool prove = 4;
|
|
1432
|
+
}
|
|
1433
|
+
oneof version {
|
|
1434
|
+
GetTokenPreProgrammedDistributionsRequestV0 v0 = 1;
|
|
1435
|
+
}
|
|
1436
|
+
}
|
|
1437
|
+
|
|
1438
|
+
message GetTokenPreProgrammedDistributionsResponse {
|
|
1439
|
+
message GetTokenPreProgrammedDistributionsResponseV0 {
|
|
1440
|
+
message TokenDistributionEntry {
|
|
1441
|
+
bytes recipient_id = 1;
|
|
1442
|
+
uint64 amount = 2;
|
|
1443
|
+
}
|
|
1444
|
+
|
|
1445
|
+
message TokenTimedDistributionEntry {
|
|
1446
|
+
uint64 timestamp = 1;
|
|
1447
|
+
repeated TokenDistributionEntry distributions = 2;
|
|
1448
|
+
}
|
|
1449
|
+
|
|
1450
|
+
message TokenDistributions {
|
|
1451
|
+
repeated TokenTimedDistributionEntry token_distributions = 1;
|
|
1452
|
+
}
|
|
1453
|
+
|
|
1454
|
+
oneof result {
|
|
1455
|
+
TokenDistributions token_distributions = 1;
|
|
1456
|
+
Proof proof = 2;
|
|
1457
|
+
}
|
|
1458
|
+
ResponseMetadata metadata = 3;
|
|
1459
|
+
}
|
|
1460
|
+
oneof version {
|
|
1461
|
+
GetTokenPreProgrammedDistributionsResponseV0 v0 = 1;
|
|
1462
|
+
}
|
|
1463
|
+
}
|
|
1464
|
+
|
|
1465
|
+
message GetTokenTotalSupplyRequest {
|
|
1466
|
+
message GetTokenTotalSupplyRequestV0 {
|
|
1467
|
+
bytes token_id = 1;
|
|
1468
|
+
bool prove = 2;
|
|
1469
|
+
}
|
|
1470
|
+
oneof version {
|
|
1471
|
+
GetTokenTotalSupplyRequestV0 v0 = 1;
|
|
1472
|
+
}
|
|
1473
|
+
}
|
|
1474
|
+
|
|
1475
|
+
message GetTokenTotalSupplyResponse {
|
|
1476
|
+
message GetTokenTotalSupplyResponseV0 {
|
|
1477
|
+
message TokenTotalSupplyEntry {
|
|
1478
|
+
bytes token_id = 1;
|
|
1479
|
+
uint64 total_aggregated_amount_in_user_accounts = 2;
|
|
1480
|
+
uint64 total_system_amount = 3;
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1483
|
+
oneof result {
|
|
1484
|
+
TokenTotalSupplyEntry token_total_supply = 1;
|
|
1485
|
+
Proof proof = 2;
|
|
1486
|
+
}
|
|
1487
|
+
ResponseMetadata metadata = 3;
|
|
1488
|
+
}
|
|
1489
|
+
oneof version {
|
|
1490
|
+
GetTokenTotalSupplyResponseV0 v0 = 1;
|
|
1491
|
+
}
|
|
1492
|
+
}
|
|
1493
|
+
|
|
1494
|
+
message GetGroupInfoRequest {
|
|
1495
|
+
message GetGroupInfoRequestV0 {
|
|
1496
|
+
bytes contract_id = 1;
|
|
1497
|
+
uint32 group_contract_position = 2;
|
|
1498
|
+
bool prove = 3;
|
|
1499
|
+
}
|
|
1500
|
+
oneof version {
|
|
1501
|
+
GetGroupInfoRequestV0 v0 = 1;
|
|
1502
|
+
}
|
|
1503
|
+
}
|
|
1504
|
+
|
|
1505
|
+
message GetGroupInfoResponse {
|
|
1506
|
+
message GetGroupInfoResponseV0 {
|
|
1507
|
+
message GroupMemberEntry {
|
|
1508
|
+
bytes member_id = 1;
|
|
1509
|
+
uint32 power = 2;
|
|
1510
|
+
}
|
|
1511
|
+
|
|
1512
|
+
message GroupInfoEntry {
|
|
1513
|
+
repeated GroupMemberEntry members = 1;
|
|
1514
|
+
uint32 group_required_power = 2;
|
|
1515
|
+
}
|
|
1516
|
+
|
|
1517
|
+
message GroupInfo {
|
|
1518
|
+
optional GroupInfoEntry group_info = 1;
|
|
1519
|
+
}
|
|
1520
|
+
|
|
1521
|
+
oneof result {
|
|
1522
|
+
GroupInfo group_info = 1;
|
|
1523
|
+
Proof proof = 2;
|
|
1524
|
+
}
|
|
1525
|
+
ResponseMetadata metadata = 4;
|
|
1526
|
+
}
|
|
1527
|
+
oneof version {
|
|
1528
|
+
GetGroupInfoResponseV0 v0 = 1;
|
|
1529
|
+
}
|
|
1530
|
+
}
|
|
1531
|
+
|
|
1532
|
+
message GetGroupInfosRequest {
|
|
1533
|
+
message StartAtGroupContractPosition {
|
|
1534
|
+
uint32 start_group_contract_position = 1;
|
|
1535
|
+
bool start_group_contract_position_included = 2;
|
|
1536
|
+
}
|
|
1537
|
+
|
|
1538
|
+
message GetGroupInfosRequestV0 {
|
|
1539
|
+
bytes contract_id = 1;
|
|
1540
|
+
optional StartAtGroupContractPosition start_at_group_contract_position = 2;
|
|
1541
|
+
optional uint32 count = 3;
|
|
1542
|
+
bool prove = 4;
|
|
1543
|
+
}
|
|
1544
|
+
oneof version {
|
|
1545
|
+
GetGroupInfosRequestV0 v0 = 1;
|
|
1546
|
+
}
|
|
1547
|
+
}
|
|
1548
|
+
|
|
1549
|
+
message GetGroupInfosResponse {
|
|
1550
|
+
message GetGroupInfosResponseV0 {
|
|
1551
|
+
message GroupMemberEntry {
|
|
1552
|
+
bytes member_id = 1;
|
|
1553
|
+
uint32 power = 2;
|
|
1554
|
+
}
|
|
1555
|
+
|
|
1556
|
+
message GroupPositionInfoEntry {
|
|
1557
|
+
uint32 group_contract_position = 1;
|
|
1558
|
+
repeated GroupMemberEntry members = 2;
|
|
1559
|
+
uint32 group_required_power = 3;
|
|
1560
|
+
}
|
|
1561
|
+
|
|
1562
|
+
message GroupInfos {
|
|
1563
|
+
repeated GroupPositionInfoEntry group_infos = 1;
|
|
1564
|
+
}
|
|
1565
|
+
|
|
1566
|
+
oneof result {
|
|
1567
|
+
GroupInfos group_infos = 1;
|
|
1568
|
+
Proof proof = 2;
|
|
1569
|
+
}
|
|
1570
|
+
ResponseMetadata metadata = 4;
|
|
1571
|
+
}
|
|
1572
|
+
oneof version {
|
|
1573
|
+
GetGroupInfosResponseV0 v0 = 1;
|
|
1574
|
+
}
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1577
|
+
message GetGroupActionsRequest {
|
|
1578
|
+
enum ActionStatus {
|
|
1579
|
+
ACTIVE = 0; // Request the active actions
|
|
1580
|
+
CLOSED = 1; // Request the closed actions
|
|
1581
|
+
}
|
|
1582
|
+
|
|
1583
|
+
message StartAtActionId {
|
|
1584
|
+
bytes start_action_id = 1;
|
|
1585
|
+
bool start_action_id_included = 2;
|
|
1586
|
+
}
|
|
1587
|
+
|
|
1588
|
+
message GetGroupActionsRequestV0 {
|
|
1589
|
+
bytes contract_id = 1;
|
|
1590
|
+
uint32 group_contract_position = 2;
|
|
1591
|
+
ActionStatus status = 3;
|
|
1592
|
+
optional StartAtActionId start_at_action_id = 4;
|
|
1593
|
+
optional uint32 count = 5;
|
|
1594
|
+
bool prove = 6;
|
|
1595
|
+
}
|
|
1596
|
+
oneof version {
|
|
1597
|
+
GetGroupActionsRequestV0 v0 = 1;
|
|
1598
|
+
}
|
|
1599
|
+
}
|
|
1600
|
+
|
|
1601
|
+
message GetGroupActionsResponse {
|
|
1602
|
+
message GetGroupActionsResponseV0 {
|
|
1603
|
+
// Mint event
|
|
1604
|
+
message MintEvent {
|
|
1605
|
+
uint64 amount = 1; // Amount to mint
|
|
1606
|
+
bytes recipient_id = 2; // Recipient identifier
|
|
1607
|
+
optional string public_note = 3; // Public note
|
|
1608
|
+
}
|
|
1609
|
+
|
|
1610
|
+
// Burn event
|
|
1611
|
+
message BurnEvent {
|
|
1612
|
+
uint64 amount = 1; // Amount to burn
|
|
1613
|
+
optional string public_note = 2; // Public note
|
|
1614
|
+
}
|
|
1615
|
+
|
|
1616
|
+
// Freeze event
|
|
1617
|
+
message FreezeEvent {
|
|
1618
|
+
bytes frozen_id = 1; // Identifier of the frozen entity
|
|
1619
|
+
optional string public_note = 2; // Public note
|
|
1620
|
+
}
|
|
1621
|
+
|
|
1622
|
+
// Unfreeze event
|
|
1623
|
+
message UnfreezeEvent {
|
|
1624
|
+
bytes frozen_id = 1; // Identifier of the unfrozen entity
|
|
1625
|
+
optional string public_note = 2; // Public note
|
|
1626
|
+
}
|
|
1627
|
+
|
|
1628
|
+
// Destroy frozen funds event
|
|
1629
|
+
message DestroyFrozenFundsEvent {
|
|
1630
|
+
bytes frozen_id = 1; // Identifier of the frozen entity
|
|
1631
|
+
uint64 amount = 2; // Amount to destroy
|
|
1632
|
+
optional string public_note = 3; // Public note
|
|
1633
|
+
}
|
|
1634
|
+
|
|
1635
|
+
// Shared encrypted note
|
|
1636
|
+
message SharedEncryptedNote {
|
|
1637
|
+
uint32 sender_key_index = 1; // Sender key index
|
|
1638
|
+
uint32 recipient_key_index = 2; // Recipient key index
|
|
1639
|
+
bytes encrypted_data = 3; // Encrypted data
|
|
1640
|
+
}
|
|
1641
|
+
|
|
1642
|
+
// Personal encrypted note
|
|
1643
|
+
message PersonalEncryptedNote {
|
|
1644
|
+
uint32 root_encryption_key_index = 1; // Root encryption key index
|
|
1645
|
+
uint32 derivation_encryption_key_index = 2; // Derivation encryption key index
|
|
1646
|
+
bytes encrypted_data = 3; // Encrypted data
|
|
1647
|
+
}
|
|
1648
|
+
|
|
1649
|
+
// Emergency action event
|
|
1650
|
+
message EmergencyActionEvent {
|
|
1651
|
+
// Enum for emergency action types
|
|
1652
|
+
enum ActionType {
|
|
1653
|
+
PAUSE = 0; // Pause action
|
|
1654
|
+
RESUME = 1; // Resume action
|
|
1655
|
+
}
|
|
1656
|
+
|
|
1657
|
+
ActionType action_type = 1; // Emergency action type
|
|
1658
|
+
optional string public_note = 2; // Public note
|
|
1659
|
+
}
|
|
1660
|
+
|
|
1661
|
+
// Token config update event
|
|
1662
|
+
message TokenConfigUpdateEvent {
|
|
1663
|
+
bytes token_config_update_item = 1; // Token config update item
|
|
1664
|
+
optional string public_note = 2; // Public note
|
|
1665
|
+
}
|
|
1666
|
+
|
|
1667
|
+
// Event associated with this action
|
|
1668
|
+
message GroupActionEvent {
|
|
1669
|
+
oneof event_type {
|
|
1670
|
+
TokenEvent token_event = 1; // Token event details
|
|
1671
|
+
DocumentEvent document_event = 2;
|
|
1672
|
+
ContractEvent contract_event = 3;
|
|
1673
|
+
}
|
|
1674
|
+
}
|
|
1675
|
+
|
|
1676
|
+
message DocumentEvent {
|
|
1677
|
+
oneof type {
|
|
1678
|
+
DocumentCreateEvent create = 1; // Create event details
|
|
1679
|
+
}
|
|
1680
|
+
}
|
|
1681
|
+
|
|
1682
|
+
message DocumentCreateEvent {
|
|
1683
|
+
bytes created_document = 1;
|
|
1684
|
+
}
|
|
1685
|
+
|
|
1686
|
+
message ContractUpdateEvent {
|
|
1687
|
+
bytes updated_contract = 1;
|
|
1688
|
+
}
|
|
1689
|
+
|
|
1690
|
+
message ContractEvent {
|
|
1691
|
+
oneof type {
|
|
1692
|
+
ContractUpdateEvent update = 1; // Contract update event
|
|
1693
|
+
}
|
|
1694
|
+
}
|
|
1695
|
+
|
|
1696
|
+
// Details for token events
|
|
1697
|
+
message TokenEvent {
|
|
1698
|
+
oneof type {
|
|
1699
|
+
MintEvent mint = 1; // Mint event details
|
|
1700
|
+
BurnEvent burn = 2; // Burn event details
|
|
1701
|
+
FreezeEvent freeze = 3; // Freeze event details
|
|
1702
|
+
UnfreezeEvent unfreeze = 4; // Unfreeze event details
|
|
1703
|
+
DestroyFrozenFundsEvent destroy_frozen_funds = 5; // Destroy frozen funds
|
|
1704
|
+
EmergencyActionEvent emergency_action = 6; // Emergency action details
|
|
1705
|
+
TokenConfigUpdateEvent token_config_update = 7; // Token configuration update details
|
|
1706
|
+
}
|
|
1707
|
+
}
|
|
1708
|
+
|
|
1709
|
+
message GroupActionEntry {
|
|
1710
|
+
bytes action_id = 1; // Unique identifier for the action
|
|
1711
|
+
GroupActionEvent event = 2; // The event data
|
|
1712
|
+
}
|
|
1713
|
+
|
|
1714
|
+
message GroupActions {
|
|
1715
|
+
repeated GroupActionEntry group_actions = 1;
|
|
1716
|
+
}
|
|
1717
|
+
|
|
1718
|
+
oneof result {
|
|
1719
|
+
GroupActions group_actions = 1;
|
|
1720
|
+
Proof proof = 2;
|
|
1721
|
+
}
|
|
1722
|
+
ResponseMetadata metadata = 3;
|
|
1723
|
+
}
|
|
1724
|
+
oneof version {
|
|
1725
|
+
GetGroupActionsResponseV0 v0 = 1;
|
|
1726
|
+
}
|
|
1727
|
+
}
|
|
1728
|
+
|
|
1729
|
+
|
|
1730
|
+
message GetGroupActionSignersRequest {
|
|
1731
|
+
enum ActionStatus {
|
|
1732
|
+
ACTIVE = 0; // Request the active actions
|
|
1733
|
+
CLOSED = 1; // Request the closed actions
|
|
1734
|
+
}
|
|
1735
|
+
|
|
1736
|
+
message GetGroupActionSignersRequestV0 {
|
|
1737
|
+
bytes contract_id = 1;
|
|
1738
|
+
uint32 group_contract_position = 2;
|
|
1739
|
+
ActionStatus status = 3;
|
|
1740
|
+
bytes action_id = 4;
|
|
1741
|
+
bool prove = 5;
|
|
1742
|
+
}
|
|
1743
|
+
oneof version {
|
|
1744
|
+
GetGroupActionSignersRequestV0 v0 = 1;
|
|
1745
|
+
}
|
|
1746
|
+
}
|
|
1747
|
+
|
|
1748
|
+
message GetGroupActionSignersResponse {
|
|
1749
|
+
message GetGroupActionSignersResponseV0 {
|
|
1750
|
+
message GroupActionSigner {
|
|
1751
|
+
bytes signer_id = 1;
|
|
1752
|
+
uint32 power = 2;
|
|
1753
|
+
}
|
|
1754
|
+
message GroupActionSigners {
|
|
1755
|
+
repeated GroupActionSigner signers = 1;
|
|
1756
|
+
}
|
|
1757
|
+
|
|
1758
|
+
oneof result {
|
|
1759
|
+
GroupActionSigners group_action_signers = 1;
|
|
1760
|
+
Proof proof = 2;
|
|
1761
|
+
}
|
|
1762
|
+
ResponseMetadata metadata = 3;
|
|
1763
|
+
}
|
|
1764
|
+
|
|
1765
|
+
oneof version {
|
|
1766
|
+
GetGroupActionSignersResponseV0 v0 = 1;
|
|
1767
|
+
}
|
|
1768
|
+
}
|