// This file is @generated by prost-build.
/// Params struct
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct Params {
    #[prost(uint64, tag = "1")]
    pub microtx_fee_basis_points: u64,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct GenesisState {
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
}
/// MsgMicrotx A Msg used to send funds from one Althea network wallet to another,
/// via an automated device. Facilitates Liquid Infrastructure by automatically
/// redirecting funds received by Liquid Infrastructure beyond configured amounts to the EVM.
/// SENDER The account sending funds to receiver, must also be the signer of the
/// message
/// RECEIVER The account receiving funds from sender
/// AMOUNTS The tokens and their quantities which should be transferred, these
/// must be Cosmos coins registered as ERC20s, or the Cosmos representation of ERC20s
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgMicrotx {
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub receiver: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "3")]
    pub amount: ::core::option::Option<cosmos_sdk_proto::cosmos::base::v1beta1::Coin>,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct MsgMicrotxResponse {}
/// A type for the block's event log, every successful Microtx must create one of
/// these in the event log
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventMicrotx {
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub receiver: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "3")]
    pub amounts: ::prost::alloc::vec::Vec<
        cosmos_sdk_proto::cosmos::base::v1beta1::Coin,
    >,
}
/// A type for the block's event log, Microtx fees may be collected out-of-band and so
/// this event may be emitted in an AnteHandler or during the Msg handler
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventMicrotxFeeCollected {
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
    #[prost(message, repeated, tag = "2")]
    pub fee: ::prost::alloc::vec::Vec<cosmos_sdk_proto::cosmos::base::v1beta1::Coin>,
}
/// A type for the block's event log recording when a Liquid Infrastructure account
/// has a received balance redirected to its registered LiquidInfrastructureNFT
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventBalanceRedirect {
    #[prost(string, tag = "1")]
    pub account: ::prost::alloc::string::String,
    #[prost(message, optional, tag = "2")]
    pub amount: ::core::option::Option<cosmos_sdk_proto::cosmos::base::v1beta1::Coin>,
}
/// Records critical information about a Liquid Infrastructure Account
/// ACCOUNT The bech32 address of the liquid infrastructure account
/// OWNER The bech32 address of the account now in control of the liquid infrastructure
/// NFT_ADDRESS The EVM address of the token contract in control of the liquid infrastructure account's accrued profits
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct LiquidInfrastructureAccount {
    #[prost(string, tag = "1")]
    pub owner: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub account: ::prost::alloc::string::String,
    #[prost(string, tag = "3")]
    pub nft_address: ::prost::alloc::string::String,
}
/// MsgLiquify Converts the sender's account into a piece of Liquid Infrastructure,
/// by creating a Non-fungible Token (NFT) within the Althea L1 EVM which will control all balances
/// held by the Liquid Infrastructure Account (beyond a configurable threshold).
/// The liquid infrastructure account itself will be the initial owner of the NFT,
/// and must transfer control through the EVM NFT contract
/// SENDER The bech32 address of the account to liquify, must also be the signer of the message
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgLiquify {
    #[prost(string, tag = "1")]
    pub sender: ::prost::alloc::string::String,
}
/// MsgLiquifyResponse potentially returns useful information from the liquification of an account
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct MsgLiquifyResponse {
    #[prost(message, optional, tag = "1")]
    pub account: ::core::option::Option<LiquidInfrastructureAccount>,
}
/// A type for the block's event log, every successful MsgLiquify must create one of
/// these in the event log
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct EventAccountLiquified {
    #[prost(string, tag = "1")]
    pub owned: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub nft_address: ::prost::alloc::string::String,
}
/// Generated client implementations.
pub mod msg_client {
    #![allow(
        unused_variables,
        dead_code,
        missing_docs,
        clippy::wildcard_imports,
        clippy::let_unit_value,
    )]
    use tonic::codegen::*;
    use tonic::codegen::http::Uri;
    /// Msg defines the state transitions possible within microtx
    #[derive(Debug, Clone)]
    pub struct MsgClient<T> {
        inner: tonic::client::Grpc<T>,
    }
    impl MsgClient<tonic::transport::Channel> {
        /// Attempt to create a new client by connecting to a given endpoint.
        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
        where
            D: TryInto<tonic::transport::Endpoint>,
            D::Error: Into<StdError>,
        {
            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
            Ok(Self::new(conn))
        }
    }
    impl<T> MsgClient<T>
    where
        T: tonic::client::GrpcService<tonic::body::BoxBody>,
        T::Error: Into<StdError>,
        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
    {
        pub fn new(inner: T) -> Self {
            let inner = tonic::client::Grpc::new(inner);
            Self { inner }
        }
        pub fn with_origin(inner: T, origin: Uri) -> Self {
            let inner = tonic::client::Grpc::with_origin(inner, origin);
            Self { inner }
        }
        pub fn with_interceptor<F>(
            inner: T,
            interceptor: F,
        ) -> MsgClient<InterceptedService<T, F>>
        where
            F: tonic::service::Interceptor,
            T::ResponseBody: Default,
            T: tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
                Response = http::Response<
                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
                >,
            >,
            <T as tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
        {
            MsgClient::new(InterceptedService::new(inner, interceptor))
        }
        /// Compress requests with the given encoding.
        ///
        /// This requires the server to support it otherwise it might respond with an
        /// error.
        #[must_use]
        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.send_compressed(encoding);
            self
        }
        /// Enable decompressing responses.
        #[must_use]
        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.accept_compressed(encoding);
            self
        }
        /// Limits the maximum size of a decoded message.
        ///
        /// Default: `4MB`
        #[must_use]
        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_decoding_message_size(limit);
            self
        }
        /// Limits the maximum size of an encoded message.
        ///
        /// Default: `usize::MAX`
        #[must_use]
        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_encoding_message_size(limit);
            self
        }
        /// The Microtx service handles payments to Althea accounts
        pub async fn microtx(
            &mut self,
            request: impl tonic::IntoRequest<super::MsgMicrotx>,
        ) -> std::result::Result<
            tonic::Response<super::MsgMicrotxResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Msg/Microtx",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Msg", "Microtx"));
            self.inner.unary(req, path, codec).await
        }
        /// The Liquify service converts an account into a piece of Liquid Infrastructure
        pub async fn liquify(
            &mut self,
            request: impl tonic::IntoRequest<super::MsgLiquify>,
        ) -> std::result::Result<
            tonic::Response<super::MsgLiquifyResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Msg/Liquify",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Msg", "Liquify"));
            self.inner.unary(req, path, codec).await
        }
    }
}
/// Query the current microtx params
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryParamsRequest {}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryParamsResponse {
    #[prost(message, optional, tag = "1")]
    pub params: ::core::option::Option<Params>,
}
/// Query the additional fee paid on MsgMicrotx, determined by governance
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryMicrotxFeeRequest {
    #[prost(uint64, tag = "1")]
    pub amount: u64,
}
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryMicrotxFeeResponse {
    #[prost(uint64, tag = "1")]
    pub fee_amount: u64,
}
/// Query the Liquid Infrastructure accounts known to the module
#[derive(Clone, Copy, PartialEq, ::prost::Message)]
pub struct QueryLiquidAccountsRequest {}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryLiquidAccountsResponse {
    #[prost(message, repeated, tag = "1")]
    pub accounts: ::prost::alloc::vec::Vec<LiquidInfrastructureAccount>,
}
/// Query for info about one particular Liquid Infrastructure account
/// OWNER if a bech32 address is provided, potenitally many accounts will be returned
/// ACCOUNT if a bech32 address is provided, the owner and nft contract address will be returned
/// NFT if a EVM address is provided and happens to be a LiquidInfrastructureNFT contract, the owner and account will be returned
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryLiquidAccountRequest {
    #[prost(string, tag = "1")]
    pub owner: ::prost::alloc::string::String,
    #[prost(string, tag = "2")]
    pub account: ::prost::alloc::string::String,
    #[prost(string, tag = "3")]
    pub nft: ::prost::alloc::string::String,
}
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct QueryLiquidAccountResponse {
    #[prost(message, repeated, tag = "1")]
    pub accounts: ::prost::alloc::vec::Vec<LiquidInfrastructureAccount>,
}
/// Generated client implementations.
pub mod query_client {
    #![allow(
        unused_variables,
        dead_code,
        missing_docs,
        clippy::wildcard_imports,
        clippy::let_unit_value,
    )]
    use tonic::codegen::*;
    use tonic::codegen::http::Uri;
    /// Query defines the possible queries to make of the microtx module
    #[derive(Debug, Clone)]
    pub struct QueryClient<T> {
        inner: tonic::client::Grpc<T>,
    }
    impl QueryClient<tonic::transport::Channel> {
        /// Attempt to create a new client by connecting to a given endpoint.
        pub async fn connect<D>(dst: D) -> Result<Self, tonic::transport::Error>
        where
            D: TryInto<tonic::transport::Endpoint>,
            D::Error: Into<StdError>,
        {
            let conn = tonic::transport::Endpoint::new(dst)?.connect().await?;
            Ok(Self::new(conn))
        }
    }
    impl<T> QueryClient<T>
    where
        T: tonic::client::GrpcService<tonic::body::BoxBody>,
        T::Error: Into<StdError>,
        T::ResponseBody: Body<Data = Bytes> + std::marker::Send + 'static,
        <T::ResponseBody as Body>::Error: Into<StdError> + std::marker::Send,
    {
        pub fn new(inner: T) -> Self {
            let inner = tonic::client::Grpc::new(inner);
            Self { inner }
        }
        pub fn with_origin(inner: T, origin: Uri) -> Self {
            let inner = tonic::client::Grpc::with_origin(inner, origin);
            Self { inner }
        }
        pub fn with_interceptor<F>(
            inner: T,
            interceptor: F,
        ) -> QueryClient<InterceptedService<T, F>>
        where
            F: tonic::service::Interceptor,
            T::ResponseBody: Default,
            T: tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
                Response = http::Response<
                    <T as tonic::client::GrpcService<tonic::body::BoxBody>>::ResponseBody,
                >,
            >,
            <T as tonic::codegen::Service<
                http::Request<tonic::body::BoxBody>,
            >>::Error: Into<StdError> + std::marker::Send + std::marker::Sync,
        {
            QueryClient::new(InterceptedService::new(inner, interceptor))
        }
        /// Compress requests with the given encoding.
        ///
        /// This requires the server to support it otherwise it might respond with an
        /// error.
        #[must_use]
        pub fn send_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.send_compressed(encoding);
            self
        }
        /// Enable decompressing responses.
        #[must_use]
        pub fn accept_compressed(mut self, encoding: CompressionEncoding) -> Self {
            self.inner = self.inner.accept_compressed(encoding);
            self
        }
        /// Limits the maximum size of a decoded message.
        ///
        /// Default: `4MB`
        #[must_use]
        pub fn max_decoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_decoding_message_size(limit);
            self
        }
        /// Limits the maximum size of an encoded message.
        ///
        /// Default: `usize::MAX`
        #[must_use]
        pub fn max_encoding_message_size(mut self, limit: usize) -> Self {
            self.inner = self.inner.max_encoding_message_size(limit);
            self
        }
        /// Query the current microtx params
        pub async fn params(
            &mut self,
            request: impl tonic::IntoRequest<super::QueryParamsRequest>,
        ) -> std::result::Result<
            tonic::Response<super::QueryParamsResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Query/Params",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Query", "Params"));
            self.inner.unary(req, path, codec).await
        }
        /// Get an authoritative fee amount which must be paid on Microtx
        pub async fn microtx_fee(
            &mut self,
            request: impl tonic::IntoRequest<super::QueryMicrotxFeeRequest>,
        ) -> std::result::Result<
            tonic::Response<super::QueryMicrotxFeeResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Query/MicrotxFee",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Query", "MicrotxFee"));
            self.inner.unary(req, path, codec).await
        }
        /// Get all of the Liquid Infrastructure accounts known to the module
        pub async fn liquid_accounts(
            &mut self,
            request: impl tonic::IntoRequest<super::QueryLiquidAccountsRequest>,
        ) -> std::result::Result<
            tonic::Response<super::QueryLiquidAccountsResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Query/LiquidAccounts",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Query", "LiquidAccounts"));
            self.inner.unary(req, path, codec).await
        }
        /// Get info about one particular Liquid Infrastructure account by owner, bech32 address, or nft address
        /// Make HTTP GET requests like:
        /// * `GET /microtx/v1/liquid_account?owner=althea1...`
        /// * `GET /microtx/v1/liquid_account?owner=0xABCDE...`
        /// * `GET /microtx/v1/liquid_account?account=althea1...`
        /// * `GET /microtx/v1/liquid_account?nft=0xABCDE...`
        pub async fn liquid_account(
            &mut self,
            request: impl tonic::IntoRequest<super::QueryLiquidAccountRequest>,
        ) -> std::result::Result<
            tonic::Response<super::QueryLiquidAccountResponse>,
            tonic::Status,
        > {
            self.inner
                .ready()
                .await
                .map_err(|e| {
                    tonic::Status::unknown(
                        format!("Service was not ready: {}", e.into()),
                    )
                })?;
            let codec = tonic::codec::ProstCodec::default();
            let path = http::uri::PathAndQuery::from_static(
                "/althea.microtx.v1.Query/LiquidAccount",
            );
            let mut req = request.into_request();
            req.extensions_mut()
                .insert(GrpcMethod::new("althea.microtx.v1.Query", "LiquidAccount"));
            self.inner.unary(req, path, codec).await
        }
    }
}
