WalletAPIClient: {
    createWallet: ((createWalletRequest?, options?) => AxiosPromise<Wallet>);
    getWallet: ((walletId, options?) => AxiosPromise<Wallet>);
    getWalletBalance(walletId, assetId, options?): AxiosPromise<Balance>;
    listWalletBalances(walletId, options?): AxiosPromise<AddressBalanceList>;
    listWalletBalances(walletId, options?): AxiosPromise<AddressBalanceList>;
    listWallets(limit?, page?, options?): AxiosPromise<WalletList>;
}

WalletAPI client type definition.

Type declaration

  • createWallet: ((createWalletRequest?, options?) => AxiosPromise<Wallet>)

    Create a new wallet scoped to the user.

    Throws

    If the request fails.

      • (createWalletRequest?, options?): AxiosPromise<Wallet>
      • Parameters

        • Optional createWalletRequest: CreateWalletRequest
        • Optional options: RawAxiosRequestConfig

          Axios request options.

        Returns AxiosPromise<Wallet>

  • getWallet: ((walletId, options?) => AxiosPromise<Wallet>)

    Returns the wallet model with the given ID.

    Throws

    If the request fails.

      • (walletId, options?): AxiosPromise<Wallet>
      • Parameters

        • walletId: string

          The ID of the wallet to fetch.

        • Optional options: RawAxiosRequestConfig

          Override http request option.

        Returns AxiosPromise<Wallet>

  • getWalletBalance:function
    • Get the aggregated balance of an asset across all of the addresses in the wallet.

      Parameters

      • walletId: string

        The ID of the wallet to fetch the balance for.

      • assetId: string

        The symbol of the asset to fetch the balance for.

      • Optional options: RawAxiosRequestConfig

        Override http request option.

      Returns AxiosPromise<Balance>

      Throws

      If the required parameter is not provided.

      Throws

      If the request fails.

  • listWalletBalances:function
    • List the balances of all of the addresses in the wallet aggregated by asset.

      Parameters

      • walletId: string

        The ID of the wallet to fetch the balances for.

      • Optional options: RawAxiosRequestConfig

        Override http request option.

      Returns AxiosPromise<AddressBalanceList>

      Throws

      If the required parameter is not provided.

      Throws

      If the request fails.

    • List the balances of all of the addresses in the wallet aggregated by asset.

      Parameters

      • walletId: string

        The ID of the wallet to fetch the balances for.

      • Optional options: RawAxiosRequestConfig

        Override http request option.

      Returns AxiosPromise<AddressBalanceList>

      Throws

      If the required parameter is not provided.

      Throws

      If the request fails.

  • listWallets:function
    • List wallets belonging to the user.

      Parameters

      • Optional limit: number

        A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.

      • Optional page: string

        A cursor for pagination across multiple pages of results. Don't include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.

      • Optional options: RawAxiosRequestConfig

        Override http request option.

      Returns AxiosPromise<WalletList>

      Throws

      If the request fails.

      Throws

      If the required parameter is not provided.