Skip to content

Commit

Permalink
add getBalance (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
yxb-git authored May 10, 2024
1 parent 97e27ea commit 5147ee1
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions mpcvault/platform/v1/api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,27 @@ service PlatformAPI {

// ExecuteSigningRequests signs a signing request. The signing request can be created via the API or manually.
rpc ExecuteSigningRequests (ExecuteSigningRequestsRequest) returns (ExecuteSigningRequestsResponse);

// GetBalance returns the details of a asset balance.
rpc GetBalance (GetBalanceRequest) returns (GetBalanceResponse);
}

message GetBalanceRequest {
// network_type is the type of the network.
NetworkType network_type = 1;
// (optional) chain_id is the chain id of the network.
google.protobuf.Int64Value chain_id = 2;
// wallet_address this is the wallet address.
string wallet_address = 3;
// (optional) token_address this is the token address
// if not set, it will return the balance of the native token.
google.protobuf.StringValue token_address = 4;
}

message GetBalanceResponse {
// The balance is in the smallest denomination.
string balance = 1;
Error error = 2;
}

message CreateWalletRequest {
Expand Down

0 comments on commit 5147ee1

Please sign in to comment.