Skip to content

Commit

Permalink
COR-10778 add refresh balance to js sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
amirlevy committed Dec 26, 2021
1 parent 2d972ca commit 027d950
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/fireblocks-sdk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,15 @@ export class FireblocksSDK {
return await this.apiClient.issueGetRequest(`/v1/vault/accounts/${vaultAccountId}/${assetId}`);
}

/**
* Gets a single vault account asset balance after forcing refresh from the blockchain
* @param vaultAccountId The vault account ID
* @param assetId The ID of the asset to get
*/
public async getVaultAccountAssetWithRefreshBalance(vaultAccountId: string, assetId: string): Promise<AssetResponse> {
return await this.apiClient.issueGetRequest(`/v1/vault/accounts/${vaultAccountId}/${assetId}/balance`);
}

/**
* Gets deposit addresses for an asset in a vault account
* @param vaultAccountId The vault account ID
Expand Down

0 comments on commit 027d950

Please sign in to comment.