Package org.knowm.xchange.blockchain
Interface BlockchainAuthenticated
- All Superinterfaces:
Blockchain
@Path("v3/exchange") @Produces("application/json") public interface BlockchainAuthenticated extends Blockchain
- See Also:
- Swagger
-
Method Summary
Modifier and Type Method Description Void
cancelAllOrders(String symbol)
Delete all open orders (of a symbol, if specified)Void
cancelOrder(String orderId)
Delete a specific orderList<BlockchainDeposits>
depositHistory(Long startTime, Long endTime)
Get a list of depositsMap<String,List<BlockchainAccountInformation>>
getAccountInformation()
Receive current account balancesBlockchainDeposit
getDepositAddress(String symbol)
Get a deposit address.BlockchainFees
getFees()
Get current fee levelBlockchainOrder
getOrder(String orderId)
Get a specific orderList<BlockchainOrder>
getOrders()
Get a list ordersList<BlockchainOrder>
getOrdersBySymbol(String symbol)
Get a list orders by symbolList<BlockchainOrder>
getTrades(String symbol, Long startTime, Long endTime, Integer limit)
Get a list of filled ordersList<BlockchainWithdrawal>
getWithdrawFunds(Long startTime, Long endTime)
Get a list of withdrawalsBlockchainOrder
postOrder(BlockchainOrder blockchainOrder)
Add an orderBlockchainWithdrawal
postWithdrawFunds(BlockchainWithdrawalParams blockchainWithdrawalRequest)
Request a withdrawal Call GET /whitelist first to retrieve the ID of the beneficiary.Methods inherited from interface org.knowm.xchange.blockchain.Blockchain
getOrderBookL3, getSymbols
-
Method Details
-
getAccountInformation
Receive current account balances- Returns:
- This returns a map where the key
String
represents the primary data and the value which is an instance of typeBlockchainAccountInformation
is a list of account balances
-
postWithdrawFunds
@Path("/withdrawals") @POST @Consumes("application/json") BlockchainWithdrawal postWithdrawFunds(BlockchainWithdrawalParams blockchainWithdrawalRequest) throws IOException, BlockchainExceptionRequest a withdrawal Call GET /whitelist first to retrieve the ID of the beneficiary.- Returns:
- the withdrawal object created
- Throws:
IOException
BlockchainException
-
getWithdrawFunds
@Path("/withdrawals") @GET List<BlockchainWithdrawal> getWithdrawFunds(@QueryParam("from") Long startTime, @QueryParam("to") Long endTime)Get a list of withdrawals- Parameters:
startTime
-endTime
-- Returns:
- list of withdrawals object
-
getDepositAddress
@Path("/deposits/{symbol}") @POST BlockchainDeposit getDepositAddress(@PathParam("symbol") @FormParam("symbol") String symbol) throws IOException, BlockchainExceptionGet a deposit address. Currently, only crypto currencies are supported- Parameters:
symbol
-- Returns:
- the deposit object according to the currency
- Throws:
IOException
BlockchainException
-
getFees
Get current fee level- Returns:
- the fees of all currency pairs
-
depositHistory
@Path("/deposits") @GET List<BlockchainDeposits> depositHistory(@QueryParam("from") Long startTime, @QueryParam("to") Long endTime)Get a list of deposits- Parameters:
startTime
-endTime
-- Returns:
- list of deposits object
-
getOrders
Get a list orders- Returns:
- live and historic orders, defaulting to live orders. Returns at most 100 results, use timestamp to paginate for further results
-
getOrdersBySymbol
@Path("/orders") @GET List<BlockchainOrder> getOrdersBySymbol(@QueryParam("symbol") String symbol) throws IOException, BlockchainExceptionGet a list orders by symbol- Returns:
- live and historic orders, defaulting to live orders. Returns at most 100 results, use timestamp to paginate for further results
- Throws:
IOException
BlockchainException
-
getOrder
@Path("/orders/{orderId}") @GET BlockchainOrder getOrder(@PathParam("orderId") String orderId) throws IOException, BlockchainExceptionGet a specific order- Parameters:
orderId
-- Returns:
- the order according to the orderId, 404 if not found
- Throws:
IOException
BlockchainException
-
postOrder
@Path("/orders") @POST @Consumes("application/json") BlockchainOrder postOrder(BlockchainOrder blockchainOrder)Add an order- Parameters:
blockchainOrder
-- Returns:
- a new order according to the provided parameters
-
cancelOrder
@Path("/orders/{orderId}") @DELETE Void cancelOrder(@PathParam("orderId") String orderId) throws IOException, BlockchainExceptionDelete a specific order- Parameters:
orderId
-- Returns:
- status 200 if it was successfully removed or 400 if there was an error
- Throws:
IOException
BlockchainException
-
cancelAllOrders
@Path("/orders") @DELETE Void cancelAllOrders(@QueryParam("symbol") String symbol) throws IOException, BlockchainExceptionDelete all open orders (of a symbol, if specified)- Parameters:
symbol
-- Returns:
- status 200 if it was successfully removed or 400 if there was an error
- Throws:
IOException
BlockchainException
-
getTrades
@Path("/trades") @GET List<BlockchainOrder> getTrades(@QueryParam("symbol") String symbol, @QueryParam("from") Long startTime, @QueryParam("to") Long endTime, @QueryParam("limit") Integer limit) throws IOException, BlockchainExceptionGet a list of filled orders- Parameters:
symbol
-startTime
-endTime
-limit
-- Returns:
- filled orders, including partial fills. Returns at most 100 results, use timestamp to paginate for further results
- Throws:
IOException
BlockchainException
-