@dashevo/dapi-grpc 3.0.0-dev.7 → 3.0.0-dev.9

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.
@@ -5923,6 +5923,46 @@ pub struct AddressInfoEntries {
5923
5923
  }
5924
5924
  #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
5925
5925
  #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
5926
+ #[derive(::dash_platform_macros::Mockable)]
5927
+ #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5928
+ pub struct AddressBalanceChange {
5929
+ #[prost(bytes = "vec", tag = "1")]
5930
+ pub address: ::prost::alloc::vec::Vec<u8>,
5931
+ #[prost(oneof = "address_balance_change::Operation", tags = "2, 3")]
5932
+ pub operation: ::core::option::Option<address_balance_change::Operation>,
5933
+ }
5934
+ /// Nested message and enum types in `AddressBalanceChange`.
5935
+ pub mod address_balance_change {
5936
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
5937
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
5938
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
5939
+ pub enum Operation {
5940
+ #[prost(uint64, tag = "2")]
5941
+ SetBalance(u64),
5942
+ #[prost(uint64, tag = "3")]
5943
+ AddToBalance(u64),
5944
+ }
5945
+ }
5946
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
5947
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
5948
+ #[derive(::dash_platform_macros::Mockable)]
5949
+ #[derive(Clone, PartialEq, ::prost::Message)]
5950
+ pub struct BlockAddressBalanceChanges {
5951
+ #[prost(uint64, tag = "1")]
5952
+ pub block_height: u64,
5953
+ #[prost(message, repeated, tag = "2")]
5954
+ pub changes: ::prost::alloc::vec::Vec<AddressBalanceChange>,
5955
+ }
5956
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
5957
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
5958
+ #[derive(::dash_platform_macros::Mockable)]
5959
+ #[derive(Clone, PartialEq, ::prost::Message)]
5960
+ pub struct AddressBalanceUpdateEntries {
5961
+ #[prost(message, repeated, tag = "1")]
5962
+ pub block_changes: ::prost::alloc::vec::Vec<BlockAddressBalanceChanges>,
5963
+ }
5964
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
5965
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
5926
5966
  #[derive(
5927
5967
  ::dash_platform_macros::VersionedGrpcMessage,
5928
5968
  ::dash_platform_macros::VersionedGrpcResponse
@@ -6165,6 +6205,204 @@ pub mod get_addresses_branch_state_response {
6165
6205
  }
6166
6206
  #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6167
6207
  #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6208
