fireblocks/fireblocks-sdk-js

Wrong return type of `createVaultAsset()`

Closed this issue · 1 comments

    /**
     * Creates a new asset within an existing vault account
     * @param vaultAccountId The vault account ID
     * @param assetId The asset to add
     */
    public async createVaultAsset(vaultAccountId: string, assetId: string): Promise<AssetResponse> {
        return await this.apiClient.issuePostRequest(`/v1/vault/accounts/${vaultAccountId}/${assetId}`, {});
    }

The return type of this function seems to be incorrect. It should be:

interface CreateVaultAssetResponse {
  id: string;
  address: string;
  legacyAddress: string;
  tag: string;
  eosAccountName: string;
}

This is more in line with the documentation.
Screenshot 2021-03-13 at 13 05 42

@Henry-bee Fixed in 1.15.16, thanks for opening the issue!