github.com/Finschia/finschia-sdk@v0.49.1/proto/cosmos/bank/v1beta1/query.proto (about)

     1  syntax = "proto3";
     2  package cosmos.bank.v1beta1;
     3  
     4  import "cosmos/base/query/v1beta1/pagination.proto";
     5  import "gogoproto/gogo.proto";
     6  import "google/api/annotations.proto";
     7  import "cosmos/base/v1beta1/coin.proto";
     8  import "cosmos/bank/v1beta1/bank.proto";
     9  
    10  option go_package = "github.com/Finschia/finschia-sdk/x/bank/types";
    11  
    12  // Query defines the gRPC querier service.
    13  service Query {
    14    // Balance queries the balance of a single coin for a single account.
    15    rpc Balance(QueryBalanceRequest) returns (QueryBalanceResponse) {
    16      option (google.api.http).get = "/cosmos/bank/v1beta1/balances/{address}/by_denom";
    17    }
    18  
    19    // AllBalances queries the balance of all coins for a single account.
    20    rpc AllBalances(QueryAllBalancesRequest) returns (QueryAllBalancesResponse) {
    21      option (google.api.http).get = "/cosmos/bank/v1beta1/balances/{address}";
    22    }
    23  
    24    // SpendableBalances queries the spenable balance of all coins for a single
    25    // account.
    26    rpc SpendableBalances(QuerySpendableBalancesRequest) returns (QuerySpendableBalancesResponse) {
    27      option (google.api.http).get = "/cosmos/bank/v1beta1/spendable_balances/{address}";
    28    }
    29  
    30    // TotalSupply queries the total supply of all coins.
    31    rpc TotalSupply(QueryTotalSupplyRequest) returns (QueryTotalSupplyResponse) {
    32      option (google.api.http).get = "/cosmos/bank/v1beta1/supply";
    33    }
    34  
    35    // SupplyOf queries the supply of a single coin.
    36    rpc SupplyOf(QuerySupplyOfRequest) returns (QuerySupplyOfResponse) {
    37      option (google.api.http).get = "/cosmos/bank/v1beta1/supply/{denom}";
    38    }
    39  
    40    // Params queries the parameters of x/bank module.
    41    rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
    42      option (google.api.http).get = "/cosmos/bank/v1beta1/params";
    43    }
    44  
    45    // DenomsMetadata queries the client metadata of a given coin denomination.
    46    rpc DenomMetadata(QueryDenomMetadataRequest) returns (QueryDenomMetadataResponse) {
    47      option (google.api.http).get = "/cosmos/bank/v1beta1/denoms_metadata/{denom}";
    48    }
    49  
    50    // DenomsMetadata queries the client metadata for all registered coin denominations.
    51    rpc DenomsMetadata(QueryDenomsMetadataRequest) returns (QueryDenomsMetadataResponse) {
    52      option (google.api.http).get = "/cosmos/bank/v1beta1/denoms_metadata";
    53    }
    54  }
    55  
    56  // QueryBalanceRequest is the request type for the Query/Balance RPC method.
    57  message QueryBalanceRequest {
    58    option (gogoproto.equal)           = false;
    59    option (gogoproto.goproto_getters) = false;
    60  
    61    // address is the address to query balances for.
    62    string address = 1;
    63  
    64    // denom is the coin denom to query balances for.
    65    string denom = 2;
    66  }
    67  
    68  // QueryBalanceResponse is the response type for the Query/Balance RPC method.
    69  message QueryBalanceResponse {
    70    // balance is the balance of the coin.
    71    cosmos.base.v1beta1.Coin balance = 1;
    72  }
    73  
    74  // QueryBalanceRequest is the request type for the Query/AllBalances RPC method.
    75  message QueryAllBalancesRequest {
    76    option (gogoproto.equal)           = false;
    77    option (gogoproto.goproto_getters) = false;
    78  
    79    // address is the address to query balances for.
    80    string address = 1;
    81  
    82    // pagination defines an optional pagination for the request.
    83    cosmos.base.query.v1beta1.PageRequest pagination = 2;
    84  }
    85  
    86  // QueryAllBalancesResponse is the response type for the Query/AllBalances RPC
    87  // method.
    88  message QueryAllBalancesResponse {
    89    // balances is the balances of all the coins.
    90    repeated cosmos.base.v1beta1.Coin balances = 1
    91        [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/Finschia/finschia-sdk/types.Coins"];
    92  
    93    // pagination defines the pagination in the response.
    94    cosmos.base.query.v1beta1.PageResponse pagination = 2;
    95  }
    96  
    97  // QuerySpendableBalancesRequest defines the gRPC request structure for querying
    98  // an account's spendable balances.
    99  message QuerySpendableBalancesRequest {
   100    option (gogoproto.equal)           = false;
   101    option (gogoproto.goproto_getters) = false;
   102  
   103    // address is the address to query spendable balances for.
   104    string address = 1;
   105  
   106    // pagination defines an optional pagination for the request.
   107    cosmos.base.query.v1beta1.PageRequest pagination = 2;
   108  }
   109  
   110  // QuerySpendableBalancesResponse defines the gRPC response structure for querying
   111  // an account's spendable balances.
   112  message QuerySpendableBalancesResponse {
   113    // balances is the spendable balances of all the coins.
   114    repeated cosmos.base.v1beta1.Coin balances = 1
   115        [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/Finschia/finschia-sdk/types.Coins"];
   116  
   117    // pagination defines the pagination in the response.
   118    cosmos.base.query.v1beta1.PageResponse pagination = 2;
   119  }
   120  
   121  // QueryTotalSupplyRequest is the request type for the Query/TotalSupply RPC
   122  // method.
   123  message QueryTotalSupplyRequest {
   124    option (gogoproto.equal)           = false;
   125    option (gogoproto.goproto_getters) = false;
   126  
   127    // pagination defines an optional pagination for the request.
   128    //
   129    // Since: cosmos-sdk 0.43
   130    cosmos.base.query.v1beta1.PageRequest pagination = 1;
   131  }
   132  
   133  // QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC
   134  // method
   135  message QueryTotalSupplyResponse {
   136    // supply is the supply of the coins
   137    repeated cosmos.base.v1beta1.Coin supply = 1
   138        [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/Finschia/finschia-sdk/types.Coins"];
   139  
   140    // pagination defines the pagination in the response.
   141    //
   142    // Since: cosmos-sdk 0.43
   143    cosmos.base.query.v1beta1.PageResponse pagination = 2;
   144  }
   145  
   146  // QuerySupplyOfRequest is the request type for the Query/SupplyOf RPC method.
   147  message QuerySupplyOfRequest {
   148    // denom is the coin denom to query balances for.
   149    string denom = 1;
   150  }
   151  
   152  // QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method.
   153  message QuerySupplyOfResponse {
   154    // amount is the supply of the coin.
   155    cosmos.base.v1beta1.Coin amount = 1 [(gogoproto.nullable) = false];
   156  }
   157  
   158  // QueryParamsRequest defines the request type for querying x/bank parameters.
   159  message QueryParamsRequest {}
   160  
   161  // QueryParamsResponse defines the response type for querying x/bank parameters.
   162  message QueryParamsResponse {
   163    Params params = 1 [(gogoproto.nullable) = false];
   164  }
   165  
   166  // QueryDenomsMetadataRequest is the request type for the Query/DenomsMetadata RPC method.
   167  message QueryDenomsMetadataRequest {
   168    // pagination defines an optional pagination for the request.
   169    cosmos.base.query.v1beta1.PageRequest pagination = 1;
   170  }
   171  
   172  // QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC
   173  // method.
   174  message QueryDenomsMetadataResponse {
   175    // metadata provides the client information for all the registered tokens.
   176    repeated Metadata metadatas = 1 [(gogoproto.nullable) = false];
   177  
   178    // pagination defines the pagination in the response.
   179    cosmos.base.query.v1beta1.PageResponse pagination = 2;
   180  }
   181  
   182  // QueryDenomMetadataRequest is the request type for the Query/DenomMetadata RPC method.
   183  message QueryDenomMetadataRequest {
   184    // denom is the coin denom to query the metadata for.
   185    string denom = 1;
   186  }
   187  
   188  // QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC
   189  // method.
   190  message QueryDenomMetadataResponse {
   191    // metadata describes and provides all the client information for the requested token.
   192    Metadata metadata = 1 [(gogoproto.nullable) = false];
   193  }