+ #[derive(::dash_platform_macros::VersionedGrpcMessage)]
6209
+ #[grpc_versions(0)]
6210
+ #[derive(::dash_platform_macros::Mockable)]
6211
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6212
+ pub struct GetRecentAddressBalanceChangesRequest {
6213
+ #[prost(oneof = "get_recent_address_balance_changes_request::Version", tags = "1")]
6214
+ pub version: ::core::option::Option<
6215
+ get_recent_address_balance_changes_request::Version,
6216
+ >,
6217
+ }
6218
+ /// Nested message and enum types in `GetRecentAddressBalanceChangesRequest`.
6219
+ pub mod get_recent_address_balance_changes_request {
6220
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6221
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6222
+ #[derive(::dash_platform_macros::Mockable)]
6223
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6224
+ pub struct GetRecentAddressBalanceChangesRequestV0 {
6225
+ #[prost(uint64, tag = "1")]
6226
+ pub start_height: u64,
6227
+ #[prost(bool, tag = "2")]
6228
+ pub prove: bool,
6229
+ }
6230
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6231
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6232
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
6233
+ pub enum Version {
6234
+ #[prost(message, tag = "1")]
6235
+ V0(GetRecentAddressBalanceChangesRequestV0),
6236
+ }
6237
+ }
6238
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6239
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6240
+ #[derive(
6241
+ ::dash_platform_macros::VersionedGrpcMessage,
6242
+ ::dash_platform_macros::VersionedGrpcResponse
6243
+ )]
6244
+ #[grpc_versions(0)]
6245
+ #[derive(::dash_platform_macros::Mockable)]
6246
+ #[derive(Clone, PartialEq, ::prost::Message)]
6247
+ pub struct GetRecentAddressBalanceChangesResponse {
6248
+ #[prost(oneof = "get_recent_address_balance_changes_response::Version", tags = "1")]
6249
+ pub version: ::core::option::Option<
6250
+ get_recent_address_balance_changes_response::Version,
6251
+ >,
6252
+ }
6253
+ /// Nested message and enum types in `GetRecentAddressBalanceChangesResponse`.
6254
+ pub mod get_recent_address_balance_changes_response {
6255
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6256
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6257
+ #[derive(::dash_platform_macros::Mockable)]
6258
+ #[derive(Clone, PartialEq, ::prost::Message)]
6259
+ pub struct GetRecentAddressBalanceChangesResponseV0 {
6260
+ #[prost(message, optional, tag = "3")]
6261
+ pub metadata: ::core::option::Option<super::ResponseMetadata>,
6262
+ #[prost(
6263
+ oneof = "get_recent_address_balance_changes_response_v0::Result",
6264
+ tags = "1, 2"
6265
+ )]
6266
+ pub result: ::core::option::Option<
6267
+ get_recent_address_balance_changes_response_v0::Result,
6268
+ >,
6269
+ }
6270
+ /// Nested message and enum types in `GetRecentAddressBalanceChangesResponseV0`.
6271
+ pub mod get_recent_address_balance_changes_response_v0 {
6272
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6273
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6274
+ #[derive(Clone, PartialEq, ::prost::Oneof)]
6275
+ pub enum Result {
6276
+ #[prost(message, tag = "1")]
6277
+ AddressBalanceUpdateEntries(super::super::AddressBalanceUpdateEntries),
6278
+ #[prost(message, tag = "2")]
6279
+ Proof(super::super::Proof),
6280
+ }
6281
+ }
6282
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6283
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6284
+ #[derive(Clone, PartialEq, ::prost::Oneof)]
6285
+ pub enum Version {
6286
+ #[prost(message, tag = "1")]
6287
+ V0(GetRecentAddressBalanceChangesResponseV0),
6288
+ }
6289
+ }
6290
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6291
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6292
+ #[derive(::dash_platform_macros::Mockable)]
6293
+ #[derive(Clone, PartialEq, ::prost::Message)]
6294
+ pub struct CompactedBlockAddressBalanceChanges {
6295
+ #[prost(uint64, tag = "1")]
6296
+ pub start_block_height: u64,
6297
+ #[prost(uint64, tag = "2")]
6298
+ pub end_block_height: u64,
6299
+ #[prost(message, repeated, tag = "3")]
6300
+ pub changes: ::prost::alloc::vec::Vec<AddressBalanceChange>,
6301
+ }
6302
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6303
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6304
+ #[derive(::dash_platform_macros::Mockable)]
6305
+ #[derive(Clone, PartialEq, ::prost::Message)]
6306
+ pub struct CompactedAddressBalanceUpdateEntries {
6307
+ #[prost(message, repeated, tag = "1")]
6308
+ pub compacted_block_changes: ::prost::alloc::vec::Vec<
6309
+ CompactedBlockAddressBalanceChanges,
6310
+ >,
6311
+ }
6312
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6313
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6314
+ #[derive(::dash_platform_macros::VersionedGrpcMessage)]
6315
+ #[grpc_versions(0)]
6316
+ #[derive(::dash_platform_macros::Mockable)]
6317
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6318
+ pub struct GetRecentCompactedAddressBalanceChangesRequest {
6319
+ #[prost(
6320
+ oneof = "get_recent_compacted_address_balance_changes_request::Version",
6321
+ tags = "1"
6322
+ )]
6323
+ pub version: ::core::option::Option<
6324
+ get_recent_compacted_address_balance_changes_request::Version,
6325
+ >,
6326
+ }
6327
+ /// Nested message and enum types in `GetRecentCompactedAddressBalanceChangesRequest`.
6328
+ pub mod get_recent_compacted_address_balance_changes_request {
6329
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6330
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6331
+ #[derive(::dash_platform_macros::Mockable)]
6332
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Message)]
6333
+ pub struct GetRecentCompactedAddressBalanceChangesRequestV0 {
6334
+ #[prost(uint64, tag = "1")]
6335
+ pub start_block_height: u64,
6336
+ #[prost(bool, tag = "2")]
6337
+ pub prove: bool,
6338
+ }
6339
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6340
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6341
+ #[derive(Clone, Copy, PartialEq, Eq, Hash, ::prost::Oneof)]
6342
+ pub enum Version {
6343
+ #[prost(message, tag = "1")]
6344
+ V0(GetRecentCompactedAddressBalanceChangesRequestV0),
6345
+ }
6346
+ }
6347
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6348
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6349
+ #[derive(
6350
+ ::dash_platform_macros::VersionedGrpcMessage,
6351
+ ::dash_platform_macros::VersionedGrpcResponse
6352
+ )]
6353
+ #[grpc_versions(0)]
6354
+ #[derive(::dash_platform_macros::Mockable)]
6355
+ #[derive(Clone, PartialEq, ::prost::Message)]
6356
+ pub struct GetRecentCompactedAddressBalanceChangesResponse {
6357
+ #[prost(
6358
+ oneof = "get_recent_compacted_address_balance_changes_response::Version",
6359
+ tags = "1"
6360
+ )]
6361
+ pub version: ::core::option::Option<
6362
+ get_recent_compacted_address_balance_changes_response::Version,
6363
+ >,
6364
+ }
6365
+ /// Nested message and enum types in `GetRecentCompactedAddressBalanceChangesResponse`.
6366
+ pub mod get_recent_compacted_address_balance_changes_response {
6367
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6368
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6369
+ #[derive(::dash_platform_macros::Mockable)]
6370
+ #[derive(Clone, PartialEq, ::prost::Message)]
6371
+ pub struct GetRecentCompactedAddressBalanceChangesResponseV0 {
6372
+ #[prost(message, optional, tag = "3")]
6373
+ pub metadata: ::core::option::Option<super::ResponseMetadata>,
6374
+ #[prost(
6375
+ oneof = "get_recent_compacted_address_balance_changes_response_v0::Result",
6376
+ tags = "1, 2"
6377
+ )]
6378
+ pub result: ::core::option::Option<
6379
+ get_recent_compacted_address_balance_changes_response_v0::Result,
6380
+ >,
6381
+ }
6382
+ /// Nested message and enum types in `GetRecentCompactedAddressBalanceChangesResponseV0`.
6383
+ pub mod get_recent_compacted_address_balance_changes_response_v0 {
6384
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6385
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6386
+ #[derive(Clone, PartialEq, ::prost::Oneof)]
6387
+ pub enum Result {
6388
+ #[prost(message, tag = "1")]
6389
+ CompactedAddressBalanceUpdateEntries(
6390
+ super::super::CompactedAddressBalanceUpdateEntries,
6391
+ ),
6392
+ #[prost(message, tag = "2")]
6393
+ Proof(super::super::Proof),
6394
+ }
6395
+ }
6396
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6397
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6398
+ #[derive(Clone, PartialEq, ::prost::Oneof)]
6399
+ pub enum Version {
6400
+ #[prost(message, tag = "1")]
6401
+ V0(GetRecentCompactedAddressBalanceChangesResponseV0),
6402
+ }
6403
+ }
6404
+ #[cfg_attr(feature = "serde", derive(::serde::Serialize, ::serde::Deserialize))]
6405
+ #[cfg_attr(feature = "serde", serde(rename_all = "snake_case"))]
6168
6406
  #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
