auth
The auth
module is responsible for the authentication of accounts and transactions and specifies the base transaction and account types. It contains the middlewares, where all basic transaction validity checks (signatures, nonces, auxiliary fields) are performed, and exposes the account keeper, which allows other modules to read, write, and modify accounts.
For more information, visit https://docs.cosmos.network/main/modules/auth/
Queries
Query
defines the gRPC querier service.
_38 // Accounts returns all the existing accounts
_38 // Since: cosmos-sdk 0.43
_38 rpc Accounts(QueryAccountsRequest) returns (QueryAccountsResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/accounts";
_38 // Account returns account details based on address.
_38 rpc Account(QueryAccountRequest) returns (QueryAccountResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/accounts/{address}";
_38 // Params queries all parameters.
_38 rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/params";
_38 // ModuleAccounts returns all the existing module accounts.
_38 rpc ModuleAccounts(QueryModuleAccountsRequest) returns (QueryModuleAccountsResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/module_accounts";
_38 // Bech32 queries bech32Prefix
_38 rpc Bech32Prefix(Bech32PrefixRequest) returns (Bech32PrefixResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/bech32";
_38 // AddressBytesToString converts Account Address bytes to string
_38 rpc AddressBytesToString(AddressBytesToStringRequest) returns (AddressBytesToStringResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/bech32/{address_bytes}";
_38 // AddressStringToBytes converts Address string to bytes
_38 rpc AddressStringToBytes(AddressStringToBytesRequest) returns (AddressStringToBytesResponse) {
_38 option (google.api.http).get = "/cosmos/auth/v1beta1/bech32/{address_string}";
QueryAccountsRequest
QueryAccountsRequest
is the request type for the Query/Accounts
RPC method.
Since: cosmos-sdk 0.43
_4message QueryAccountsRequest {
_4 // pagination defines an optional pagination for the request.
_4 cosmos.base.query.v1beta1.PageRequest pagination = 1;
QueryAccountsResponse
QueryAccountsResponse
is the response type for the Query/Accounts RPC method.
Since: cosmos-sdk 0.43
_7message QueryAccountsResponse {
_7 // accounts are the existing accounts
_7 repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "AccountI"];
_7 // pagination defines the pagination in the response.
_7 cosmos.base.query.v1beta1.PageResponse pagination = 2;
QueryAccountRequest
QueryAccountRequest
is the request type for the Query/Account
RPC method.
_7message QueryAccountRequest {
_7 option (gogoproto.equal) = false;
_7 option (gogoproto.goproto_getters) = false;
_7 // address defines the address to query for.
_7 string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"];
QueryAccountResponse
QueryAccountResponse
is the response type for the Query/Account
RPC method.
_4message QueryAccountResponse {
_4 // account defines the account of the corresponding address.
_4 google.protobuf.Any account = 1 [(cosmos_proto.accepts_interface) = "AccountI"];
QueryParamsRequest
QueryParamsRequest
is the request type for the Query/Params
RPC method.
_1message QueryParamsRequest {}
QueryParamsResponse
QueryParamsResponse
is the response type for the Query/Params
RPC method.
_4message QueryParamsResponse {
_4 // params defines the parameters of the module.
_4 Params params = 1 [(gogoproto.nullable) = false];
QueryModuleAccountsRequest
QueryModuleAccountsRequest
is the request type for the Query/ModuleAccounts
RPC method.
_1message QueryModuleAccountsRequest {}
QueryModuleAccountsResponse
QueryModuleAccountsResponse
is the response type for the Query/ModuleAccounts
RPC method.
_3message QueryModuleAccountsResponse {
_3 repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "ModuleAccountI"];
Bech32PrefixRequest
Bech32PrefixRequest
is the request type for Bech32Prefix
rpc method.
_1message Bech32PrefixRequest {}
Bech32PrefixResponse
Bech32PrefixResponse
is the response type for Bech32Prefix
rpc method.
_3message Bech32PrefixResponse {
_3 string bech32_prefix = 1;
AddressBytesToStringRequest
AddressBytesToStringRequest
is the request type for AddressString
rpc method.
_3message AddressBytesToStringRequest {
_3 bytes address_bytes = 1;
AddressBytesToStringResponse
AddressBytesToStringResponse
is the response type for AddressString
rpc method.
_3message AddressBytesToStringResponse {
_3 string address_string = 1;
AddressStringToBytesRequest
AddressStringToBytesRequest
is the request type for AccountBytes
rpc method.
_3message AddressStringToBytesRequest {
_3 string address_string = 1;
AddressStringToBytesResponse
AddressStringToBytesResponse
is the response type for AddressBytes
rpc method.
_3message AddressStringToBytesResponse {
_3 bytes address_bytes = 1;