fireblocks-sdk
Advanced tools
Comparing version 2.0.0 to 2.1.0
@@ -5,2 +5,8 @@ ### Changelog | ||
#### [v2.1.0](https://github.com/fireblocks/fireblocks-sdk-js/compare/v2.0.0...v2.1.0) | ||
> 2 May 2022 | ||
- Bump minimist from 1.2.5 to 1.2.6 [`#91`](https://github.com/fireblocks/fireblocks-sdk-js/pull/91) | ||
### [v2.0.0](https://github.com/fireblocks/fireblocks-sdk-js/compare/v1.14.0...v2.0.0) | ||
@@ -11,2 +17,4 @@ | ||
- feat: added pagination to vault_accounts endpoint [`#79`](https://github.com/fireblocks/fireblocks-sdk-js/pull/79) | ||
- Refactor network connection response [`#81`](https://github.com/fireblocks/fireblocks-sdk-js/pull/81) | ||
- Bump minimist from 1.2.5 to 1.2.6 [`#80`](https://github.com/fireblocks/fireblocks-sdk-js/pull/80) | ||
@@ -13,0 +21,0 @@ #### [v1.14.0](https://github.com/fireblocks/fireblocks-sdk-js/compare/v1.13.0...v1.14.0) |
import { IAuthProvider } from "./iauth-provider"; | ||
import { VaultAccountResponse, CreateTransactionResponse, TransactionArguments, AssetResponse, ExchangeResponse, TransactionResponse, TransactionFilter, CancelTransactionResponse, WalletContainerResponse, DepositAddressResponse, GenerateAddressResponse, OperationSuccessResponse, NetworkConnectionResponse, FiatAccountResponse, CreateTransferTicketArgs, TransferTicketResponse, TermResponse, ExecuteTermArgs, CreateTransferTicketResponse, EstimateTransactionFeeResponse, EstimateFeeResponse, PublicKeyInfoArgs, PublicKeyInfoForVaultAccountArgs, GasStationInfo, MaxSpendableAmountResponse, VaultAccountsFilter, VaultBalancesFilter, ValidateAddressResponse, VaultAssetResponse, RequestOptions, AllocateFundsRequest, DeallocateFundsRequest, ResendWebhooksResponse, AssetTypeResponse, User, TransactionPageResponse, TransactionPageFilter, InternalWalletAsset, ExternalWalletAsset, OffExchangeEntityResponse, PagedVaultAccountsResponse, PagedVaultAccountsRequestFilters } from "./types"; | ||
import { VaultAccountResponse, CreateTransactionResponse, TransactionArguments, AssetResponse, ExchangeResponse, TransactionResponse, TransactionFilter, CancelTransactionResponse, WalletContainerResponse, DepositAddressResponse, GenerateAddressResponse, OperationSuccessResponse, NetworkConnectionResponse, FiatAccountResponse, CreateTransferTicketArgs, TransferTicketResponse, TermResponse, ExecuteTermArgs, CreateTransferTicketResponse, EstimateTransactionFeeResponse, EstimateFeeResponse, PublicKeyInfoArgs, PublicKeyInfoForVaultAccountArgs, GasStationInfo, MaxSpendableAmountResponse, VaultAccountsFilter, VaultBalancesFilter, ValidateAddressResponse, VaultAssetResponse, RequestOptions, AllocateFundsRequest, DeallocateFundsRequest, ResendWebhooksResponse, AssetTypeResponse, User, TransactionPageResponse, TransactionPageFilter, InternalWalletAsset, ExternalWalletAsset, OffExchangeEntityResponse, SetFeePayerConfiguration, FeePayerConfiguration, PagedVaultAccountsResponse, PagedVaultAccountsRequestFilters } from "./types"; | ||
export * from "./types"; | ||
@@ -54,2 +54,3 @@ export interface SDKOptions { | ||
* @param assetId The ID of the asset to get | ||
* @param requestOptions | ||
*/ | ||
@@ -75,2 +76,3 @@ refreshVaultAssetBalance(vaultAccountId: string, assetId: string, requestOptions?: RequestOptions): Promise<AssetResponse>; | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -122,2 +124,3 @@ generateNewAddress(vaultAccountId: string, assetId: string, description?: string, customerRefId?: string, requestOptions?: RequestOptions): Promise<GenerateAddressResponse>; | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -131,2 +134,3 @@ transferToSubaccount(exchangeAccountId: string, subaccountId: string, assetId: string, amount: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -147,2 +151,3 @@ transferFromSubaccount(exchangeAccountId: string, subaccountId: string, assetId: string, amount: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -154,2 +159,3 @@ redeemToLinkedDDA(accountId: string, amount: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -215,2 +221,3 @@ depositFromLinkedDDA(accountId: string, amount: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param txId The transaction id to cancel | ||
* @param requestOptions | ||
*/ | ||
@@ -223,2 +230,6 @@ cancelTransactionById(txId: string, requestOptions?: RequestOptions): Promise<CancelTransactionResponse>; | ||
* @param customerRefId A customer reference ID | ||
* @param autoFuel | ||
* @param requestOptions | ||
* @param autoFuel | ||
* @param requestOptions | ||
*/ | ||
@@ -229,2 +240,3 @@ createVaultAccount(name: string, hiddenOnUI?: boolean, customerRefId?: string, autoFuel?: boolean, requestOptions?: RequestOptions): Promise<VaultAccountResponse>; | ||
* @param vaultAccountId The vault account ID | ||
* @param requestOptions | ||
*/ | ||
@@ -235,2 +247,3 @@ hideVaultAccount(vaultAccountId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param vaultAccountId The vault account ID | ||
* @param requestOptions | ||
*/ | ||
@@ -242,2 +255,3 @@ unhideVaultAccount(vaultAccountId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param autoFuel The new value for the autoFuel flag | ||
* @param requestOptions | ||
*/ | ||
@@ -247,2 +261,3 @@ setAutoFuel(vaultAccountId: string, autoFuel: boolean, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* Updates a vault account | ||
* @param vaultAccountId | ||
* @param name A new name for the vault account | ||
@@ -255,2 +270,3 @@ */ | ||
* @param assetId The asset to add | ||
* @param requestOptions | ||
*/ | ||
@@ -262,2 +278,3 @@ createVaultAsset(vaultAccountId: string, assetId: string, requestOptions?: RequestOptions): Promise<VaultAssetResponse>; | ||
* @param assetId The asset to add | ||
* @param requestOptions | ||
*/ | ||
@@ -269,2 +286,3 @@ activateVaultAsset(vaultAccountId: string, assetId: string, requestOptions?: RequestOptions): Promise<VaultAssetResponse>; | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -276,2 +294,3 @@ createExternalWallet(name: string, customerRefId?: string, requestOptions?: RequestOptions): Promise<WalletContainerResponse<ExternalWalletAsset>>; | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -285,2 +304,3 @@ createInternalWallet(name: string, customerRefId?: string, requestOptions?: RequestOptions): Promise<WalletContainerResponse<InternalWalletAsset>>; | ||
* @param tag (for ripple only) The ripple account tag | ||
* @param requestOptions | ||
*/ | ||
@@ -294,2 +314,3 @@ createExternalWalletAsset(walletId: string, assetId: string, address: string, tag?: string, requestOptions?: RequestOptions): Promise<ExternalWalletAsset>; | ||
* @param tag (for ripple only) The ripple account tag | ||
* @param requestOptions | ||
*/ | ||
@@ -331,2 +352,3 @@ createInternalWalletAsset(walletId: string, assetId: string, address: string, tag?: string, requestOptions?: RequestOptions): Promise<InternalWalletAsset>; | ||
* @param ticketId | ||
* @param requestOptions | ||
*/ | ||
@@ -339,2 +361,3 @@ cancelTransferTicket(ticketId: string, requestOptions?: RequestOptions): Promise<any>; | ||
* @param options | ||
* @param requestOptions | ||
*/ | ||
@@ -368,2 +391,3 @@ executeTransferTicketTerm(ticketId: string, termId: string, options: ExecuteTermArgs, requestOptions?: RequestOptions): Promise<any>; | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -375,2 +399,3 @@ setCustomerRefIdForVaultAccount(vaultAccountId: string, customerRefId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -382,2 +407,3 @@ setCustomerRefIdForInternalWallet(walletId: string, customerRefId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -392,2 +418,3 @@ setCustomerRefIdForExternalWallet(walletId: string, customerRefId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -399,2 +426,3 @@ setCustomerRefIdForAddress(vaultAccountId: string, assetId: string, address: string, tag?: string, customerRefId?: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param requiredConfirmationsNumber | ||
* @param requestOptions | ||
*/ | ||
@@ -406,2 +434,3 @@ setConfirmationThresholdForTxId(txId: string, requiredConfirmationsNumber: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param requiredConfirmationsNumber | ||
* @param requestOptions | ||
*/ | ||
@@ -421,2 +450,3 @@ setConfirmationThresholdForTxHash(txHash: string, requiredConfirmationsNumber: number, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param args | ||
* @param requestOptions | ||
*/ | ||
@@ -429,2 +459,3 @@ allocateFundsToPrivateLedger(vaultAccountId: string, asset: string, args: AllocateFundsRequest, requestOptions?: RequestOptions): Promise<any>; | ||
* @param args | ||
* @param requestOptions | ||
*/ | ||
@@ -468,2 +499,3 @@ deallocateFundsFromPrivateLedger(vaultAccountId: string, asset: string, args: DeallocateFundsRequest, requestOptions?: RequestOptions): Promise<any>; | ||
* @param txId The transaction id to unfreeze | ||
* @param requestOptions | ||
*/ | ||
@@ -474,2 +506,3 @@ unfreezeTransactionById(txId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param txId The transaction id to freeze | ||
* @param requestOptions | ||
*/ | ||
@@ -486,2 +519,3 @@ freezeTransactionById(txId: string, requestOptions?: RequestOptions): Promise<OperationSuccessResponse>; | ||
* @param resendStatusUpdated If true a webhook will be sent for the status of the transaction | ||
* @param requestOptions | ||
*/ | ||
@@ -505,4 +539,22 @@ resendTransactionWebhooksById(txId: string, resendCreated?: boolean, resendStatusUpdated?: boolean, requestOptions?: RequestOptions): Promise<ResendWebhooksResponse>; | ||
* @param id the ID of the off exchange | ||
* @param requestOptions | ||
*/ | ||
settleOffExchangeAccountById(id: string, requestOptions?: RequestOptions): Promise<void>; | ||
/** | ||
* Set Fee Payer configuration | ||
* @param feePayerConfiguration | ||
* @param baseAsset | ||
* @param requestOptions | ||
*/ | ||
setFeePayerConfiguration(baseAsset: string, feePayerConfiguration: SetFeePayerConfiguration, requestOptions?: RequestOptions): Promise<FeePayerConfiguration>; | ||
/** | ||
* Get Fee Payer Configuration | ||
* @param baseAsset | ||
*/ | ||
getFeePayerConfiguration(baseAsset: string): Promise<FeePayerConfiguration>; | ||
/** | ||
* Delete Fee Payer Configuration | ||
* @param baseAsset | ||
*/ | ||
removeFeePayerConfiguration(baseAsset: string): Promise<void>; | ||
} |
@@ -105,2 +105,3 @@ "use strict"; | ||
* @param assetId The ID of the asset to get | ||
* @param requestOptions | ||
*/ | ||
@@ -138,2 +139,3 @@ refreshVaultAssetBalance(vaultAccountId, assetId, requestOptions) { | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -224,2 +226,3 @@ generateNewAddress(vaultAccountId, assetId, description, customerRefId, requestOptions) { | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -241,2 +244,3 @@ transferToSubaccount(exchangeAccountId, subaccountId, assetId, amount, requestOptions) { | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -273,2 +277,3 @@ transferFromSubaccount(exchangeAccountId, subaccountId, assetId, amount, requestOptions) { | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -287,2 +292,3 @@ redeemToLinkedDDA(accountId, amount, requestOptions) { | ||
* @param amount The amount to transfer | ||
* @param requestOptions | ||
*/ | ||
@@ -403,2 +409,3 @@ depositFromLinkedDDA(accountId, amount, requestOptions) { | ||
* @param txId The transaction id to cancel | ||
* @param requestOptions | ||
*/ | ||
@@ -415,2 +422,6 @@ cancelTransactionById(txId, requestOptions) { | ||
* @param customerRefId A customer reference ID | ||
* @param autoFuel | ||
* @param requestOptions | ||
* @param autoFuel | ||
* @param requestOptions | ||
*/ | ||
@@ -431,2 +442,3 @@ createVaultAccount(name, hiddenOnUI, customerRefId, autoFuel, requestOptions) { | ||
* @param vaultAccountId The vault account ID | ||
* @param requestOptions | ||
*/ | ||
@@ -441,2 +453,3 @@ hideVaultAccount(vaultAccountId, requestOptions) { | ||
* @param vaultAccountId The vault account ID | ||
* @param requestOptions | ||
*/ | ||
@@ -452,2 +465,3 @@ unhideVaultAccount(vaultAccountId, requestOptions) { | ||
* @param autoFuel The new value for the autoFuel flag | ||
* @param requestOptions | ||
*/ | ||
@@ -461,2 +475,3 @@ setAutoFuel(vaultAccountId, autoFuel, requestOptions) { | ||
* Updates a vault account | ||
* @param vaultAccountId | ||
* @param name A new name for the vault account | ||
@@ -476,2 +491,3 @@ */ | ||
* @param assetId The asset to add | ||
* @param requestOptions | ||
*/ | ||
@@ -487,2 +503,3 @@ createVaultAsset(vaultAccountId, assetId, requestOptions) { | ||
* @param assetId The asset to add | ||
* @param requestOptions | ||
*/ | ||
@@ -498,2 +515,3 @@ activateVaultAsset(vaultAccountId, assetId, requestOptions) { | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -513,2 +531,3 @@ createExternalWallet(name, customerRefId, requestOptions) { | ||
* @param customerRefId A customer reference ID | ||
* @param requestOptions | ||
*/ | ||
@@ -530,2 +549,3 @@ createInternalWallet(name, customerRefId, requestOptions) { | ||
* @param tag (for ripple only) The ripple account tag | ||
* @param requestOptions | ||
*/ | ||
@@ -548,2 +568,3 @@ createExternalWalletAsset(walletId, assetId, address, tag, requestOptions) { | ||
* @param tag (for ripple only) The ripple account tag | ||
* @param requestOptions | ||
*/ | ||
@@ -622,2 +643,3 @@ createInternalWalletAsset(walletId, assetId, address, tag, requestOptions) { | ||
* @param ticketId | ||
* @param requestOptions | ||
*/ | ||
@@ -634,2 +656,3 @@ cancelTransferTicket(ticketId, requestOptions) { | ||
* @param options | ||
* @param requestOptions | ||
*/ | ||
@@ -683,2 +706,3 @@ executeTransferTicketTerm(ticketId, termId, options, requestOptions) { | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -694,2 +718,3 @@ setCustomerRefIdForVaultAccount(vaultAccountId, customerRefId, requestOptions) { | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -705,2 +730,3 @@ setCustomerRefIdForInternalWallet(walletId, customerRefId, requestOptions) { | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -719,2 +745,3 @@ setCustomerRefIdForExternalWallet(walletId, customerRefId, requestOptions) { | ||
* @param customerRefId The customer reference ID to set | ||
* @param requestOptions | ||
*/ | ||
@@ -734,2 +761,3 @@ setCustomerRefIdForAddress(vaultAccountId, assetId, address, tag, customerRefId, requestOptions) { | ||
* @param requiredConfirmationsNumber | ||
* @param requestOptions | ||
*/ | ||
@@ -745,2 +773,3 @@ setConfirmationThresholdForTxId(txId, requiredConfirmationsNumber, requestOptions) { | ||
* @param requiredConfirmationsNumber | ||
* @param requestOptions | ||
*/ | ||
@@ -778,2 +807,3 @@ setConfirmationThresholdForTxHash(txHash, requiredConfirmationsNumber, requestOptions) { | ||
* @param args | ||
* @param requestOptions | ||
*/ | ||
@@ -791,2 +821,3 @@ allocateFundsToPrivateLedger(vaultAccountId, asset, args, requestOptions) { | ||
* @param args | ||
* @param requestOptions | ||
*/ | ||
@@ -889,2 +920,3 @@ deallocateFundsFromPrivateLedger(vaultAccountId, asset, args, requestOptions) { | ||
* @param txId The transaction id to unfreeze | ||
* @param requestOptions | ||
*/ | ||
@@ -899,2 +931,3 @@ unfreezeTransactionById(txId, requestOptions) { | ||
* @param txId The transaction id to freeze | ||
* @param requestOptions | ||
*/ | ||
@@ -919,2 +952,3 @@ freezeTransactionById(txId, requestOptions) { | ||
* @param resendStatusUpdated If true a webhook will be sent for the status of the transaction | ||
* @param requestOptions | ||
*/ | ||
@@ -955,2 +989,3 @@ resendTransactionWebhooksById(txId, resendCreated, resendStatusUpdated, requestOptions) { | ||
* @param id the ID of the off exchange | ||
* @param requestOptions | ||
*/ | ||
@@ -962,4 +997,33 @@ settleOffExchangeAccountById(id, requestOptions) { | ||
} | ||
/** | ||
* Set Fee Payer configuration | ||
* @param feePayerConfiguration | ||
* @param baseAsset | ||
* @param requestOptions | ||
*/ | ||
setFeePayerConfiguration(baseAsset, feePayerConfiguration, requestOptions) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
return yield this.apiClient.issuePostRequest(`/v1/fee_payer/${baseAsset}`, feePayerConfiguration, requestOptions); | ||
}); | ||
} | ||
/** | ||
* Get Fee Payer Configuration | ||
* @param baseAsset | ||
*/ | ||
getFeePayerConfiguration(baseAsset) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
return yield this.apiClient.issueGetRequest(`/v1/fee_payer/${baseAsset}`); | ||
}); | ||
} | ||
/** | ||
* Delete Fee Payer Configuration | ||
* @param baseAsset | ||
*/ | ||
removeFeePayerConfiguration(baseAsset) { | ||
return __awaiter(this, void 0, void 0, function* () { | ||
return yield this.apiClient.issueDeleteRequest(`/v1/fee_payer/${baseAsset}`); | ||
}); | ||
} | ||
} | ||
exports.FireblocksSDK = FireblocksSDK; | ||
//# sourceMappingURL=fireblocks-sdk.js.map |
@@ -13,2 +13,5 @@ export interface VaultAccountResponse { | ||
} | ||
export interface BalanceRewardInfo { | ||
pendingRewards: string; | ||
} | ||
export interface AssetResponse { | ||
@@ -30,2 +33,3 @@ id: string; | ||
totalStakedNetwork?: string; | ||
rewardInfo?: BalanceRewardInfo; | ||
blockHeight?: string; | ||
@@ -162,2 +166,5 @@ blockHash?: string; | ||
} | ||
export interface TransactionArgumentsFeePayerInfo { | ||
feePayerAccountId: string; | ||
} | ||
export interface TransactionArguments { | ||
@@ -187,2 +194,3 @@ assetId?: string; | ||
forceSweep?: boolean; | ||
feePayerInfo?: TransactionArgumentsFeePayerInfo; | ||
} | ||
@@ -217,2 +225,9 @@ export declare enum FeeLevel { | ||
} | ||
export interface RewardInfo { | ||
srcRewards?: string; | ||
destRewards?: string; | ||
} | ||
export interface FeePayerInfo { | ||
feePayerAccountId?: string; | ||
} | ||
export interface TransactionResponse { | ||
@@ -260,2 +275,4 @@ id: string; | ||
index?: number; | ||
rewardInfo?: RewardInfo; | ||
feePayerInfo?: FeePayerInfo; | ||
} | ||
@@ -271,2 +288,3 @@ export interface AmountInfo { | ||
serviceFee?: string; | ||
gasPrice?: string; | ||
} | ||
@@ -604,2 +622,8 @@ export interface TransactionResponseDestination { | ||
} | ||
export interface SetFeePayerConfiguration { | ||
feePayerAccountId: string; | ||
} | ||
export interface FeePayerConfiguration { | ||
feePayerAccountId: string; | ||
} | ||
export {}; |
{ | ||
"name": "fireblocks-sdk", | ||
"version": "2.0.0", | ||
"version": "2.1.0", | ||
"main": "dist/fireblocks-sdk.js", | ||
@@ -5,0 +5,0 @@ "types": "dist/fireblocks-sdk.d.ts", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
135460
2412