6169
6407
  #[repr(i32)]
6170
6408
  pub enum KeyPurpose {
@@ -7772,5 +8010,67 @@ pub mod platform_client {
7772
8010
  );
7773
8011
  self.inner.unary(req, path, codec).await
7774
8012
  }
8013
+ pub async fn get_recent_address_balance_changes(
8014
+ &mut self,
8015
+ request: impl tonic::IntoRequest<
8016
+ super::GetRecentAddressBalanceChangesRequest,
8017
+ >,
8018
+ ) -> std::result::Result<
8019
+ tonic::Response<super::GetRecentAddressBalanceChangesResponse>,
8020
+ tonic::Status,
8021
+ > {
8022
+ self.inner
8023
+ .ready()
8024
+ .await
8025
+ .map_err(|e| {
8026
+ tonic::Status::unknown(
8027
+ format!("Service was not ready: {}", e.into()),
8028
+ )
8029
+ })?;
8030
+ let codec = tonic_prost::ProstCodec::default();
8031
+ let path = http::uri::PathAndQuery::from_static(
8032
+ "/org.dash.platform.dapi.v0.Platform/getRecentAddressBalanceChanges",
8033
+ );
8034
+ let mut req = request.into_request();
8035
+ req.extensions_mut()
8036
+ .insert(
8037
+ GrpcMethod::new(
8038
+ "org.dash.platform.dapi.v0.Platform",
8039
+ "getRecentAddressBalanceChanges",
8040
+ ),
8041
+ );
8042
+ self.inner.unary(req, path, codec).await
8043
+ }
8044
+ pub async fn get_recent_compacted_address_balance_changes(
8045
+ &mut self,
8046
+ request: impl tonic::IntoRequest<
8047
+ super::GetRecentCompactedAddressBalanceChangesRequest,
8048
+ >,
8049
+ ) -> std::result::Result<
8050
+ tonic::Response<super::GetRecentCompactedAddressBalanceChangesResponse>,
8051
+ tonic::Status,
8052
+ > {
8053
+ self.inner
8054
+ .ready()
8055
+ .await
8056
+ .map_err(|e| {
8057
+ tonic::Status::unknown(
8058
+ format!("Service was not ready: {}", e.into()),
8059
+ )
8060
+ })?;
8061
+ let codec = tonic_prost::ProstCodec::default();
8062
+ let path = http::uri::PathAndQuery::from_static(
8063
+ "/org.dash.platform.dapi.v0.Platform/getRecentCompactedAddressBalanceChanges",
8064
+ );
8065
+ let mut req = request.into_request();
8066
+ req.extensions_mut()
8067
+ .insert(
8068
+ GrpcMethod::new(
8069
+ "org.dash.platform.dapi.v0.Platform",
8070
+ "getRecentCompactedAddressBalanceChanges",
8071
+ ),
8072
+ );
8073
+ self.inner.unary(req, path, codec).await
8074
+ }
7775
8075
  }
7776
8076
  }