public interface LoanAPI
| 限定符和类型 | 方法和说明 |
|---|---|
BorrowResponse |
borrow(BorrowRequest request)
Post Borrow Order
|
Void |
cancelLendOrder(String orderId)
Cancel Lend Order
Request via this endpoint to cancel lend order.
|
LendResponse |
lend(LendRequest request)
Post Lend Order
Request via this endpoint to post lend order.
|
Pagination<ActiveLendItem> |
queryActiveLend(String currency,
Integer currentPage,
Integer pageSize)
Get Active Order
Request via this endpoint to get active lend orders.
|
BorrowQueryResponse |
queryBorrow(String orderId)
Get Borrow Order
Request via this endpoint to get the info of the borrow order through the orderId retrieved from Post Borrow Order .
|
Pagination<BorrowOutstandingResponse> |
queryBorrowOutstanding(BorrowRecordQueryRequest request)
Get Repay Record
|
Pagination<BorrowRepaidResponse> |
queryBorrowRepaid(BorrowRecordQueryRequest request)
Get Repayment Record
|
Pagination<DoneLendItem> |
queryDoneLend(String currency,
Integer currentPage,
Integer pageSize)
Get Lent History
Request via this endpoint to get lent orders .
|
List<LastTradeResponse> |
queryLastTrade(String currency)
Margin Trade Data
Request via this endpoint to get the last 300 fills in the lending and borrowing market.
|
List<LendAssetsResponse> |
queryLendAssets(String currency)
Get Account Lend Record
Request via this endpoint to get the lending history of the main account.
|
List<MarketItemResponse> |
queryMarket(String currency,
Integer term)
Lending Market Data
Request via this endpoint to get the configure info of the margin.
|
Pagination<SettledTradeItem> |
querySettledTrade(String currency,
Integer currentPage,
Integer pageSize)
Get Settled Lend Order History
Request via this endpoint to get the settled lend orders .
|
Pagination<UnsettledTradeItem> |
queryUnsettledTrade(String currency,
Integer currentPage,
Integer pageSize)
Get Active Lend Order List
Request via this endpoint to get the outstanding lend order list.
|
Void |
repayAll(RepayAllRequest request)
One-Click Repayment
|
Void |
repaySingle(RepaySingleRequest request)
Repay a Single Order
Request via this endpoint to repay a single order.
|
Void |
toggleAutoLend(ToggleAutoLendRequest request)
Set Auto-lend
Request via this endpoint to set up the automatic lending for a specified currency.
|
BorrowResponse borrow(BorrowRequest request) throws IOException
request - IOExceptionBorrowQueryResponse queryBorrow(String orderId) throws IOException
Request via this endpoint to get the info of the borrow order through the orderId retrieved from Post Borrow Order .
orderId - IOExceptionPagination<BorrowOutstandingResponse> queryBorrowOutstanding(BorrowRecordQueryRequest request) throws IOException
request - IOExceptionPagination<BorrowRepaidResponse> queryBorrowRepaid(BorrowRecordQueryRequest request) throws IOException
request - IOExceptionVoid repayAll(RepayAllRequest request) throws IOException
request - IOExceptionVoid repaySingle(RepaySingleRequest request) throws IOException
Request via this endpoint to repay a single order.
request - IOExceptionLendResponse lend(LendRequest request) throws IOException
Request via this endpoint to post lend order. Please ensure that you have sufficient funds in your Main Account before you post the order. Once the post succeed, the funds posted will be frozen until the order is succssfuly lent out or cancelled.
request - IOExceptionVoid cancelLendOrder(String orderId) throws IOException
Request via this endpoint to cancel lend order.
orderId - IOExceptionVoid toggleAutoLend(ToggleAutoLendRequest request) throws IOException
Request via this endpoint to set up the automatic lending for a specified currency.
request - IOExceptionPagination<ActiveLendItem> queryActiveLend(String currency, Integer currentPage, Integer pageSize) throws IOException
Request via this endpoint to get active lend orders. Items are paginated and sorted to show the latest first. See the Pagination section for retrieving additional entries after the first page. The max pageSize is 100. Active lend orders include orders unfilled, partially filled and uncanceled.
currency - currentPage - pageSize - IOExceptionPagination<DoneLendItem> queryDoneLend(String currency, Integer currentPage, Integer pageSize) throws IOException
Request via this endpoint to get lent orders . Items are paginated and sorted to show the latest first. See the Pagination section for retrieving additional entries after the first page. The max pageSize is 100. Lent order history involves orders canceled or fully filled.
currency - currentPage - pageSize - IOExceptionPagination<UnsettledTradeItem> queryUnsettledTrade(String currency, Integer currentPage, Integer pageSize) throws IOException
Request via this endpoint to get the outstanding lend order list. Items are paginated and sorted to show the latest first. See the Pagination section for retrieving additional entries after the first page. The max pageSize is 100. When a lending order is executed, the system will generate the lending history. The outstanding lend orders includes orders unrepaid and partially repaid.
currency - currentPage - pageSize - IOExceptionPagination<SettledTradeItem> querySettledTrade(String currency, Integer currentPage, Integer pageSize) throws IOException
Request via this endpoint to get the settled lend orders . Items are paginated and sorted to show the latest first. See the Pagination section for retrieving additional entries after the first page. The max pageSize is 100. The settled lend orders include orders repaid fully or partially before or at the maturity time.
currency - currentPage - pageSize - IOExceptionList<LendAssetsResponse> queryLendAssets(String currency) throws IOException
Request via this endpoint to get the lending history of the main account.
currency - IOExceptionList<MarketItemResponse> queryMarket(String currency, Integer term) throws IOException
Request via this endpoint to get the configure info of the margin.
currency - term - IOExceptionList<LastTradeResponse> queryLastTrade(String currency) throws IOException
Request via this endpoint to get the last 300 fills in the lending and borrowing market. The returned value is sorted based on the descending sequence of the order execution time.
currency - IOExceptionCopyright © 2023. All rights reserved.