@dashevo/dapi-grpc 1.0.0-dev.11 → 1.0.0-dev.12
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 +2 -1
- package/build.rs +4 -2
- package/clients/core/v0/nodejs/CorePromiseClient.js +51 -13
- package/clients/core/v0/nodejs/core_pbjs.js +869 -703
- package/clients/core/v0/nodejs/core_protoc.js +681 -609
- package/clients/core/v0/web/CorePromiseClient.js +19 -5
- package/clients/core/v0/web/core_pb.d.ts +99 -89
- package/clients/core/v0/web/core_pb.js +681 -609
- package/clients/core/v0/web/core_pb_service.d.ts +29 -10
- package/clients/core/v0/web/core_pb_service.js +46 -6
- package/clients/platform/v0/nodejs/PlatformPromiseClient.js +55 -14
- package/clients/platform/v0/nodejs/platform_pbjs.js +7805 -7761
- package/clients/platform/v0/nodejs/platform_protoc.js +7845 -7749
- package/clients/platform/v0/web/PlatformPromiseClient.js +22 -8
- package/clients/platform/v0/web/platform_pb.d.ts +388 -372
- package/clients/platform/v0/web/platform_pb.js +7845 -7749
- package/clients/platform/v0/web/platform_pb_service.d.ts +35 -35
- package/clients/platform/v0/web/platform_pb_service.js +35 -35
- package/package.json +2 -2
- package/protos/core/v0/core.proto +27 -23
- package/protos/platform/v0/platform.proto +49 -64
- package/src/core/proto/org.dash.platform.dapi.v0.rs +196 -101
- package/src/platform/proto/org.dash.platform.dapi.v0.rs +197 -345
- package/test/unit/clients/core/v0/nodejs/CorePromiseClient.spec.js +27 -6
- package/test/unit/clients/platform/v0/nodejs/PlatformPromiseClient.spec.js +21 -0
- package/test/unit/getCoreDefinition.spec.js +5 -2
|
@@ -295,118 +295,6 @@ pub mod get_identity_response {
|
|
|
295
295
|
}
|
|
296
296
|
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
297
297
|
#[serde(rename_all = "snake_case")]
|
|
298
|
-
#[derive(::dapi_grpc_macros::VersionedGrpcMessage)]
|
|
299
|
-
#[grpc_versions(0)]
|
|
300
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
301
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
302
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
303
|
-
pub struct GetIdentitiesRequest {
|
|
304
|
-
#[prost(oneof = "get_identities_request::Version", tags = "1")]
|
|
305
|
-
pub version: ::core::option::Option<get_identities_request::Version>,
|
|
306
|
-
}
|
|
307
|
-
/// Nested message and enum types in `GetIdentitiesRequest`.
|
|
308
|
-
pub mod get_identities_request {
|
|
309
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
310
|
-
#[serde(rename_all = "snake_case")]
|
|
311
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
312
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
313
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
314
|
-
pub struct GetIdentitiesRequestV0 {
|
|
315
|
-
#[prost(bytes = "vec", repeated, tag = "1")]
|
|
316
|
-
#[serde(with = "crate::deserialization::vec_base64string")]
|
|
317
|
-
pub ids: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
|
|
318
|
-
#[prost(bool, tag = "2")]
|
|
319
|
-
pub prove: bool,
|
|
320
|
-
}
|
|
321
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
322
|
-
#[serde(rename_all = "snake_case")]
|
|
323
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
324
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
325
|
-
pub enum Version {
|
|
326
|
-
#[prost(message, tag = "1")]
|
|
327
|
-
V0(GetIdentitiesRequestV0),
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
331
|
-
#[serde(rename_all = "snake_case")]
|
|
332
|
-
#[derive(
|
|
333
|
-
::dapi_grpc_macros::VersionedGrpcMessage,
|
|
334
|
-
::dapi_grpc_macros::VersionedGrpcResponse
|
|
335
|
-
)]
|
|
336
|
-
#[grpc_versions(0)]
|
|
337
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
338
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
339
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
340
|
-
pub struct GetIdentitiesResponse {
|
|
341
|
-
#[prost(oneof = "get_identities_response::Version", tags = "1")]
|
|
342
|
-
pub version: ::core::option::Option<get_identities_response::Version>,
|
|
343
|
-
}
|
|
344
|
-
/// Nested message and enum types in `GetIdentitiesResponse`.
|
|
345
|
-
pub mod get_identities_response {
|
|
346
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
347
|
-
#[serde(rename_all = "snake_case")]
|
|
348
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
349
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
350
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
351
|
-
pub struct IdentityValue {
|
|
352
|
-
#[prost(bytes = "vec", tag = "1")]
|
|
353
|
-
pub value: ::prost::alloc::vec::Vec<u8>,
|
|
354
|
-
}
|
|
355
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
356
|
-
#[serde(rename_all = "snake_case")]
|
|
357
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
358
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
359
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
360
|
-
pub struct IdentityEntry {
|
|
361
|
-
#[prost(bytes = "vec", tag = "1")]
|
|
362
|
-
pub key: ::prost::alloc::vec::Vec<u8>,
|
|
363
|
-
#[prost(message, optional, tag = "2")]
|
|
364
|
-
pub value: ::core::option::Option<IdentityValue>,
|
|
365
|
-
}
|
|
366
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
367
|
-
#[serde(rename_all = "snake_case")]
|
|
368
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
369
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
370
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
371
|
-
pub struct Identities {
|
|
372
|
-
#[prost(message, repeated, tag = "1")]
|
|
373
|
-
pub identity_entries: ::prost::alloc::vec::Vec<IdentityEntry>,
|
|
374
|
-
}
|
|
375
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
376
|
-
#[serde(rename_all = "snake_case")]
|
|
377
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
378
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
379
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
380
|
-
pub struct GetIdentitiesResponseV0 {
|
|
381
|
-
#[prost(message, optional, tag = "3")]
|
|
382
|
-
pub metadata: ::core::option::Option<super::ResponseMetadata>,
|
|
383
|
-
#[prost(oneof = "get_identities_response_v0::Result", tags = "1, 2")]
|
|
384
|
-
pub result: ::core::option::Option<get_identities_response_v0::Result>,
|
|
385
|
-
}
|
|
386
|
-
/// Nested message and enum types in `GetIdentitiesResponseV0`.
|
|
387
|
-
pub mod get_identities_response_v0 {
|
|
388
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
389
|
-
#[serde(rename_all = "snake_case")]
|
|
390
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
391
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
392
|
-
pub enum Result {
|
|
393
|
-
#[prost(message, tag = "1")]
|
|
394
|
-
Identities(super::Identities),
|
|
395
|
-
#[prost(message, tag = "2")]
|
|
396
|
-
Proof(super::super::Proof),
|
|
397
|
-
}
|
|
398
|
-
}
|
|
399
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
400
|
-
#[serde(rename_all = "snake_case")]
|
|
401
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
402
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
403
|
-
pub enum Version {
|
|
404
|
-
#[prost(message, tag = "1")]
|
|
405
|
-
V0(GetIdentitiesResponseV0),
|
|
406
|
-
}
|
|
407
|
-
}
|
|
408
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
409
|
-
#[serde(rename_all = "snake_case")]
|
|
410
298
|
#[derive(
|
|
411
299
|
::dapi_grpc_macros::VersionedGrpcMessage,
|
|
412
300
|
::dapi_grpc_macros::VersionedGrpcResponse
|
|
@@ -832,6 +720,131 @@ pub mod get_identity_keys_response {
|
|
|
832
720
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
833
721
|
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
834
722
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
723
|
+
pub struct GetIdentitiesContractKeysRequest {
|
|
724
|
+
#[prost(oneof = "get_identities_contract_keys_request::Version", tags = "1")]
|
|
725
|
+
pub version: ::core::option::Option<get_identities_contract_keys_request::Version>,
|
|
726
|
+
}
|
|
727
|
+
/// Nested message and enum types in `GetIdentitiesContractKeysRequest`.
|
|
728
|
+
pub mod get_identities_contract_keys_request {
|
|
729
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
730
|
+
#[serde(rename_all = "snake_case")]
|
|
731
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
732
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
733
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
734
|
+
pub struct GetIdentitiesContractKeysRequestV0 {
|
|
735
|
+
#[prost(bytes = "vec", repeated, tag = "1")]
|
|
736
|
+
pub identities_ids: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
|
|
737
|
+
#[prost(bytes = "vec", tag = "2")]
|
|
738
|
+
pub contract_id: ::prost::alloc::vec::Vec<u8>,
|
|
739
|
+
#[prost(string, optional, tag = "3")]
|
|
740
|
+
pub document_type_name: ::core::option::Option<::prost::alloc::string::String>,
|
|
741
|
+
#[prost(enumeration = "super::KeyPurpose", repeated, tag = "4")]
|
|
742
|
+
pub purposes: ::prost::alloc::vec::Vec<i32>,
|
|
743
|
+
#[prost(bool, tag = "5")]
|
|
744
|
+
pub prove: bool,
|
|
745
|
+
}
|
|
746
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
747
|
+
#[serde(rename_all = "snake_case")]
|
|
748
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
749
|
+
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
750
|
+
pub enum Version {
|
|
751
|
+
#[prost(message, tag = "1")]
|
|
752
|
+
V0(GetIdentitiesContractKeysRequestV0),
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
756
|
+
#[serde(rename_all = "snake_case")]
|
|
757
|
+
#[derive(
|
|
758
|
+
::dapi_grpc_macros::VersionedGrpcMessage,
|
|
759
|
+
::dapi_grpc_macros::VersionedGrpcResponse
|
|
760
|
+
)]
|
|
761
|
+
#[grpc_versions(0)]
|
|
762
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
763
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
764
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
765
|
+
pub struct GetIdentitiesContractKeysResponse {
|
|
766
|
+
#[prost(oneof = "get_identities_contract_keys_response::Version", tags = "1")]
|
|
767
|
+
pub version: ::core::option::Option<get_identities_contract_keys_response::Version>,
|
|
768
|
+
}
|
|
769
|
+
/// Nested message and enum types in `GetIdentitiesContractKeysResponse`.
|
|
770
|
+
pub mod get_identities_contract_keys_response {
|
|
771
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
772
|
+
#[serde(rename_all = "snake_case")]
|
|
773
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
774
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
775
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
776
|
+
pub struct GetIdentitiesContractKeysResponseV0 {
|
|
777
|
+
#[prost(message, optional, tag = "3")]
|
|
778
|
+
pub metadata: ::core::option::Option<super::ResponseMetadata>,
|
|
779
|
+
#[prost(
|
|
780
|
+
oneof = "get_identities_contract_keys_response_v0::Result",
|
|
781
|
+
tags = "1, 2"
|
|
782
|
+
)]
|
|
783
|
+
pub result: ::core::option::Option<
|
|
784
|
+
get_identities_contract_keys_response_v0::Result,
|
|
785
|
+
>,
|
|
786
|
+
}
|
|
787
|
+
/// Nested message and enum types in `GetIdentitiesContractKeysResponseV0`.
|
|
788
|
+
pub mod get_identities_contract_keys_response_v0 {
|
|
789
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
790
|
+
#[serde(rename_all = "snake_case")]
|
|
791
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
792
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
793
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
794
|
+
pub struct PurposeKeys {
|
|
795
|
+
#[prost(enumeration = "super::super::KeyPurpose", tag = "1")]
|
|
796
|
+
pub purpose: i32,
|
|
797
|
+
#[prost(bytes = "vec", repeated, tag = "2")]
|
|
798
|
+
pub keys_bytes: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
|
|
799
|
+
}
|
|
800
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
801
|
+
#[serde(rename_all = "snake_case")]
|
|
802
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
803
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
804
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
805
|
+
pub struct IdentityKeys {
|
|
806
|
+
#[prost(bytes = "vec", tag = "1")]
|
|
807
|
+
#[serde(with = "serde_bytes")]
|
|
808
|
+
pub identity_id: ::prost::alloc::vec::Vec<u8>,
|
|
809
|
+
#[prost(message, repeated, tag = "2")]
|
|
810
|
+
pub keys: ::prost::alloc::vec::Vec<PurposeKeys>,
|
|
811
|
+
}
|
|
812
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
813
|
+
#[serde(rename_all = "snake_case")]
|
|
814
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
815
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
816
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
817
|
+
pub struct IdentitiesKeys {
|
|
818
|
+
#[prost(message, repeated, tag = "1")]
|
|
819
|
+
pub entries: ::prost::alloc::vec::Vec<IdentityKeys>,
|
|
820
|
+
}
|
|
821
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
822
|
+
#[serde(rename_all = "snake_case")]
|
|
823
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
824
|
+
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
825
|
+
pub enum Result {
|
|
826
|
+
#[prost(message, tag = "1")]
|
|
827
|
+
IdentitiesKeys(IdentitiesKeys),
|
|
828
|
+
#[prost(message, tag = "2")]
|
|
829
|
+
Proof(super::super::Proof),
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
833
|
+
#[serde(rename_all = "snake_case")]
|
|
834
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
835
|
+
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
836
|
+
pub enum Version {
|
|
837
|
+
#[prost(message, tag = "1")]
|
|
838
|
+
V0(GetIdentitiesContractKeysResponseV0),
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
842
|
+
#[serde(rename_all = "snake_case")]
|
|
843
|
+
#[derive(::dapi_grpc_macros::VersionedGrpcMessage)]
|
|
844
|
+
#[grpc_versions(0)]
|
|
845
|
+
#[derive(::dapi_grpc_macros::Mockable)]
|
|
846
|
+
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
847
|
+
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
835
848
|
pub struct GetProofsRequest {
|
|
836
849
|
#[prost(oneof = "get_proofs_request::Version", tags = "1")]
|
|
837
850
|
pub version: ::core::option::Option<get_proofs_request::Version>,
|
|
@@ -1417,119 +1430,6 @@ pub mod get_documents_response {
|
|
|
1417
1430
|
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1418
1431
|
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1419
1432
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1420
|
-
pub struct GetIdentitiesByPublicKeyHashesRequest {
|
|
1421
|
-
#[prost(oneof = "get_identities_by_public_key_hashes_request::Version", tags = "1")]
|
|
1422
|
-
pub version: ::core::option::Option<
|
|
1423
|
-
get_identities_by_public_key_hashes_request::Version,
|
|
1424
|
-
>,
|
|
1425
|
-
}
|
|
1426
|
-
/// Nested message and enum types in `GetIdentitiesByPublicKeyHashesRequest`.
|
|
1427
|
-
pub mod get_identities_by_public_key_hashes_request {
|
|
1428
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1429
|
-
#[serde(rename_all = "snake_case")]
|
|
1430
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1431
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1432
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1433
|
-
pub struct GetIdentitiesByPublicKeyHashesRequestV0 {
|
|
1434
|
-
#[prost(bytes = "vec", repeated, tag = "1")]
|
|
1435
|
-
#[serde(with = "crate::deserialization::vec_base64string")]
|
|
1436
|
-
pub public_key_hashes: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
|
|
1437
|
-
#[prost(bool, tag = "2")]
|
|
1438
|
-
pub prove: bool,
|
|
1439
|
-
}
|
|
1440
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1441
|
-
#[serde(rename_all = "snake_case")]
|
|
1442
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1443
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
1444
|
-
pub enum Version {
|
|
1445
|
-
#[prost(message, tag = "1")]
|
|
1446
|
-
V0(GetIdentitiesByPublicKeyHashesRequestV0),
|
|
1447
|
-
}
|
|
1448
|
-
}
|
|
1449
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1450
|
-
#[serde(rename_all = "snake_case")]
|
|
1451
|
-
#[derive(
|
|
1452
|
-
::dapi_grpc_macros::VersionedGrpcMessage,
|
|
1453
|
-
::dapi_grpc_macros::VersionedGrpcResponse
|
|
1454
|
-
)]
|
|
1455
|
-
#[grpc_versions(0)]
|
|
1456
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1457
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1458
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1459
|
-
pub struct GetIdentitiesByPublicKeyHashesResponse {
|
|
1460
|
-
#[prost(oneof = "get_identities_by_public_key_hashes_response::Version", tags = "1")]
|
|
1461
|
-
pub version: ::core::option::Option<
|
|
1462
|
-
get_identities_by_public_key_hashes_response::Version,
|
|
1463
|
-
>,
|
|
1464
|
-
}
|
|
1465
|
-
/// Nested message and enum types in `GetIdentitiesByPublicKeyHashesResponse`.
|
|
1466
|
-
pub mod get_identities_by_public_key_hashes_response {
|
|
1467
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1468
|
-
#[serde(rename_all = "snake_case")]
|
|
1469
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1470
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1471
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1472
|
-
pub struct PublicKeyHashIdentityEntry {
|
|
1473
|
-
#[prost(bytes = "vec", tag = "1")]
|
|
1474
|
-
#[serde(with = "serde_bytes")]
|
|
1475
|
-
pub public_key_hash: ::prost::alloc::vec::Vec<u8>,
|
|
1476
|
-
#[prost(message, optional, tag = "2")]
|
|
1477
|
-
pub value: ::core::option::Option<::prost::alloc::vec::Vec<u8>>,
|
|
1478
|
-
}
|
|
1479
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1480
|
-
#[serde(rename_all = "snake_case")]
|
|
1481
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1482
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1483
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1484
|
-
pub struct IdentitiesByPublicKeyHashes {
|
|
1485
|
-
#[prost(message, repeated, tag = "1")]
|
|
1486
|
-
pub identity_entries: ::prost::alloc::vec::Vec<PublicKeyHashIdentityEntry>,
|
|
1487
|
-
}
|
|
1488
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1489
|
-
#[serde(rename_all = "snake_case")]
|
|
1490
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1491
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1492
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1493
|
-
pub struct GetIdentitiesByPublicKeyHashesResponseV0 {
|
|
1494
|
-
#[prost(message, optional, tag = "3")]
|
|
1495
|
-
pub metadata: ::core::option::Option<super::ResponseMetadata>,
|
|
1496
|
-
#[prost(
|
|
1497
|
-
oneof = "get_identities_by_public_key_hashes_response_v0::Result",
|
|
1498
|
-
tags = "1, 2"
|
|
1499
|
-
)]
|
|
1500
|
-
pub result: ::core::option::Option<
|
|
1501
|
-
get_identities_by_public_key_hashes_response_v0::Result,
|
|
1502
|
-
>,
|
|
1503
|
-
}
|
|
1504
|
-
/// Nested message and enum types in `GetIdentitiesByPublicKeyHashesResponseV0`.
|
|
1505
|
-
pub mod get_identities_by_public_key_hashes_response_v0 {
|
|
1506
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1507
|
-
#[serde(rename_all = "snake_case")]
|
|
1508
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1509
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
1510
|
-
pub enum Result {
|
|
1511
|
-
#[prost(message, tag = "1")]
|
|
1512
|
-
Identities(super::IdentitiesByPublicKeyHashes),
|
|
1513
|
-
#[prost(message, tag = "2")]
|
|
1514
|
-
Proof(super::super::Proof),
|
|
1515
|
-
}
|
|
1516
|
-
}
|
|
1517
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1518
|
-
#[serde(rename_all = "snake_case")]
|
|
1519
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1520
|
-
#[derive(Clone, PartialEq, ::prost::Oneof)]
|
|
1521
|
-
pub enum Version {
|
|
1522
|
-
#[prost(message, tag = "1")]
|
|
1523
|
-
V0(GetIdentitiesByPublicKeyHashesResponseV0),
|
|
1524
|
-
}
|
|
1525
|
-
}
|
|
1526
|
-
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
1527
|
-
#[serde(rename_all = "snake_case")]
|
|
1528
|
-
#[derive(::dapi_grpc_macros::VersionedGrpcMessage)]
|
|
1529
|
-
#[grpc_versions(0)]
|
|
1530
|
-
#[derive(::dapi_grpc_macros::Mockable)]
|
|
1531
|
-
#[allow(clippy::derive_partial_eq_without_eq)]
|
|
1532
|
-
#[derive(Clone, PartialEq, ::prost::Message)]
|
|
1533
1433
|
pub struct GetIdentityByPublicKeyHashRequest {
|
|
1534
1434
|
#[prost(oneof = "get_identity_by_public_key_hash_request::Version", tags = "1")]
|
|
1535
1435
|
pub version: ::core::option::Option<
|
|
@@ -2227,6 +2127,43 @@ pub mod get_path_elements_response {
|
|
|
2227
2127
|
V0(GetPathElementsResponseV0),
|
|
2228
2128
|
}
|
|
2229
2129
|
}
|
|
2130
|
+
#[derive(::serde::Serialize, ::serde::Deserialize)]
|
|
2131
|
+
#[serde(rename_all = "snake_case")]
|
|
2132
|
+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
|
|
2133
|
+
#[repr(i32)]
|
|
2134
|
+
pub enum KeyPurpose {
|
|
2135
|
+
Authentication = 0,
|
|
2136
|
+
Encryption = 1,
|
|
2137
|
+
Decryption = 2,
|
|
2138
|
+
Transfer = 3,
|
|
2139
|
+
Voting = 5,
|
|
2140
|
+
}
|
|
2141
|
+
impl KeyPurpose {
|
|
2142
|
+
/// String value of the enum field names used in the ProtoBuf definition.
|
|
2143
|
+
///
|
|
2144
|
+
/// The values are not transformed in any way and thus are considered stable
|
|
2145
|
+
/// (if the ProtoBuf definition does not change) and safe for programmatic use.
|
|
2146
|
+
pub fn as_str_name(&self) -> &'static str {
|
|
2147
|
+
match self {
|
|
2148
|
+
KeyPurpose::Authentication => "AUTHENTICATION",
|
|
2149
|
+
KeyPurpose::Encryption => "ENCRYPTION",
|
|
2150
|
+
KeyPurpose::Decryption => "DECRYPTION",
|
|
2151
|
+
KeyPurpose::Transfer => "TRANSFER",
|
|
2152
|
+
KeyPurpose::Voting => "VOTING",
|
|
2153
|
+
}
|
|
2154
|
+
}
|
|
2155
|
+
/// Creates an enum from field names used in the ProtoBuf definition.
|
|
2156
|
+
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
|
|
2157
|
+
match value {
|
|
2158
|
+
"AUTHENTICATION" => Some(Self::Authentication),
|
|
2159
|
+
"ENCRYPTION" => Some(Self::Encryption),
|
|
2160
|
+
"DECRYPTION" => Some(Self::Decryption),
|
|
2161
|
+
"TRANSFER" => Some(Self::Transfer),
|
|
2162
|
+
"VOTING" => Some(Self::Voting),
|
|
2163
|
+
_ => None,
|
|
2164
|
+
}
|
|
2165
|
+
}
|
|
2166
|
+
}
|
|
2230
2167
|
/// Generated client implementations.
|
|
2231
2168
|
pub mod platform_client {
|
|
2232
2169
|
#![allow(unused_variables, dead_code, missing_docs, clippy::let_unit_value)]
|
|
@@ -2369,11 +2306,11 @@ pub mod platform_client {
|
|
|
2369
2306
|
);
|
|
2370
2307
|
self.inner.unary(req, path, codec).await
|
|
2371
2308
|
}
|
|
2372
|
-
pub async fn
|
|
2309
|
+
pub async fn get_identity_keys(
|
|
2373
2310
|
&mut self,
|
|
2374
|
-
request: impl tonic::IntoRequest<super::
|
|
2311
|
+
request: impl tonic::IntoRequest<super::GetIdentityKeysRequest>,
|
|
2375
2312
|
) -> std::result::Result<
|
|
2376
|
-
tonic::Response<super::
|
|
2313
|
+
tonic::Response<super::GetIdentityKeysResponse>,
|
|
2377
2314
|
tonic::Status,
|
|
2378
2315
|
> {
|
|
2379
2316
|
self.inner
|
|
@@ -2387,23 +2324,23 @@ pub mod platform_client {
|
|
|
2387
2324
|
})?;
|
|
2388
2325
|
let codec = tonic::codec::ProstCodec::default();
|
|
2389
2326
|
let path = http::uri::PathAndQuery::from_static(
|
|
2390
|
-
"/org.dash.platform.dapi.v0.Platform/
|
|
2327
|
+
"/org.dash.platform.dapi.v0.Platform/getIdentityKeys",
|
|
2391
2328
|
);
|
|
2392
2329
|
let mut req = request.into_request();
|
|
2393
2330
|
req.extensions_mut()
|
|
2394
2331
|
.insert(
|
|
2395
2332
|
GrpcMethod::new(
|
|
2396
2333
|
"org.dash.platform.dapi.v0.Platform",
|
|
2397
|
-
"
|
|
2334
|
+
"getIdentityKeys",
|
|
2398
2335
|
),
|
|
2399
2336
|
);
|
|
2400
2337
|
self.inner.unary(req, path, codec).await
|
|
2401
2338
|
}
|
|
2402
|
-
pub async fn
|
|
2339
|
+
pub async fn get_identities_contract_keys(
|
|
2403
2340
|
&mut self,
|
|
2404
|
-
request: impl tonic::IntoRequest<super::
|
|
2341
|
+
request: impl tonic::IntoRequest<super::GetIdentitiesContractKeysRequest>,
|
|
2405
2342
|
) -> std::result::Result<
|
|
2406
|
-
tonic::Response<super::
|
|
2343
|
+
tonic::Response<super::GetIdentitiesContractKeysResponse>,
|
|
2407
2344
|
tonic::Status,
|
|
2408
2345
|
> {
|
|
2409
2346
|
self.inner
|
|
@@ -2417,14 +2354,14 @@ pub mod platform_client {
|
|
|
2417
2354
|
})?;
|
|
2418
2355
|
let codec = tonic::codec::ProstCodec::default();
|
|
2419
2356
|
let path = http::uri::PathAndQuery::from_static(
|
|
2420
|
-
"/org.dash.platform.dapi.v0.Platform/
|
|
2357
|
+
"/org.dash.platform.dapi.v0.Platform/getIdentitiesContractKeys",
|
|
2421
2358
|
);
|
|
2422
2359
|
let mut req = request.into_request();
|
|
2423
2360
|
req.extensions_mut()
|
|
2424
2361
|
.insert(
|
|
2425
2362
|
GrpcMethod::new(
|
|
2426
2363
|
"org.dash.platform.dapi.v0.Platform",
|
|
2427
|
-
"
|
|
2364
|
+
"getIdentitiesContractKeys",
|
|
2428
2365
|
),
|
|
2429
2366
|
);
|
|
2430
2367
|
self.inner.unary(req, path, codec).await
|
|
@@ -2693,38 +2630,6 @@ pub mod platform_client {
|
|
|
2693
2630
|
);
|
|
2694
2631
|
self.inner.unary(req, path, codec).await
|
|
2695
2632
|
}
|
|
2696
|
-
pub async fn get_identities_by_public_key_hashes(
|
|
2697
|
-
&mut self,
|
|
2698
|
-
request: impl tonic::IntoRequest<
|
|
2699
|
-
super::GetIdentitiesByPublicKeyHashesRequest,
|
|
2700
|
-
>,
|
|
2701
|
-
) -> std::result::Result<
|
|
2702
|
-
tonic::Response<super::GetIdentitiesByPublicKeyHashesResponse>,
|
|
2703
|
-
tonic::Status,
|
|
2704
|
-
> {
|
|
2705
|
-
self.inner
|
|
2706
|
-
.ready()
|
|
2707
|
-
.await
|
|
2708
|
-
.map_err(|e| {
|
|
2709
|
-
tonic::Status::new(
|
|
2710
|
-
tonic::Code::Unknown,
|
|
2711
|
-
format!("Service was not ready: {}", e.into()),
|
|
2712
|
-
)
|
|
2713
|
-
})?;
|
|
2714
|
-
let codec = tonic::codec::ProstCodec::default();
|
|
2715
|
-
let path = http::uri::PathAndQuery::from_static(
|
|
2716
|
-
"/org.dash.platform.dapi.v0.Platform/getIdentitiesByPublicKeyHashes",
|
|
2717
|
-
);
|
|
2718
|
-
let mut req = request.into_request();
|
|
2719
|
-
req.extensions_mut()
|
|
2720
|
-
.insert(
|
|
2721
|
-
GrpcMethod::new(
|
|
2722
|
-
"org.dash.platform.dapi.v0.Platform",
|
|
2723
|
-
"getIdentitiesByPublicKeyHashes",
|
|
2724
|
-
),
|
|
2725
|
-
);
|
|
2726
|
-
self.inner.unary(req, path, codec).await
|
|
2727
|
-
}
|
|
2728
2633
|
pub async fn get_identity_by_public_key_hash(
|
|
2729
2634
|
&mut self,
|
|
2730
2635
|
request: impl tonic::IntoRequest<super::GetIdentityByPublicKeyHashRequest>,
|
|
@@ -2962,18 +2867,18 @@ pub mod platform_server {
|
|
|
2962
2867
|
tonic::Response<super::GetIdentityResponse>,
|
|
2963
2868
|
tonic::Status,
|
|
2964
2869
|
>;
|
|
2965
|
-
async fn
|
|
2870
|
+
async fn get_identity_keys(
|
|
2966
2871
|
&self,
|
|
2967
|
-
request: tonic::Request<super::
|
|
2872
|
+
request: tonic::Request<super::GetIdentityKeysRequest>,
|
|
2968
2873
|
) -> std::result::Result<
|
|
2969
|
-
tonic::Response<super::
|
|
2874
|
+
tonic::Response<super::GetIdentityKeysResponse>,
|
|
2970
2875
|
tonic::Status,
|
|
2971
2876
|
>;
|
|
2972
|
-
async fn
|
|
2877
|
+
async fn get_identities_contract_keys(
|
|
2973
2878
|
&self,
|
|
2974
|
-
request: tonic::Request<super::
|
|
2879
|
+
request: tonic::Request<super::GetIdentitiesContractKeysRequest>,
|
|
2975
2880
|
) -> std::result::Result<
|
|
2976
|
-
tonic::Response<super::
|
|
2881
|
+
tonic::Response<super::GetIdentitiesContractKeysResponse>,
|
|
2977
2882
|
tonic::Status,
|
|
2978
2883
|
>;
|
|
2979
2884
|
async fn get_identity_nonce(
|
|
@@ -3039,13 +2944,6 @@ pub mod platform_server {
|
|
|
3039
2944
|
tonic::Response<super::GetDocumentsResponse>,
|
|
3040
2945
|
tonic::Status,
|
|
3041
2946
|
>;
|
|
3042
|
-
async fn get_identities_by_public_key_hashes(
|
|
3043
|
-
&self,
|
|
3044
|
-
request: tonic::Request<super::GetIdentitiesByPublicKeyHashesRequest>,
|
|
3045
|
-
) -> std::result::Result<
|
|
3046
|
-
tonic::Response<super::GetIdentitiesByPublicKeyHashesResponse>,
|
|
3047
|
-
tonic::Status,
|
|
3048
|
-
>;
|
|
3049
2947
|
async fn get_identity_by_public_key_hash(
|
|
3050
2948
|
&self,
|
|
3051
2949
|
request: tonic::Request<super::GetIdentityByPublicKeyHashRequest>,
|
|
@@ -3269,25 +3167,25 @@ pub mod platform_server {
|
|
|
3269
3167
|
};
|
|
3270
3168
|
Box::pin(fut)
|
|
3271
3169
|
}
|
|
3272
|
-
"/org.dash.platform.dapi.v0.Platform/
|
|
3170
|
+
"/org.dash.platform.dapi.v0.Platform/getIdentityKeys" => {
|
|
3273
3171
|
#[allow(non_camel_case_types)]
|
|
3274
|
-
struct
|
|
3172
|
+
struct getIdentityKeysSvc<T: Platform>(pub Arc<T>);
|
|
3275
3173
|
impl<
|
|
3276
3174
|
T: Platform,
|
|
3277
|
-
> tonic::server::UnaryService<super::
|
|
3278
|
-
for
|
|
3279
|
-
type Response = super::
|
|
3175
|
+
> tonic::server::UnaryService<super::GetIdentityKeysRequest>
|
|
3176
|
+
for getIdentityKeysSvc<T> {
|
|
3177
|
+
type Response = super::GetIdentityKeysResponse;
|
|
3280
3178
|
type Future = BoxFuture<
|
|
3281
3179
|
tonic::Response<Self::Response>,
|
|
3282
3180
|
tonic::Status,
|
|
3283
3181
|
>;
|
|
3284
3182
|
fn call(
|
|
3285
3183
|
&mut self,
|
|
3286
|
-
request: tonic::Request<super::
|
|
3184
|
+
request: tonic::Request<super::GetIdentityKeysRequest>,
|
|
3287
3185
|
) -> Self::Future {
|
|
3288
3186
|
let inner = Arc::clone(&self.0);
|
|
3289
3187
|
let fut = async move {
|
|
3290
|
-
(*inner).
|
|
3188
|
+
(*inner).get_identity_keys(request).await
|
|
3291
3189
|
};
|
|
3292
3190
|
Box::pin(fut)
|
|
3293
3191
|
}
|
|
@@ -3299,7 +3197,7 @@ pub mod platform_server {
|
|
|
3299
3197
|
let inner = self.inner.clone();
|
|
3300
3198
|
let fut = async move {
|
|
3301
3199
|
let inner = inner.0;
|
|
3302
|
-
let method =
|
|
3200
|
+
let method = getIdentityKeysSvc(inner);
|
|
3303
3201
|
let codec = tonic::codec::ProstCodec::default();
|
|
3304
3202
|
let mut grpc = tonic::server::Grpc::new(codec)
|
|
3305
3203
|
.apply_compression_config(
|
|
@@ -3315,25 +3213,28 @@ pub mod platform_server {
|
|
|
3315
3213
|
};
|
|
3316
3214
|
Box::pin(fut)
|
|
3317
3215
|
}
|
|
3318
|
-
"/org.dash.platform.dapi.v0.Platform/
|
|
3216
|
+
"/org.dash.platform.dapi.v0.Platform/getIdentitiesContractKeys" => {
|
|
3319
3217
|
#[allow(non_camel_case_types)]
|
|
3320
|
-
struct
|
|
3218
|
+
struct getIdentitiesContractKeysSvc<T: Platform>(pub Arc<T>);
|
|
3321
3219
|
impl<
|
|
3322
3220
|
T: Platform,
|
|
3323
|
-
> tonic::server::UnaryService<
|
|
3324
|
-
|
|
3325
|
-
|
|
3221
|
+
> tonic::server::UnaryService<
|
|
3222
|
+
super::GetIdentitiesContractKeysRequest,
|
|
3223
|
+
> for getIdentitiesContractKeysSvc<T> {
|
|
3224
|
+
type Response = super::GetIdentitiesContractKeysResponse;
|
|
3326
3225
|
type Future = BoxFuture<
|
|
3327
3226
|
tonic::Response<Self::Response>,
|
|
3328
3227
|
tonic::Status,
|
|
3329
3228
|
>;
|
|
3330
3229
|
fn call(
|
|
3331
3230
|
&mut self,
|
|
3332
|
-
request: tonic::Request<
|
|
3231
|
+
request: tonic::Request<
|
|
3232
|
+
super::GetIdentitiesContractKeysRequest,
|
|
3233
|
+
>,
|
|
3333
3234
|
) -> Self::Future {
|
|
3334
3235
|
let inner = Arc::clone(&self.0);
|
|
3335
3236
|
let fut = async move {
|
|
3336
|
-
(*inner).
|
|
3237
|
+
(*inner).get_identities_contract_keys(request).await
|
|
3337
3238
|
};
|
|
3338
3239
|
Box::pin(fut)
|
|
3339
3240
|
}
|
|
@@ -3345,7 +3246,7 @@ pub mod platform_server {
|
|
|
3345
3246
|
let inner = self.inner.clone();
|
|
3346
3247
|
let fut = async move {
|
|
3347
3248
|
let inner = inner.0;
|
|
3348
|
-
let method =
|
|
3249
|
+
let method = getIdentitiesContractKeysSvc(inner);
|
|
3349
3250
|
let codec = tonic::codec::ProstCodec::default();
|
|
3350
3251
|
let mut grpc = tonic::server::Grpc::new(codec)
|
|
3351
3252
|
.apply_compression_config(
|
|
@@ -3778,55 +3679,6 @@ pub mod platform_server {
|
|
|
3778
3679
|
};
|
|
3779
3680
|
Box::pin(fut)
|
|
3780
3681
|
}
|
|
3781
|
-
"/org.dash.platform.dapi.v0.Platform/getIdentitiesByPublicKeyHashes" => {
|
|
3782
|
-
#[allow(non_camel_case_types)]
|
|
3783
|
-
struct getIdentitiesByPublicKeyHashesSvc<T: Platform>(pub Arc<T>);
|
|
3784
|
-
impl<
|
|
3785
|
-
T: Platform,
|
|
3786
|
-
> tonic::server::UnaryService<
|
|
3787
|
-
super::GetIdentitiesByPublicKeyHashesRequest,
|
|
3788
|
-
> for getIdentitiesByPublicKeyHashesSvc<T> {
|
|
3789
|
-
type Response = super::GetIdentitiesByPublicKeyHashesResponse;
|
|
3790
|
-
type Future = BoxFuture<
|
|
3791
|
-
tonic::Response<Self::Response>,
|
|
3792
|
-
tonic::Status,
|
|
3793
|
-
>;
|
|
3794
|
-
fn call(
|
|
3795
|
-
&mut self,
|
|
3796
|
-
request: tonic::Request<
|
|
3797
|
-
super::GetIdentitiesByPublicKeyHashesRequest,
|
|
3798
|
-
>,
|
|
3799
|
-
) -> Self::Future {
|
|
3800
|
-
let inner = Arc::clone(&self.0);
|
|
3801
|
-
let fut = async move {
|
|
3802
|
-
(*inner).get_identities_by_public_key_hashes(request).await
|
|
3803
|
-
};
|
|
3804
|
-
Box::pin(fut)
|
|
3805
|
-
}
|
|
3806
|
-
}
|
|
3807
|
-
let accept_compression_encodings = self.accept_compression_encodings;
|
|
3808
|
-
let send_compression_encodings = self.send_compression_encodings;
|
|
3809
|
-
let max_decoding_message_size = self.max_decoding_message_size;
|
|
3810
|
-
let max_encoding_message_size = self.max_encoding_message_size;
|
|
3811
|
-
let inner = self.inner.clone();
|
|
3812
|
-
let fut = async move {
|
|
3813
|
-
let inner = inner.0;
|
|
3814
|
-
let method = getIdentitiesByPublicKeyHashesSvc(inner);
|
|
3815
|
-
let codec = tonic::codec::ProstCodec::default();
|
|
3816
|
-
let mut grpc = tonic::server::Grpc::new(codec)
|
|
3817
|
-
.apply_compression_config(
|
|
3818
|
-
accept_compression_encodings,
|
|
3819
|
-
send_compression_encodings,
|
|
3820
|
-
)
|
|
3821
|
-
.apply_max_message_size_config(
|
|
3822
|
-
max_decoding_message_size,
|
|
3823
|
-
max_encoding_message_size,
|
|
3824
|
-
);
|
|
3825
|
-
let res = grpc.unary(method, req).await;
|
|
3826
|
-
Ok(res)
|
|
3827
|
-
};
|
|
3828
|
-
Box::pin(fut)
|
|
3829
|
-
}
|
|
3830
3682
|
"/org.dash.platform.dapi.v0.Platform/getIdentityByPublicKeyHash" => {
|
|
3831
3683
|
#[allow(non_camel_case_types)]
|
|
3832
3684
|
struct getIdentityByPublicKeyHashSvc<T: Platform>(pub Arc<T>);
|