@dashevo/dapi-grpc 2.1.0-dev.8 → 2.1.0-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/Cargo.toml +1 -1
- package/package.json +2 -2
- package/protos/platform/v0/platform.proto +37 -37
- package/src/drive/client/org.dash.platform.dapi.v0.rs +5 -3
- package/src/drive/wasm/org.dash.platform.dapi.v0.rs +5 -3
- package/src/platform/client/org.dash.platform.dapi.v0.rs +5 -3
- package/src/platform/wasm/org.dash.platform.dapi.v0.rs +5 -3
package/Cargo.toml
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dashevo/dapi-grpc",
|
|
3
|
-
"version": "2.1.0-
|
|
3
|
+
"version": "2.1.0-rc.1",
|
|
4
4
|
"description": "DAPI GRPC definition file and generated clients",
|
|
5
5
|
"browser": "browser.js",
|
|
6
6
|
"main": "node.js",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"homepage": "https://github.com/dashevo/dapi-grpc#readme",
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@dashevo/grpc-common": "2.1.0-
|
|
48
|
+
"@dashevo/grpc-common": "2.1.0-rc.1",
|
|
49
49
|
"@dashevo/protobufjs": "6.10.5",
|
|
50
50
|
"@grpc/grpc-js": "1.4.4",
|
|
51
51
|
"@improbable-eng/grpc-web": "^0.15.0",
|
|
@@ -37,7 +37,8 @@ service Platform {
|
|
|
37
37
|
rpc getDocuments(GetDocumentsRequest) returns (GetDocumentsResponse);
|
|
38
38
|
rpc getIdentityByPublicKeyHash(GetIdentityByPublicKeyHashRequest)
|
|
39
39
|
returns (GetIdentityByPublicKeyHashResponse);
|
|
40
|
-
rpc getIdentityByNonUniquePublicKeyHash(
|
|
40
|
+
rpc getIdentityByNonUniquePublicKeyHash(
|
|
41
|
+
GetIdentityByNonUniquePublicKeyHashRequest)
|
|
41
42
|
returns (GetIdentityByNonUniquePublicKeyHashResponse);
|
|
42
43
|
rpc waitForStateTransitionResult(WaitForStateTransitionResultRequest)
|
|
43
44
|
returns (WaitForStateTransitionResultResponse);
|
|
@@ -49,7 +50,8 @@ service Platform {
|
|
|
49
50
|
GetProtocolVersionUpgradeVoteStatusRequest)
|
|
50
51
|
returns (GetProtocolVersionUpgradeVoteStatusResponse);
|
|
51
52
|
rpc getEpochsInfo(GetEpochsInfoRequest) returns (GetEpochsInfoResponse);
|
|
52
|
-
rpc getFinalizedEpochInfos(GetFinalizedEpochInfosRequest)
|
|
53
|
+
rpc getFinalizedEpochInfos(GetFinalizedEpochInfosRequest)
|
|
54
|
+
returns (GetFinalizedEpochInfosResponse);
|
|
53
55
|
// What votes are currently happening for a specific contested index
|
|
54
56
|
rpc getContestedResources(GetContestedResourcesRequest)
|
|
55
57
|
returns (GetContestedResourcesResponse);
|
|
@@ -611,9 +613,7 @@ message GetIdentityByNonUniquePublicKeyHashRequest {
|
|
|
611
613
|
|
|
612
614
|
message GetIdentityByNonUniquePublicKeyHashResponse {
|
|
613
615
|
message GetIdentityByNonUniquePublicKeyHashResponseV0 {
|
|
614
|
-
message IdentityResponse {
|
|
615
|
-
optional bytes identity = 1;
|
|
616
|
-
}
|
|
616
|
+
message IdentityResponse { optional bytes identity = 1; }
|
|
617
617
|
|
|
618
618
|
message IdentityProvedResponse {
|
|
619
619
|
Proof grovedb_identity_public_key_hash_proof = 1;
|
|
@@ -624,7 +624,7 @@ message GetIdentityByNonUniquePublicKeyHashResponse {
|
|
|
624
624
|
IdentityProvedResponse proof = 2;
|
|
625
625
|
}
|
|
626
626
|
|
|
627
|
-
ResponseMetadata metadata = 3;
|
|
627
|
+
ResponseMetadata metadata = 3; // Metadata about the blockchain state
|
|
628
628
|
}
|
|
629
629
|
oneof version { GetIdentityByNonUniquePublicKeyHashResponseV0 v0 = 1; }
|
|
630
630
|
}
|
|
@@ -801,11 +801,11 @@ message GetEpochsInfoResponse {
|
|
|
801
801
|
|
|
802
802
|
message GetFinalizedEpochInfosRequest {
|
|
803
803
|
message GetFinalizedEpochInfosRequestV0 {
|
|
804
|
-
uint32 start_epoch_index = 1;
|
|
805
|
-
bool start_epoch_index_included = 2;
|
|
806
|
-
uint32 end_epoch_index = 3;
|
|
807
|
-
bool end_epoch_index_included = 4;
|
|
808
|
-
bool prove = 5;
|
|
804
|
+
uint32 start_epoch_index = 1; // The starting epoch index
|
|
805
|
+
bool start_epoch_index_included = 2; // Whether to include the start epoch
|
|
806
|
+
uint32 end_epoch_index = 3; // The ending epoch index
|
|
807
|
+
bool end_epoch_index_included = 4; // Whether to include the end epoch
|
|
808
|
+
bool prove = 5; // Flag to request a proof as the response
|
|
809
809
|
}
|
|
810
810
|
|
|
811
811
|
oneof version { GetFinalizedEpochInfosRequestV0 v0 = 1; }
|
|
@@ -813,9 +813,10 @@ message GetFinalizedEpochInfosRequest {
|
|
|
813
813
|
|
|
814
814
|
message GetFinalizedEpochInfosResponse {
|
|
815
815
|
message GetFinalizedEpochInfosResponseV0 {
|
|
816
|
-
// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
816
|
+
// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
817
|
+
// entries
|
|
817
818
|
message FinalizedEpochInfos {
|
|
818
|
-
repeated FinalizedEpochInfo finalized_epoch_infos =
|
|
819
|
+
repeated FinalizedEpochInfo finalized_epoch_infos =
|
|
819
820
|
1; // List of finalized information for each requested epoch
|
|
820
821
|
}
|
|
821
822
|
|
|
@@ -824,15 +825,17 @@ message GetFinalizedEpochInfosResponse {
|
|
|
824
825
|
uint32 number = 1; // The number of the epoch
|
|
825
826
|
uint64 first_block_height = 2
|
|
826
827
|
[ jstype = JS_STRING ]; // The height of the first block in this epoch
|
|
827
|
-
uint32 first_core_block_height =
|
|
828
|
+
uint32 first_core_block_height =
|
|
828
829
|
3; // The height of the first Core block in this epoch
|
|
829
830
|
uint64 first_block_time = 4
|
|
830
|
-
[ jstype =
|
|
831
|
-
|
|
831
|
+
[ jstype =
|
|
832
|
+
JS_STRING ]; // The timestamp of the first block (milliseconds)
|
|
833
|
+
double fee_multiplier = 5; // The fee multiplier (converted from permille)
|
|
832
834
|
uint32 protocol_version = 6; // The protocol version for this epoch
|
|
833
835
|
uint64 total_blocks_in_epoch = 7
|
|
834
836
|
[ jstype = JS_STRING ]; // Total number of blocks in the epoch
|
|
835
|
-
uint32 next_epoch_start_core_block_height =
|
|
837
|
+
uint32 next_epoch_start_core_block_height =
|
|
838
|
+
8; // Core block height where next epoch starts
|
|
836
839
|
uint64 total_processing_fees = 9
|
|
837
840
|
[ jstype = JS_STRING ]; // Total processing fees collected
|
|
838
841
|
uint64 total_distributed_storage_fees = 10
|
|
@@ -841,20 +844,21 @@ message GetFinalizedEpochInfosResponse {
|
|
|
841
844
|
[ jstype = JS_STRING ]; // Total storage fees created
|
|
842
845
|
uint64 core_block_rewards = 12
|
|
843
846
|
[ jstype = JS_STRING ]; // Rewards from core blocks
|
|
844
|
-
repeated BlockProposer block_proposers =
|
|
847
|
+
repeated BlockProposer block_proposers =
|
|
848
|
+
13; // List of block proposers and their counts
|
|
845
849
|
}
|
|
846
850
|
|
|
847
851
|
// BlockProposer represents a block proposer and their block count
|
|
848
852
|
message BlockProposer {
|
|
849
|
-
bytes proposer_id = 1;
|
|
853
|
+
bytes proposer_id = 1; // The proposer's identifier
|
|
850
854
|
uint32 block_count = 2; // Number of blocks proposed
|
|
851
855
|
}
|
|
852
856
|
|
|
853
857
|
oneof result {
|
|
854
|
-
FinalizedEpochInfos epochs =
|
|
858
|
+
FinalizedEpochInfos epochs =
|
|
855
859
|
1; // The actual finalized information about the requested epochs
|
|
856
|
-
Proof proof =
|
|
857
|
-
|
|
860
|
+
Proof proof = 2; // Cryptographic proof of the finalized epoch
|
|
861
|
+
// information, if requested
|
|
858
862
|
}
|
|
859
863
|
ResponseMetadata metadata = 3; // Metadata about the blockchain state
|
|
860
864
|
}
|
|
@@ -1456,7 +1460,6 @@ message GetTokenDirectPurchasePricesRequest {
|
|
|
1456
1460
|
oneof version { GetTokenDirectPurchasePricesRequestV0 v0 = 1; }
|
|
1457
1461
|
}
|
|
1458
1462
|
|
|
1459
|
-
|
|
1460
1463
|
// Response to GetTokenDirectPurchasePricesRequest, containing information about
|
|
1461
1464
|
// direct purchase prices defined for requested token IDs.
|
|
1462
1465
|
message GetTokenDirectPurchasePricesResponse {
|
|
@@ -1517,9 +1520,7 @@ message GetTokenContractInfoRequest {
|
|
|
1517
1520
|
bool prove = 2;
|
|
1518
1521
|
}
|
|
1519
1522
|
|
|
1520
|
-
oneof version {
|
|
1521
|
-
GetTokenContractInfoRequestV0 v0 = 1;
|
|
1522
|
-
}
|
|
1523
|
+
oneof version { GetTokenContractInfoRequestV0 v0 = 1; }
|
|
1523
1524
|
}
|
|
1524
1525
|
|
|
1525
1526
|
// Response to GetTokenContractInfoRequest.
|
|
@@ -1546,9 +1547,7 @@ message GetTokenContractInfoResponse {
|
|
|
1546
1547
|
ResponseMetadata metadata = 3;
|
|
1547
1548
|
}
|
|
1548
1549
|
|
|
1549
|
-
oneof version {
|
|
1550
|
-
GetTokenContractInfoResponseV0 v0 = 1;
|
|
1551
|
-
}
|
|
1550
|
+
oneof version { GetTokenContractInfoResponseV0 v0 = 1; }
|
|
1552
1551
|
}
|
|
1553
1552
|
|
|
1554
1553
|
message GetTokenPreProgrammedDistributionsRequest {
|
|
@@ -1605,15 +1604,16 @@ message GetTokenPerpetualDistributionLastClaimRequest {
|
|
|
1605
1604
|
|
|
1606
1605
|
message GetTokenPerpetualDistributionLastClaimRequestV0 {
|
|
1607
1606
|
// 32‑byte token identifier
|
|
1608
|
-
bytes token_id
|
|
1607
|
+
bytes token_id = 1;
|
|
1609
1608
|
|
|
1610
|
-
// This should be set if you wish to get back the last claim info as a
|
|
1609
|
+
// This should be set if you wish to get back the last claim info as a
|
|
1610
|
+
// specific type
|
|
1611
1611
|
optional ContractTokenInfo contract_info = 2;
|
|
1612
1612
|
|
|
1613
1613
|
// Identity whose last‑claim timestamp is requested
|
|
1614
1614
|
bytes identity_id = 4;
|
|
1615
1615
|
// Return GroveDB / signature proof instead of raw value
|
|
1616
|
-
bool
|
|
1616
|
+
bool prove = 5;
|
|
1617
1617
|
}
|
|
1618
1618
|
|
|
1619
1619
|
oneof version { GetTokenPerpetualDistributionLastClaimRequestV0 v0 = 1; }
|
|
@@ -1626,17 +1626,17 @@ message GetTokenPerpetualDistributionLastClaimResponse {
|
|
|
1626
1626
|
oneof paid_at {
|
|
1627
1627
|
uint64 timestamp_ms = 1 [ jstype = JS_STRING ]; // Unix epoch, ms
|
|
1628
1628
|
uint64 block_height = 2 [ jstype = JS_STRING ]; // Core‑block height
|
|
1629
|
-
uint32 epoch
|
|
1630
|
-
bytes
|
|
1629
|
+
uint32 epoch = 3; // Epoch index
|
|
1630
|
+
bytes raw_bytes = 4; // Arbitrary encoding
|
|
1631
1631
|
}
|
|
1632
1632
|
}
|
|
1633
1633
|
|
|
1634
1634
|
oneof result {
|
|
1635
1635
|
LastClaimInfo last_claim = 1; // Direct answer
|
|
1636
|
-
Proof
|
|
1636
|
+
Proof proof = 2; // GroveDB / quorum proof
|
|
1637
1637
|
}
|
|
1638
1638
|
|
|
1639
|
-
ResponseMetadata metadata = 3;
|
|
1639
|
+
ResponseMetadata metadata = 3; // Chain context
|
|
1640
1640
|
}
|
|
1641
1641
|
|
|
1642
1642
|
oneof version { GetTokenPerpetualDistributionLastClaimResponseV0 v0 = 1; }
|
|
@@ -1647,7 +1647,7 @@ message GetTokenTotalSupplyRequest {
|
|
|
1647
1647
|
bytes token_id = 1;
|
|
1648
1648
|
bool prove = 2;
|
|
1649
1649
|
}
|
|
1650
|
-
oneof version {GetTokenTotalSupplyRequestV0 v0 = 1;}
|
|
1650
|
+
oneof version { GetTokenTotalSupplyRequestV0 v0 = 1; }
|
|
1651
1651
|
}
|
|
1652
1652
|
|
|
1653
1653
|
message GetTokenTotalSupplyResponse {
|
|
@@ -2168,7 +2168,8 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2168
2168
|
}
|
|
2169
2169
|
/// Nested message and enum types in `GetFinalizedEpochInfosResponseV0`.
|
|
2170
2170
|
pub mod get_finalized_epoch_infos_response_v0 {
|
|
2171
|
-
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2171
|
+
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2172
|
+
/// entries
|
|
2172
2173
|
#[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
|
|
2173
2174
|
#[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
|
|
2174
2175
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
@@ -2244,7 +2245,7 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2244
2245
|
/// The actual finalized information about the requested epochs
|
|
2245
2246
|
#[prost(message, tag = "1")]
|
|
2246
2247
|
Epochs(FinalizedEpochInfos),
|
|
2247
|
-
/// Cryptographic proof of the finalized epoch
|
|
2248
|
+
/// Cryptographic proof of the finalized epoch
|
|
2248
2249
|
#[prost(message, tag = "2")]
|
|
2249
2250
|
Proof(super::super::Proof),
|
|
2250
2251
|
}
|
|
@@ -4487,7 +4488,8 @@ pub mod get_token_perpetual_distribution_last_claim_request {
|
|
|
4487
4488
|
/// 32‑byte token identifier
|
|
4488
4489
|
#[prost(bytes = "vec", tag = "1")]
|
|
4489
4490
|
pub token_id: ::prost::alloc::vec::Vec<u8>,
|
|
4490
|
-
/// This should be set if you wish to get back the last claim info as a
|
|
4491
|
+
/// This should be set if you wish to get back the last claim info as a
|
|
4492
|
+
/// specific type
|
|
4491
4493
|
#[prost(message, optional, tag = "2")]
|
|
4492
4494
|
pub contract_info: ::core::option::Option<ContractTokenInfo>,
|
|
4493
4495
|
/// Identity whose last‑claim timestamp is requested
|
|
@@ -2168,7 +2168,8 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2168
2168
|
}
|
|
2169
2169
|
/// Nested message and enum types in `GetFinalizedEpochInfosResponseV0`.
|
|
2170
2170
|
pub mod get_finalized_epoch_infos_response_v0 {
|
|
2171
|
-
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2171
|
+
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2172
|
+
/// entries
|
|
2172
2173
|
#[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
|
|
2173
2174
|
#[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
|
|
2174
2175
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
@@ -2244,7 +2245,7 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2244
2245
|
/// The actual finalized information about the requested epochs
|
|
2245
2246
|
#[prost(message, tag = "1")]
|
|
2246
2247
|
Epochs(FinalizedEpochInfos),
|
|
2247
|
-
/// Cryptographic proof of the finalized epoch
|
|
2248
|
+
/// Cryptographic proof of the finalized epoch
|
|
2248
2249
|
#[prost(message, tag = "2")]
|
|
2249
2250
|
Proof(super::super::Proof),
|
|
2250
2251
|
}
|
|
@@ -4487,7 +4488,8 @@ pub mod get_token_perpetual_distribution_last_claim_request {
|
|
|
4487
4488
|
/// 32‑byte token identifier
|
|
4488
4489
|
#[prost(bytes = "vec", tag = "1")]
|
|
4489
4490
|
pub token_id: ::prost::alloc::vec::Vec<u8>,
|
|
4490
|
-
/// This should be set if you wish to get back the last claim info as a
|
|
4491
|
+
/// This should be set if you wish to get back the last claim info as a
|
|
4492
|
+
/// specific type
|
|
4491
4493
|
#[prost(message, optional, tag = "2")]
|
|
4492
4494
|
pub contract_info: ::core::option::Option<ContractTokenInfo>,
|
|
4493
4495
|
/// Identity whose last‑claim timestamp is requested
|
|
@@ -2346,7 +2346,8 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2346
2346
|
}
|
|
2347
2347
|
/// Nested message and enum types in `GetFinalizedEpochInfosResponseV0`.
|
|
2348
2348
|
pub mod get_finalized_epoch_infos_response_v0 {
|
|
2349
|
-
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2349
|
+
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2350
|
+
/// entries
|
|
2350
2351
|
#[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
|
|
2351
2352
|
#[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
|
|
2352
2353
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
@@ -2422,7 +2423,7 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2422
2423
|
/// The actual finalized information about the requested epochs
|
|
2423
2424
|
#[prost(message, tag = "1")]
|
|
2424
2425
|
Epochs(FinalizedEpochInfos),
|
|
2425
|
-
/// Cryptographic proof of the finalized epoch
|
|
2426
|
+
/// Cryptographic proof of the finalized epoch
|
|
2426
2427
|
#[prost(message, tag = "2")]
|
|
2427
2428
|
Proof(super::super::Proof),
|
|
2428
2429
|
}
|
|
@@ -4782,7 +4783,8 @@ pub mod get_token_perpetual_distribution_last_claim_request {
|
|
|
4782
4783
|
/// 32‑byte token identifier
|
|
4783
4784
|
#[prost(bytes = "vec", tag = "1")]
|
|
4784
4785
|
pub token_id: ::prost::alloc::vec::Vec<u8>,
|
|
4785
|
-
/// This should be set if you wish to get back the last claim info as a
|
|
4786
|
+
/// This should be set if you wish to get back the last claim info as a
|
|
4787
|
+
/// specific type
|
|
4786
4788
|
#[prost(message, optional, tag = "2")]
|
|
4787
4789
|
pub contract_info: ::core::option::Option<ContractTokenInfo>,
|
|
4788
4790
|
/// Identity whose last‑claim timestamp is requested
|
|
@@ -2346,7 +2346,8 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2346
2346
|
}
|
|
2347
2347
|
/// Nested message and enum types in `GetFinalizedEpochInfosResponseV0`.
|
|
2348
2348
|
pub mod get_finalized_epoch_infos_response_v0 {
|
|
2349
|
-
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2349
|
+
/// FinalizedEpochInfos holds a collection of finalized epoch information
|
|
2350
|
+
/// entries
|
|
2350
2351
|
#[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
|
|
2351
2352
|
#[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
|
|
2352
2353
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
@@ -2422,7 +2423,7 @@ pub mod get_finalized_epoch_infos_response {
|
|
|
2422
2423
|
/// The actual finalized information about the requested epochs
|
|
2423
2424
|
#[prost(message, tag = "1")]
|
|
2424
2425
|
Epochs(FinalizedEpochInfos),
|
|
2425
|
-
/// Cryptographic proof of the finalized epoch
|
|
2426
|
+
/// Cryptographic proof of the finalized epoch
|
|
2426
2427
|
#[prost(message, tag = "2")]
|
|
2427
2428
|
Proof(super::super::Proof),
|
|
2428
2429
|
}
|
|
@@ -4782,7 +4783,8 @@ pub mod get_token_perpetual_distribution_last_claim_request {
|
|
|
4782
4783
|
/// 32‑byte token identifier
|
|
4783
4784
|
#[prost(bytes = "vec", tag = "1")]
|
|
4784
4785
|
pub token_id: ::prost::alloc::vec::Vec<u8>,
|
|
4785
|
-
/// This should be set if you wish to get back the last claim info as a
|
|
4786
|
+
/// This should be set if you wish to get back the last claim info as a
|
|
4787
|
+
/// specific type
|
|
4786
4788
|
#[prost(message, optional, tag = "2")]
|
|
4787
4789
|
pub contract_info: ::core::option::Option<ContractTokenInfo>,
|
|
4788
4790
|
/// Identity whose last‑claim timestamp is requested
|