Class CoinbaseProAccountService
java.lang.Object
org.knowm.xchange.service.BaseExchangeService<E>
org.knowm.xchange.service.BaseResilientExchangeService<CoinbaseProExchange>
org.knowm.xchange.coinbasepro.service.CoinbaseProBaseService
org.knowm.xchange.coinbasepro.service.CoinbaseProAccountServiceRaw
org.knowm.xchange.coinbasepro.service.CoinbaseProAccountService
- All Implemented Interfaces:
AccountService,BaseService
public class CoinbaseProAccountService
extends CoinbaseProAccountServiceRaw
implements AccountService
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class -
Field Summary
Fields inherited from class org.knowm.xchange.coinbasepro.service.CoinbaseProBaseService
apiKey, coinbasePro, digest, passphraseFields inherited from class org.knowm.xchange.service.BaseResilientExchangeService
resilienceRegistriesFields inherited from class org.knowm.xchange.service.BaseExchangeService
exchange -
Constructor Summary
ConstructorsConstructorDescriptionCoinbaseProAccountService(CoinbaseProExchange exchange, ResilienceRegistries resilienceRegistries) -
Method Summary
Modifier and TypeMethodDescriptionCreateTradeHistoryParamsobject specific to this exchange.Get account infoGet the trading fees per instrument as determined by the given exchange's rules for adjusting fees by recent volume traded.getFundingHistory(TradeHistoryParams params) moveFunds(Currency currency, String address, BigDecimal amount) requestDepositAddress(Currency currency, String... args) Deprecated.requestDepositAddressData(Currency currency, String... args) Request a digital currency address to fund this account.withdrawFunds(Currency currency, BigDecimal amount, String address) Convenience method, typically just delegates to withdrawFunds(WithdrawFundsParams params)withdrawFunds(Currency currency, BigDecimal amount, AddressWithTag address) Convenience method, typically just delegates to withdrawFunds(WithdrawFundsParams params)withdrawFunds(WithdrawFundsParams params) Withdraw funds from this account.Methods inherited from class org.knowm.xchange.coinbasepro.service.CoinbaseProAccountServiceRaw
getCoinbaseAccountAddress, getCoinbaseAccounts, getCoinbaseProAccountInfo, getCoinbaseProFees, getWebsocketAuthData, ledger, report, requestNewReport, sendMoney, transfers, transfers, withdrawCryptoMethods inherited from class org.knowm.xchange.coinbasepro.service.CoinbaseProBaseService
handleErrorMethods inherited from class org.knowm.xchange.service.BaseResilientExchangeService
decorateApiCall, rateLimiter, rateLimiter, retry, retryMethods inherited from class org.knowm.xchange.service.BaseExchangeService
verifyOrder, verifyOrder, verifyOrderMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.knowm.xchange.service.account.AccountService
requestDepositAddress, requestDepositAddressData
-
Constructor Details
-
CoinbaseProAccountService
public CoinbaseProAccountService(CoinbaseProExchange exchange, ResilienceRegistries resilienceRegistries)
-
-
Method Details
-
getAccountInfo
Description copied from interface:AccountServiceGet account info- Specified by:
getAccountInfoin interfaceAccountService- Returns:
- the AccountInfo object, null if some sort of error occurred. Implementers should log the error.
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
getDynamicTradingFeesByInstrument
Description copied from interface:AccountServiceGet the trading fees per instrument as determined by the given exchange's rules for adjusting fees by recent volume traded. Some exchanges will provide the current fees per currency via a single API request, while others require more logic to compute by hand.- Specified by:
getDynamicTradingFeesByInstrumentin interfaceAccountService- Returns:
- map between currency pairs and their fees at the time of invocation.
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
withdrawFunds
public String withdrawFunds(Currency currency, BigDecimal amount, String address) throws IOException Description copied from interface:AccountServiceConvenience method, typically just delegates to withdrawFunds(WithdrawFundsParams params)- Specified by:
withdrawFundsin interfaceAccountService- Parameters:
currency- The currency to withdrawamount- The amount to withdrawaddress- The destination address- Returns:
- The result of the withdrawal (usually a transaction ID)
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
withdrawFunds
public String withdrawFunds(Currency currency, BigDecimal amount, AddressWithTag address) throws IOException Description copied from interface:AccountServiceConvenience method, typically just delegates to withdrawFunds(WithdrawFundsParams params)- Specified by:
withdrawFundsin interfaceAccountService- Parameters:
currency- The currency to withdrawamount- The amount to withdrawaddress- The destination address- Returns:
- The result of the withdrawal (usually a transaction ID)
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
withdrawFunds
Description copied from interface:AccountServiceWithdraw funds from this account. Allows to withdraw digital currency funds from the exchange account to an external address- Specified by:
withdrawFundsin interfaceAccountService- Parameters:
params- The withdrawl details- Returns:
- The result of the withdrawal (usually a transaction ID)
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
moveFunds
- Throws:
IOException
-
requestDepositAddress
@Deprecated public String requestDepositAddress(Currency currency, String... args) throws IOException Deprecated.Description copied from interface:AccountServiceRequest a digital currency address to fund this account. Allows to fund the exchange account with digital currency from an external address- Specified by:
requestDepositAddressin interfaceAccountService- Parameters:
currency- The digital currency that corresponds to the desired deposit address.args- Necessary argument(s) as aString- Returns:
- the internal deposit address to send funds to
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
requestDepositAddressData
public AddressWithTag requestDepositAddressData(Currency currency, String... args) throws IOException Description copied from interface:AccountServiceRequest a digital currency address to fund this account. Allows to fund the exchange account with digital currency from an external address- Specified by:
requestDepositAddressDatain interfaceAccountService- Parameters:
currency- The digital currency that corresponds to the desired deposit address.- Returns:
- the internal deposit address to send funds to
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-
createFundingHistoryParams
Description copied from interface:AccountServiceCreateTradeHistoryParamsobject specific to this exchange. Object created by this method may be used to discover supported and requiredAccountService.getFundingHistory(TradeHistoryParams)parameters and should be passed only to the method in the same class as the createFundingHistoryParams that created the object.- Specified by:
createFundingHistoryParamsin interfaceAccountService
-
getTransfersWithPagination
public CoinbaseProTransfersWithHeader getTransfersWithPagination(TradeHistoryParams params) throws IOException - Throws:
IOException
-
getFundingHistory
- Specified by:
getFundingHistoryin interfaceAccountService- Returns:
- list of funding history if available or an empty list otherwise. This should never return null.
- Throws:
IOException- - Indication that a networking error occurred while fetching JSON data
-