Package org.knowm.xchange.coinbasepro
Interface CoinbasePro
@Path("/")
@Produces("application/json")
public interface CoinbasePro
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionvoidcancelOrder(String id, String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) Map<?,?> createReport(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, CoinbasePro.CoinbaseProReportRequest request) getAccounts(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) Authenticated callsgetCoinbaseProAccountAddress(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String accountId) getCoinbaseProAccounts(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) getFills(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, Integer tradeIdAfter, Integer tradeIdBefore, Integer limit, String orderId, String productId) getHistoricalCandles(String baseCurrency, String targetCurrency, String start, String end, String granularity) getListOrders(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) getListOrders(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String status, Integer limit, String after) getListOrders(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String status, String productId) getOrder(String id, String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) getProductOrderBook(String baseCurrency, String targetCurrency, String level) getProductStats(String baseCurrency, String targetCurrency) getProductTicker(String baseCurrency, String targetCurrency) Map<?,?> getReport(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String reportId) getStats()getTradesPageable(String baseCurrency, String targetCurrency, Long after, Integer limit) com.fasterxml.jackson.databind.JsonNodegetVerifyId(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) ledger(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String accountId, String startingOrderId) placeOrder(CoinbaseProPlaceOrder placeOrder, String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase) sendMoney(CoinbaseProSendMoneyRequest sendMoney, String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String accountId) transfers(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String accountId, String profileId, Integer limit, String createdAtDate) transfers(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, String type, String profileId, String beforeDate, String afterDate, Integer limit) withdrawCrypto(String apiKey, si.mazi.rescu.ParamsDigest signer, long timestamp, String passphrase, CoinbaseProWithdrawFundsRequest request)
-
Method Details
-
getCurrencies
@GET @Path("currencies") CoinbaseProCurrency[] getCurrencies() throws CoinbaseProException, IOException- Throws:
CoinbaseProExceptionIOException
-
getProducts
- Throws:
CoinbaseProExceptionIOException
-
getProductTicker
@GET @Path("products/{baseCurrency}-{targetCurrency}/ticker") CoinbaseProProductTicker getProductTicker(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getProductStats
@GET @Path("products/{baseCurrency}-{targetCurrency}/stats") CoinbaseProProductStats getProductStats(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getStats
@GET @Path("products/stats") Map<String,CoinbaseProStats> getStats() throws CoinbaseProException, IOException- Throws:
CoinbaseProExceptionIOException
-
getProductOrderBook
@GET @Path("products/{baseCurrency}-{targetCurrency}/book?level={level}") CoinbaseProProductBook getProductOrderBook(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency, @PathParam("level") String level) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getTrades
@GET @Path("products/{baseCurrency}-{targetCurrency}/trades") CoinbaseProTrade[] getTrades(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getTradesPageable
@GET @Path("products/{baseCurrency}-{targetCurrency}/trades") CoinbaseProTrades getTradesPageable(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency, @QueryParam("after") Long after, @QueryParam("limit") Integer limit) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getHistoricalCandles
@GET @Path("products/{baseCurrency}-{targetCurrency}/candles") CoinbaseProCandle[] getHistoricalCandles(@PathParam("baseCurrency") String baseCurrency, @PathParam("targetCurrency") String targetCurrency, @QueryParam("start") String start, @QueryParam("end") String end, @QueryParam("granularity") String granularity) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getAccounts
@GET @Path("accounts") CoinbaseProAccount[] getAccounts(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException Authenticated calls- Throws:
CoinbaseProExceptionIOException
-
getFees
@GET @Path("fees") CoinbaseProFee getFees(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getListOrders
@GET @Path("orders") CoinbaseProOrder[] getListOrders(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getListOrders
@GET @Path("orders") CoinbasePagedResponse<CoinbaseProOrder> getListOrders(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @QueryParam("status") String status, @QueryParam("limit") Integer limit, @QueryParam("after") String after) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getListOrders
@GET @Path("orders") CoinbaseProOrder[] getListOrders(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @QueryParam("status") String status, @QueryParam("product_id") String productId) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
placeOrder
@POST @Path("orders") @Consumes("application/json") CoinbaseProIdResponse placeOrder(CoinbaseProPlaceOrder placeOrder, @HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
cancelOrder
@DELETE @Path("orders/{id}") @Produces("text/plain") void cancelOrder(@PathParam("id") String id, @HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getOrder
@GET @Path("orders/{id}") @Produces("application/json") CoinbaseProOrder getOrder(@PathParam("id") String id, @HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getFills
@GET @Path("fills") CoinbasePagedResponse<CoinbaseProFill> getFills(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @QueryParam("after") Integer tradeIdAfter, @QueryParam("before") Integer tradeIdBefore, @QueryParam("limit") Integer limit, @QueryParam("order_id") String orderId, @QueryParam("product_id") String productId) throws CoinbaseProException, IOException - Parameters:
apiKey- for accountsigner- for accounttimestamp- of messagepassphrase- for accounttradeIdAfter- Return trades before this tradeId.tradeIdBefore- Return trades after this tradeId.orderId- to get fills forproductId- to get fills for- Returns:
- fill array
- Throws:
CoinbaseProException- when exchange throws exceptionIOException- when connection issue arises
-
sendMoney
@POST @Path("accounts/{account_id}/transactions") @Consumes("application/json") CoinbaseProSendMoneyResponse sendMoney(CoinbaseProSendMoneyRequest sendMoney, @HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @PathParam("account_id") String accountId) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
ledger
@GET @Path("accounts/{account_id}/ledger") @Consumes("application/json") List<Map<?,?>> ledger(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @PathParam("account_id") String accountId, @QueryParam("after") String startingOrderId) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
transfers
@GET @Path("accounts/{account_id}/transfers") @Consumes("application/json") CoinbaseProTransfers transfers(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @PathParam("account_id") String accountId, @QueryParam("profile_id") String profileId, @QueryParam("limit") Integer limit, @QueryParam("after") String createdAtDate) -
transfers
@GET @Path("transfers") @Consumes("application/json") CoinbaseProTransfers transfers(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @QueryParam("type") String type, @QueryParam("profile_id") String profileId, @QueryParam("before") String beforeDate, @QueryParam("after") String afterDate, @QueryParam("limit") Integer limit) -
createReport
@POST @Path("reports") @Consumes("application/json") Map<?,?> createReport(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, CoinbasePro.CoinbaseProReportRequest request) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
getReport
@GET @Path("reports/{report_id}") @Consumes("application/json") Map<?,?> getReport(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @PathParam("report_id") String reportId) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-
withdrawCrypto
@POST @Path("withdrawals/crypto") @Produces("application/json") @Consumes("application/json") CoinbaseProWithdrawCryptoResponse withdrawCrypto(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, CoinbaseProWithdrawFundsRequest request) throws si.mazi.rescu.HttpStatusIOException - Throws:
si.mazi.rescu.HttpStatusIOException
-
getCoinbaseProAccounts
@GET @Path("coinbase-accounts") CoinbaseProAccount[] getCoinbaseProAccounts(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws si.mazi.rescu.HttpStatusIOException - Throws:
si.mazi.rescu.HttpStatusIOException
-
getCoinbaseProAccountAddress
@POST @Path("coinbase-accounts/{account_id}/addresses") CoinbaseProAccountAddress getCoinbaseProAccountAddress(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase, @PathParam("account_id") String accountId) -
getVerifyId
@GET @Path("/users/self/verify") com.fasterxml.jackson.databind.JsonNode getVerifyId(@HeaderParam("CB-ACCESS-KEY") String apiKey, @HeaderParam("CB-ACCESS-SIGN") si.mazi.rescu.ParamsDigest signer, @HeaderParam("CB-ACCESS-TIMESTAMP") long timestamp, @HeaderParam("CB-ACCESS-PASSPHRASE") String passphrase) throws CoinbaseProException, IOException - Throws:
CoinbaseProExceptionIOException
-