Skip to content

Latest commit

 

History

History
543 lines (516 loc) · 83 KB

File metadata and controls

543 lines (516 loc) · 83 KB

Endpoint maps

SDK Logo

Each REST client is a JavaScript class, which provides functions individually mapped to each endpoint available in the exchange's API offering.

The following table shows all methods available in each REST client, whether the method requires authentication (automatically handled if API keys are provided), as well as the exact endpoint each method is connected to.

This can be used to easily find which method to call, once you have found which endpoint you're looking to use.

All REST clients are in the src folder. For usage examples, make sure to check the examples folder.

List of clients:

If anything is missing or wrong, please open an issue or let us know in our Node.js Traders telegram group!

How to use table

Table consists of 4 parts:

  • Function name
  • AUTH
  • HTTP Method
  • Endpoint

Function name is the name of the function that can be called through the SDK. Check examples folder in the repo for more help on how to use them!

AUTH is a boolean value that indicates if the function requires authentication - which means you need to pass your API key and secret to the SDK.

HTTP Method shows HTTP method that the function uses to call the endpoint. Sometimes endpoints can have same URL, but different HTTP method so you can use this column to differentiate between them.

Endpoint is the URL that the function uses to call the endpoint. Best way to find exact function you need for the endpoint is to search for URL in this table and find corresponding function name.

SpotClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in SpotClient.ts.

Function AUTH HTTP Method Endpoint
getMarketStatus() GET /v2/market-status
getTimestamp() GET /v1/common/timestamp
getTradingSymbols() GET /v2/settings/common/symbols
getCurrencies() GET /v2/settings/common/currencies
getCurrencysSettings() GET /v1/settings/common/currencys
getSymbolsSettings() GET /v1/settings/common/symbols
getMarketSymbolsSettings() GET /v1/settings/common/market-symbols
getChainsInfo() GET /v1/settings/common/chains
getReferenceCurrencies() GET /v2/reference/currencies
getKlines() GET /market/history/kline
getTicker() GET /market/detail/merged
getTickers() GET /market/tickers
getMarketDepth() GET /market/depth
getLastTrade() GET /market/trade
getHistoryTrades() GET /market/history/trade
get24hMarketSummary() GET /market/detail
getFullOrderBook() GET /market/fullMbp
getAccounts() 🔐 GET /v1/account/accounts
getAccountBalance() 🔐 GET /v1/account/accounts/{accountId}/balance
getAccountValuation() 🔐 GET /v2/account/valuation
getAssetValuation() 🔐 GET /v2/account/asset-valuation
submitTransfer() 🔐 POST /v1/account/transfer
getAccountHistory() 🔐 GET /v1/account/history
getAccountLedger() 🔐 GET /v2/account/ledger
submitV2AccountTransfer() 🔐 POST /v2/account/transfer
submitFuturesTransfer() 🔐 POST /v1/futures/transfer
getPointBalance() 🔐 GET /v2/point/account
submitPointTransfer() 🔐 POST /v2/point/transfer
getAccountSwitchUserInfo() 🔐 GET /v1/account/switch/user/info
getAccountOverviewInfo() 🔐 GET /v1/account/overview/info
updateFeeDeductionMethod() 🔐 POST /v1/account/fee/switch
submitOrder() 🔐 POST /v1/order/orders/place
submitBatchOrders() 🔐 POST /v1/order/batch-orders
submitMarginOrder() 🔐 POST /v1/order/auto/place
cancelOrderById() 🔐 POST /v1/order/orders/{orderId}/submitcancel
cancelOrderByClientId() 🔐 POST /v1/order/orders/submitCancelClientOrder
cancelAllOrders() 🔐 GET /v1/order/cancelAllOrders
getOpenOrders() 🔐 GET /v1/order/openOrders
batchCancelOpenOrders() 🔐 POST /v1/order/orders/batchCancelOpenOrders
batchCancelOrders() 🔐 POST /v1/order/orders/batchcancel
setCancelAllAfter() 🔐 POST /v2/algo-orders/cancel-all-after
getOrder() 🔐 GET /v1/order/orders/{orderId}
getOrderByClientId() 🔐 GET /v1/order/orders/getClientOrder
getOrderMatch() 🔐 GET /v1/order/orders/{orderId}/matchresults
getOrderHistory() 🔐 GET /v1/order/orders
getOrderHistory48h() 🔐 GET /v1/order/history
getMatchResults() 🔐 GET /v1/order/matchresults
getFeeRate() 🔐 GET /v2/reference/transact-fee-rate
placeConditionalOrder() 🔐 POST /v2/algo-orders
cancelConditionalOrders() 🔐 POST /v2/algo-orders/cancellation
getOpenConditionalOrders() 🔐 GET /v2/algo-orders/opening
getConditionalOrderHistory() 🔐 GET /v2/algo-orders/history
getConditionalOrder() 🔐 GET /v2/algo-orders/specific
getRepaymentRecords() 🔐 GET /v2/account/repayment
repayMarginLoan() 🔐 POST /v2/account/repayment
transferSpotToIsolatedMargin() 🔐 POST /v1/dw/transfer-in/margin
transferIsolatedMarginToSpot() 🔐 POST /v1/dw/transfer-out/margin
getMarginLoanInfo() 🔐 GET /v1/margin/loan-info
requestMarginLoan() 🔐 POST /v1/margin/orders
repayMarginLoanIsolated() 🔐 POST /v1/margin/orders/{orderId}/repay
getMarginLoanOrders() 🔐 GET /v1/margin/loan-orders
getMarginAccountBalance() 🔐 GET /v1/margin/accounts/balance
transferSpotToCrossMargin() 🔐 POST /v1/cross-margin/transfer-in
transferCrossMarginToSpot() 🔐 POST /v1/cross-margin/transfer-out
getCrossMarginLoanInfo() 🔐 GET /v1/cross-margin/loan-info
requestCrossMarginLoan() 🔐 POST /v1/cross-margin/orders
repayCrossMarginLoan() 🔐 POST /v1/cross-margin/orders/{orderId}/repay
getCrossMarginLoanOrders() 🔐 GET /v1/cross-margin/loan-orders
getCrossMarginBalance() 🔐 GET /v1/cross-margin/accounts/balance
getCrossMarginLimit() 🔐 GET /v2/margin/limit
getDepositAddress() 🔐 GET /v2/account/deposit/address
getWithdrawQuota() 🔐 GET /v2/account/withdraw/quota
getWithdrawAddress() 🔐 GET /v2/account/withdraw/address
submitWithdraw() 🔐 POST /v1/dw/withdraw/api/create
getWithdrawByClientId() 🔐 GET /v1/query/withdraw/client-order-id
cancelWithdraw() 🔐 POST /v1/dw/withdraw-virtual/{withdrawId}/cancel
getDepositWithdrawHistory() 🔐 GET /v1/query/deposit-withdraw
getVaspList() GET /v1/query/vasp-list
getBrokerUserRebateStatus() 🔐 GET /broker/v1/user_rebate_status
setBrokerSubUserFeeRate() 🔐 POST /broker/v1/sub-user/fee_rate/add
getBrokerAccountCapitalSnapshot() 🔐 POST /broker/v1/account_capital_snapshot_everyday
updateSubUserDeductMode() 🔐 POST /v2/sub-user/deduct-mode
getSubUserApiKey() 🔐 GET /v2/user/api-key
getUserUid() 🔐 GET /v2/user/uid
getSubUserList() 🔐 GET /v2/sub-user/user-list
updateSubUserLockStatus() 🔐 POST /v2/sub-user/management
getSubUserStatus() 🔐 GET /v2/sub-user/user-state
setSubUserTradableMarket() 🔐 POST /v2/sub-user/tradable-market
setSubUserTransferPermissions() 🔐 POST /v2/sub-user/transferability
getSubUserAccounts() 🔐 GET /v2/sub-user/account-list
createSubUserApiKey() 🔐 POST /v2/sub-user/api-key-generation
updateSubUserApiKey() 🔐 POST /v2/sub-user/api-key-modification
deleteSubUserApiKey() 🔐 POST /v2/sub-user/api-key-deletion
submitSubUserTransfer() 🔐 POST /v1/subuser/transfer
getSubUserDepositAddress() 🔐 GET /v2/sub-user/deposit-address
getSubUserDepositHistory() 🔐 GET /v2/sub-user/query-deposit
getSubUsersAggregatedBalance() 🔐 GET /v1/subuser/aggregate-balance
getSubUserBalance() 🔐 GET /v1/account/accounts/{subUid}
getSubUserEntrustUserList() 🔐 GET /v2/sub-user/entrust-user-list
getSubUserManagedTransferHistory() 🔐 GET /v2/sub-user/managed-transfer-history
getReferralRebateDetail() 🔐 GET /v2/invitee/rebate/detail
getReferralRebateHistory() 🔐 GET /v2/invitee/rebate/history
getReferralAllRebateDetail() 🔐 GET /v2/invitee/rebate/all_rebate/detail
getReferralMultipleRebateDetail() 🔐 GET /v2/invitee/rebate/batcher_rebate/detail
getReferralInvitedUserList() 🔐 GET /v2/invitee/rebate/referrals
getP2POrderHistory() GET /v1/api/c2c/order/history
getEarnProjectList() 🔐 GET /v1/earn/project/queryEarnProjectList
earnSubscribe() 🔐 POST /v1/earn/order/demand/add
earnRedeem() 🔐 POST /v1/earn/order/demand/redeem-order
getEarnUserAssets() 🔐 GET /v1/earn/order/user/assets/list

FuturesClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in FuturesClient.ts.

Function AUTH HTTP Method Endpoint
getTimestamp() GET /api/v1/timestamp
getHeartbeat() GET /heartbeat/
getLinearSwapAccountType() 🔐 GET /linear-swap-api/v3/swap_unified_account_type
updateLinearSwapAccountType() 🔐 POST /linear-swap-api/v3/swap_switch_account_type
getLinearSwapFundingRate() GET /linear-swap-api/v1/swap_funding_rate
getLinearSwapFundingRates() GET /linear-swap-api/v1/swap_batch_funding_rate
getLinearSwapHistoricalFundingRate() GET /linear-swap-api/v1/swap_historical_funding_rate
getLinearSwapLiquidationOrders() GET /linear-swap-api/v3/swap_liquidation_orders
getLinearSwapSettlementRecords() GET /linear-swap-api/v1/swap_settlement_records
getLinearSwapNetAccountRatio() GET /linear-swap-api/v1/swap_elite_account_ratio
getLinearSwapNetPositionRatio() GET /linear-swap-api/v1/swap_elite_position_ratio
getLinearSwapIsolatedSystemStatus() GET /linear-swap-api/v1/swap_api_state
getLinearSwapCrossTieredMargin() GET /linear-swap-api/v1/swap_cross_ladder_margin
getLinearSwapIsolatedTieredMargin() GET /linear-swap-api/v1/swap_ladder_margin
getLinearSwapEstimatedSettlementPrice() GET /linear-swap-api/v1/swap_estimated_settlement_price
getLinearSwapIsolatedAdjustFactor() GET /linear-swap-api/v1/swap_adjustfactor
getLinearSwapCrossAdjustFactor() GET /linear-swap-api/v1/swap_cross_adjustfactor
getLinearSwapRiskReserveBalance() GET /v1/insurance_fund_info
getLinearSwapRiskReserveHistory() GET /v1/insurance_fund_history
getLinearSwapContractPriceLimit() GET /linear-swap-api/v1/swap_price_limit
getLinearSwapOpenInterest() GET /linear-swap-api/v1/swap_open_interest
getLinearSwapContractInfo() GET /linear-swap-api/v1/swap_contract_info
getLinearSwapIndexPrice() GET /linear-swap-api/v1/swap_index
getLinearSwapIndexConstituents() GET /linear-swap-api/market/swap_contract_constituents
getLinearSwapContractElements() GET /linear-swap-api/v1/swap_query_elements
getLinearSwapMarketDepth() GET /linear-swap-ex/market/depth
getLinearSwapMarketBbo() GET /linear-swap-ex/market/bbo
getLinearSwapKlines() GET /linear-swap-ex/market/history/kline
getLinearSwapMarkKlines() GET /index/market/history/linear_swap_mark_price_kline
getLinearSwapTicker() GET /linear-swap-ex/market/detail/merged
getLinearSwapTickers() GET /v2/linear-swap-ex/market/detail/batch_merged
getLinearSwapLastTrade() GET /linear-swap-ex/market/trade
getLinearSwapTradeHistory() GET /linear-swap-ex/market/history/trade
getLinearSwapHistoricalOpenInterest() GET /linear-swap-api/v1/swap_his_open_interest
getLinearSwapPremiumIndexKlines() GET /index/market/history/linear_swap_premium_index_kline
getLinearSwapFundingRateKlines() GET /index/market/history/linear_swap_estimated_rate_kline
getLinearSwapBasisData() GET /index/market/history/linear_swap_basis
getLinearSwapAssetValuation() 🔐 POST /linear-swap-api/v1/swap_balance_valuation
getLinearSwapIsolatedAccountInfo() 🔐 POST /linear-swap-api/v1/swap_account_info
getLinearSwapCrossAccountInfo() 🔐 POST /linear-swap-api/v1/swap_cross_account_info
getLinearSwapIsolatedPositions() 🔐 POST /linear-swap-api/v1/swap_position_info
getLinearSwapCrossPositions() 🔐 POST /linear-swap-api/v1/swap_cross_position_info
getLinearSwapIsolatedAccountFull() 🔐 POST /linear-swap-api/v1/swap_account_position_info
getLinearSwapCrossAccountFull() 🔐 POST /linear-swap-api/v1/swap_cross_account_position_info
updateLinearSwapSubPermissions() 🔐 POST /linear-swap-api/v1/swap_sub_auth
getLinearSwapSubPermissions() 🔐 GET /linear-swap-api/v1/swap_sub_auth_list
getLinearSwapIsolatedSubAccounts() 🔐 POST /linear-swap-api/v1/swap_sub_account_list
getLinearSwapCrossSubAccounts() 🔐 POST /linear-swap-api/v1/swap_cross_sub_account_list
getLinearSwapIsolatedSubAccountsAssets() 🔐 POST /linear-swap-api/v1/swap_sub_account_info_list
getLinearSwapCrossSubAccountsAssets() 🔐 POST /linear-swap-api/v1/swap_cross_sub_account_info_list
getLinearSwapIsolatedSubAccountAssets() 🔐 POST /linear-swap-api/v1/swap_sub_account_info
getLinearSwapCrossSubAccountAssets() 🔐 POST /linear-swap-api/v1/swap_cross_sub_account_info
getLinearSwapIsolatedSubPositions() 🔐 POST /linear-swap-api/v1/swap_sub_position_info
getLinearSwapCrossSubPositions() 🔐 POST /linear-swap-api/v1/swap_cross_sub_position_info
getLinearSwapFinancialRecords() 🔐 POST /linear-swap-api/v3/swap_financial_record
getLinearSwapFinancialRecordsExact() 🔐 POST /linear-swap-api/v3/swap_financial_record_exact
getLinearSwapIsolatedAvailableLeverage() 🔐 POST /linear-swap-api/v1/swap_available_level_rate
getLinearSwapCrossAvailableLeverage() 🔐 POST /linear-swap-api/v1/swap_cross_available_level_rate
getLinearSwapOrderLimit() 🔐 POST /linear-swap-api/v1/swap_order_limit
getLinearSwapFee() 🔐 POST /linear-swap-api/v1/swap_fee
getLinearSwapIsolatedTransferLimit() 🔐 POST /linear-swap-api/v1/swap_transfer_limit
getLinearSwapCrossTransferLimit() 🔐 POST /linear-swap-api/v1/swap_cross_transfer_limit
getLinearSwapIsolatedPositionLimit() 🔐 POST /linear-swap-api/v1/swap_position_limit
getLinearSwapCrossPositionLimit() 🔐 POST /linear-swap-api/v1/swap_cross_position_limit
getLinearSwapIsolatedLeverageLimits() 🔐 POST /linear-swap-api/v1/swap_lever_position_limit
getLinearSwapCrossLeverageLimits() 🔐 POST /linear-swap-api/v1/swap_cross_lever_position_limit
transferLinearSwapMasterSub() 🔐 POST /linear-swap-api/v1/swap_master_sub_transfer
getLinearSwapMasterSubTransfers() 🔐 POST /linear-swap-api/v1/swap_master_sub_transfer_record
transferLinearSwapInner() 🔐 POST /linear-swap-api/v1/swap_transfer_inner
setLinearSwapCancelAfter() 🔐 POST /linear-swap-api/v1/linear-cancel-after
getLinearSwapCrossTradeState() 🔐 GET /linear-swap-api/v1/swap_cross_trade_state
getLinearSwapCrossTransferState() 🔐 GET /linear-swap-api/v1/swap_cross_transfer_state
updateLinearSwapIsolatedPositionMode() 🔐 POST /linear-swap-api/v1/swap_switch_position_mode
updateLinearSwapCrossPositionMode() 🔐 POST /linear-swap-api/v1/swap_cross_switch_position_mode
submitLinearSwapIsolatedOrder() 🔐 POST /linear-swap-api/v1/swap_order
submitLinearSwapCrossOrder() 🔐 POST /linear-swap-api/v1/swap_cross_order
submitLinearSwapIsolatedBatchOrders() 🔐 POST /linear-swap-api/v1/swap_batchorder
submitLinearSwapCrossBatchOrders() 🔐 POST /linear-swap-api/v1/swap_cross_batchorder
cancelLinearSwapIsolatedOrder() 🔐 POST /linear-swap-api/v1/swap_cancel
cancelLinearSwapCrossOrder() 🔐 POST /linear-swap-api/v1/swap_cross_cancel
cancelLinearSwapIsolatedAllOrders() 🔐 POST /linear-swap-api/v1/swap_cancelall
cancelLinearSwapCrossAllOrders() 🔐 POST /linear-swap-api/v1/swap_cross_cancelall
updateLinearSwapIsolatedLeverage() 🔐 POST /linear-swap-api/v1/swap_switch_lever_rate
updateLinearSwapCrossLeverage() 🔐 POST /linear-swap-api/v1/swap_cross_switch_lever_rate
getLinearSwapIsolatedOrderInfo() 🔐 POST /linear-swap-api/v1/swap_order_info
getLinearSwapCrossOrderInfo() 🔐 POST /linear-swap-api/v1/swap_cross_order_info
getLinearSwapIsolatedOrderDetail() 🔐 POST /linear-swap-api/v1/swap_order_detail
getLinearSwapCrossOrderDetail() 🔐 POST /linear-swap-api/v1/swap_cross_order_detail
getLinearSwapIsolatedOpenOrders() 🔐 POST /linear-swap-api/v1/swap_openorders
getLinearSwapCrossOpenOrders() 🔐 POST /linear-swap-api/v1/swap_cross_openorders
getLinearSwapIsolatedHistoryOrders() 🔐 POST /linear-swap-api/v3/swap_hisorders
getLinearSwapCrossHistoryOrders() 🔐 POST /linear-swap-api/v3/swap_cross_hisorders
getLinearSwapIsolatedHistoryOrdersExact() 🔐 POST /linear-swap-api/v3/swap_hisorders_exact
getLinearSwapCrossHistoryOrdersExact() 🔐 POST /linear-swap-api/v3/swap_cross_hisorders_exact
getLinearSwapIsolatedFills() 🔐 POST /linear-swap-api/v3/swap_matchresults
getLinearSwapCrossFills() 🔐 POST /linear-swap-api/v3/swap_cross_matchresults
getLinearSwapIsolatedFillsExact() 🔐 POST /linear-swap-api/v3/swap_matchresults_exact
getLinearSwapCrossFillsExact() 🔐 POST /linear-swap-api/v3/swap_cross_matchresults_exact
submitLinearSwapIsolatedLightningCloseOrder() 🔐 POST /linear-swap-api/v1/swap_lightning_close_position
submitLinearSwapCrossLightningCloseOrder() 🔐 POST /linear-swap-api/v1/swap_cross_lightning_close_position
getLinearSwapIsolatedPositionMode() 🔐 GET /linear-swap-api/v1/swap_position_side
getLinearSwapCrossPositionMode() 🔐 GET /linear-swap-api/v1/swap_cross_position_side
submitLinearSwapIsolatedTriggerOrder() 🔐 POST /linear-swap-api/v1/swap_trigger_order
submitLinearSwapCrossTriggerOrder() 🔐 POST /linear-swap-api/v1/swap_cross_trigger_order
cancelLinearSwapIsolatedTriggerOrder() 🔐 POST /linear-swap-api/v1/swap_trigger_cancel
cancelLinearSwapCrossTriggerOrder() 🔐 POST /linear-swap-api/v1/swap_cross_trigger_cancel
cancelLinearSwapIsolatedAllTriggerOrders() 🔐 POST /linear-swap-api/v1/swap_trigger_cancelall
cancelLinearSwapCrossAllTriggerOrders() 🔐 POST /linear-swap-api/v1/swap_cross_trigger_cancelall
getLinearSwapIsolatedTriggerOpenOrders() 🔐 POST /linear-swap-api/v1/swap_trigger_openorders
getLinearSwapCrossTriggerOpenOrders() 🔐 POST /linear-swap-api/v1/swap_cross_trigger_openorders
getLinearSwapIsolatedTriggerHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_trigger_hisorders
getLinearSwapCrossTriggerHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_cross_trigger_hisorders
submitLinearSwapIsolatedTpslOrder() 🔐 POST /linear-swap-api/v1/swap_tpsl_order
submitLinearSwapCrossTpslOrder() 🔐 POST /linear-swap-api/v1/swap_cross_tpsl_order
cancelLinearSwapIsolatedTpslOrder() 🔐 POST /linear-swap-api/v1/swap_tpsl_cancel
cancelLinearSwapCrossTpslOrder() 🔐 POST /linear-swap-api/v1/swap_cross_tpsl_cancel
cancelLinearSwapIsolatedAllTpslOrders() 🔐 POST /linear-swap-api/v1/swap_tpsl_cancelall
cancelLinearSwapCrossAllTpslOrders() 🔐 POST /linear-swap-api/v1/swap_cross_tpsl_cancelall
getLinearSwapIsolatedTpslOpenOrders() 🔐 POST /linear-swap-api/v1/swap_tpsl_openorders
getLinearSwapCrossTpslOpenOrders() 🔐 POST /linear-swap-api/v1/swap_cross_tpsl_openorders
getLinearSwapIsolatedTpslHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_tpsl_hisorders
getLinearSwapCrossTpslHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_cross_tpsl_hisorders
getLinearSwapIsolatedRelationTpslOrder() 🔐 POST /linear-swap-api/v1/swap_relation_tpsl_order
getLinearSwapCrossRelationTpslOrder() 🔐 POST /linear-swap-api/v1/swap_cross_relation_tpsl_order
submitLinearSwapIsolatedTrailingOrder() 🔐 POST /linear-swap-api/v1/swap_track_order
submitLinearSwapCrossTrailingOrder() 🔐 POST /linear-swap-api/v1/swap_cross_track_order
cancelLinearSwapIsolatedTrailingOrder() 🔐 POST /linear-swap-api/v1/swap_track_cancel
cancelLinearSwapCrossTrailingOrder() 🔐 POST /linear-swap-api/v1/swap_cross_track_cancel
cancelLinearSwapIsolatedAllTrailingOrders() 🔐 POST /linear-swap-api/v1/swap_track_cancelall
cancelLinearSwapCrossAllTrailingOrders() 🔐 POST /linear-swap-api/v1/swap_cross_track_cancelall
getLinearSwapIsolatedTrailingOpenOrders() 🔐 POST /linear-swap-api/v1/swap_track_openorders
getLinearSwapCrossTrailingOpenOrders() 🔐 POST /linear-swap-api/v1/swap_cross_track_openorders
getLinearSwapIsolatedTrailingHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_track_hisorders
getLinearSwapCrossTrailingHistoryOrders() 🔐 POST /linear-swap-api/v1/swap_cross_track_hisorders
getLinearSwapUnifiedAccountInfo() 🔐 GET /linear-swap-api/v3/unified_account_info
getLinearSwapUnifiedAssets() 🔐 GET /linear-swap-api/v3/linear_swap_overview_account_info
updateLinearSwapUnifiedFeeMethod() 🔐 POST /linear-swap-api/v3/linear_swap_fee_switch
getLinearSwapUnifiedMarginAdjustments() 🔐 GET /linear-swap-api/v3/fix_position_margin_change_record
updateLinearSwapUnifiedMargin() 🔐 POST /linear-swap-api/v3/fix_position_margin_change
getMultiAssetAccountBalance() 🔐 GET /v5/account/balance
getMultiAssetMode() 🔐 GET /v5/account/asset_mode
updateMultiAssetMode() 🔐 POST /v5/account/asset_mode
updateMultiAssetFeeCurrency() 🔐 POST /v5/account/fee_deduction_currency
getMultiAssetFeeCurrency() 🔐 GET /v5/account/fee_deduction_currency
getMultiAssetBills() 🔐 GET /v5/account/bills
submitMultiAssetOrder() 🔐 POST /v5/trade/order
submitMultiAssetBatchOrders() 🔐 POST /v5/trade/batch_orders
cancelMultiAssetOrder() 🔐 POST /v5/trade/cancel_order
cancelMultiAssetBatchOrders() 🔐 POST /v5/trade/cancel_batch_orders
cancelMultiAssetAllOrders() 🔐 POST /v5/trade/cancel_all_orders
closeMultiAssetPosition() 🔐 POST /v5/trade/position
closeMultiAssetAllPositions() 🔐 POST /v5/trade/position_all
getMultiAssetOpenOrders() 🔐 GET /v5/trade/order/opens
getMultiAssetFills() 🔐 GET /v5/trade/order/details
getMultiAssetOrderHistory() 🔐 GET /v5/trade/order/history
getMultiAssetOrderInfo() 🔐 GET /v5/trade/order
setMultiAssetCancelAfter() 🔐 POST /v5/trade/cancel-after
getMultiAssetPositions() 🔐 GET /v5/trade/position/opens
getMultiAssetLeverage() 🔐 GET /v5/position/lever
updateMultiAssetLeverage() 🔐 POST /v5/position/lever
getMultiAssetPositionMode() 🔐 GET /v5/position/mode
updateMultiAssetPositionMode() 🔐 POST /v5/position/mode
getMultiAssetRiskLimit() 🔐 GET /v5/position/risk/limit
getMultiAssetRiskLimitTiers() 🔐 GET /v5/position/risk/limit_tier
adjustMultiAssetMargin() 🔐 POST /v5/position/margin
getMultiAssetMarketRiskLimit() 🔐 GET /v5/market/risk/limit
getMultiAssetFeeCurrencies() 🔐 GET /v5/market/assets_deduction_currency
getMultiAssetCollateralAssets() 🔐 GET /v5/market/multi_assets_margin
getCoinMDeliveryAdjustFactor() GET /api/v1/contract_adjustfactor
getCoinMDeliveryHistoricalOpenInterest() GET /api/v1/contract_his_open_interest
getCoinMDeliveryTieredMargin() GET /api/v1/contract_ladder_margin
getCoinMDeliveryAccountRatio() GET /api/v1/contract_elite_account_ratio
getCoinMDeliveryPositionRatio() GET /api/v1/contract_elite_position_ratio
getCoinMDeliveryLiquidationOrders() GET /api/v3/contract_liquidation_orders
getCoinMDeliverySettlementRecords() GET /api/v1/contract_settlement_records
getCoinMDeliveryRiskReserveBalance() GET /v1/insurance_fund_info
getCoinMDeliveryRiskReserveHistory() GET /v1/insurance_fund_history
getCoinMDeliveryContractLimit() GET /api/v1/contract_price_limit
getCoinMDeliveryOpenInterest() GET /api/v1/contract_open_interest
getCoinMDeliveryDeliveryPrice() GET /api/v1/contract_delivery_price
getCoinMDeliveryEstimatedSettlementPrice() GET /api/v1/contract_estimated_settlement_price
getCoinMDeliverySystemStatus() GET /api/v1/contract_api_state
getCoinMDeliveryContractInfo() GET /api/v1/contract_contract_info
getCoinMDeliveryIndexPrice() GET /api/v1/contract_index
getCoinMDeliveryIndexConstituents() GET /api/market/contract_constituents
getCoinMDeliveryContractElements() GET /api/v1/contract_query_elements
getCoinMDeliveryMarketDepth() GET /market/depth
getCoinMDeliveryMarketBbo() GET /market/bbo
getCoinMDeliveryKlines() GET /market/history/kline
getCoinMDeliveryMarkKlines() GET /index/market/history/mark_price_kline
getCoinMDeliveryTicker() GET /market/detail/merged
getCoinMDeliveryTickers() GET /v2/market/detail/batch_merged
getCoinMDeliveryLastTrade() GET /market/trade
getCoinMDeliveryTradeHistory() GET /market/history/trade
getCoinMDeliveryIndexKlines() GET /index/market/history/index
getCoinMDeliveryBasisData() GET /index/market/history/basis
getCoinMDeliveryAssetValuation() 🔐 POST /api/v1/contract_balance_valuation
getCoinMDeliveryAccountInfo() 🔐 POST /api/v1/contract_account_info
getCoinMDeliveryPositionInfo() 🔐 POST /api/v1/contract_position_info
updateCoinMDeliverySubPermissions() 🔐 POST /api/v1/contract_sub_auth
getCoinMDeliverySubPermissions() 🔐 GET /api/v1/contract_sub_auth_list
getCoinMDeliverySubAccounts() 🔐 POST /api/v1/contract_sub_account_list
getCoinMDeliverySubAccountsAssets() 🔐 POST /api/v1/contract_sub_account_info_list
getCoinMDeliverySubAccountAssets() 🔐 POST /api/v1/contract_sub_account_info
getCoinMDeliverySubPositionInfo() 🔐 POST /api/v1/contract_sub_position_info
getCoinMDeliveryFinancialRecords() 🔐 POST /api/v3/contract_financial_record
getCoinMDeliveryFinancialRecordsExact() 🔐 POST /api/v3/contract_financial_record_exact
getCoinMDeliveryUserSettlementRecords() 🔐 POST /api/v1/contract_user_settlement_records
getCoinMDeliveryOrderLimit() 🔐 POST /api/v1/contract_order_limit
getCoinMDeliveryFee() 🔐 POST /api/v1/contract_fee
getCoinMDeliveryTransferLimit() 🔐 POST /api/v1/contract_transfer_limit
getCoinMDeliveryPositionLimit() 🔐 POST /api/v1/contract_position_limit
getCoinMDeliveryAccountFull() 🔐 POST /api/v1/contract_account_position_info
transferCoinMDeliveryMasterSub() 🔐 POST /api/v1/contract_master_sub_transfer
getCoinMDeliveryMasterSubTransfers() 🔐 POST /api/v1/contract_master_sub_transfer_record
getCoinMDeliveryApiStatus() 🔐 GET /api/v1/contract_api_trading_status
getCoinMDeliveryAvailableLeverage() 🔐 POST /api/v1/contract_available_level_rate
setCoinMDeliveryCancelAfter() 🔐 POST /api/v1/contract-cancel-after
submitCoinMDeliveryOrder() 🔐 POST /api/v1/contract_order
submitCoinMDeliveryBatchOrders() 🔐 POST /api/v1/contract_batchorder
cancelCoinMDeliveryOrder() 🔐 POST /api/v1/contract_cancel
cancelCoinMDeliveryAllOrders() 🔐 POST /api/v1/contract_cancelall
updateCoinMDeliveryLeverage() 🔐 POST /api/v1/contract_switch_lever_rate
getCoinMDeliveryOrderInfo() 🔐 POST /api/v1/contract_order_info
getCoinMDeliveryOrderDetail() 🔐 POST /api/v1/contract_order_detail
getCoinMDeliveryOpenOrders() 🔐 POST /api/v1/contract_openorders
getCoinMDeliveryHistoryOrders() 🔐 POST /api/v3/contract_hisorders
getCoinMDeliveryHistoryOrdersExact() 🔐 POST /api/v3/contract_hisorders_exact
getCoinMDeliveryFills() 🔐 POST /api/v3/contract_matchresults
getCoinMDeliveryFillsExact() 🔐 POST /api/v3/contract_matchresults_exact
submitCoinMDeliveryLightningCloseOrder() 🔐 POST /api/v1/lightning_close_position
submitCoinMDeliveryTriggerOrder() 🔐 POST /api/v1/contract_trigger_order
cancelCoinMDeliveryTriggerOrder() 🔐 POST /api/v1/contract_trigger_cancel
cancelCoinMDeliveryAllTriggerOrders() 🔐 POST /api/v1/contract_trigger_cancelall
getCoinMDeliveryTriggerOpenOrders() 🔐 POST /api/v1/contract_trigger_openorders
getCoinMDeliveryTriggerHistoryOrders() 🔐 POST /api/v1/contract_trigger_hisorders
submitCoinMDeliveryTpslOrder() 🔐 POST /api/v1/contract_tpsl_order
cancelCoinMDeliveryTpslOrder() 🔐 POST /api/v1/contract_tpsl_cancel
cancelCoinMDeliveryAllTpslOrders() 🔐 POST /api/v1/contract_tpsl_cancelall
getCoinMDeliveryTpslOpenOrders() 🔐 POST /api/v1/contract_tpsl_openorders
getCoinMDeliveryTpslHistoryOrders() 🔐 POST /api/v1/contract_tpsl_hisorders
getCoinMDeliveryRelationTpslOrder() 🔐 POST /api/v1/contract_relation_tpsl_order
submitCoinMDeliveryTrailingOrder() 🔐 POST /api/v1/contract_track_order
cancelCoinMDeliveryTrailingOrder() 🔐 POST /api/v1/contract_track_cancel
cancelCoinMDeliveryAllTrailingOrders() 🔐 POST /api/v1/contract_track_cancelall
getCoinMDeliveryTrailingOpenOrders() 🔐 POST /api/v1/contract_track_openorders
getCoinMDeliveryTrailingHistoryOrders() 🔐 POST /api/v1/contract_track_hisorders
getCoinMPerpAdjustFactor() GET /swap-api/v1/swap_adjustfactor
getCoinMPerpHistoricalOpenInterest() GET /swap-api/v1/swap_his_open_interest
getCoinMPerpTieredMargin() GET /swap-api/v1/swap_ladder_margin
getCoinMPerpAccountRatio() GET /swap-api/v1/swap_elite_account_ratio
getCoinMPerpPositionRatio() GET /swap-api/v1/swap_elite_position_ratio
getCoinMPerpEstimatedSettlementPrice() GET /swap-api/v1/swap_estimated_settlement_price
getCoinMPerpSystemStatus() GET /swap-api/v1/swap_api_state
getCoinMPerpFundingRate() GET /swap-api/v1/swap_funding_rate
getCoinMPerpFundingRates() GET /swap-api/v1/swap_batch_funding_rate
getCoinMPerpHistoricalFundingRate() GET /swap-api/v1/swap_historical_funding_rate
getCoinMPerpLiquidationOrders() GET /swap-api/v3/swap_liquidation_orders
getCoinMPerpSettlementRecords() GET /swap-api/v1/swap_settlement_records
getCoinMPerpContractInfo() GET /swap-api/v1/swap_contract_info
getCoinMPerpIndexPrice() GET /swap-api/v1/swap_index
getCoinMPerpContractElements() GET /swap-api/v1/swap_query_elements
getCoinMPerpIndexConstituents() GET /swap-api/market/swap_constituents
getCoinMPerpRiskReserveBalance() GET /v1/insurance_fund_info
getCoinMPerpRiskReserveHistory() GET /v1/insurance_fund_history
getCoinMPerpPriceLimit() GET /swap-api/v1/swap_price_limit
getCoinMPerpOpenInterest() GET /swap-api/v1/swap_open_interest
getCoinMPerpMarketDepth() GET /swap-ex/market/depth
getCoinMPerpMarketBbo() GET /swap-ex/market/bbo
getCoinMPerpKlines() GET /swap-ex/market/history/kline
getCoinMPerpMarkKlines() GET /index/market/history/swap_mark_price_kline
getCoinMPerpTicker() GET /swap-ex/market/detail/merged
getCoinMPerpTickers() GET /v2/swap-ex/market/detail/batch_merged
getCoinMPerpLastTrade() GET /swap-ex/market/trade
getCoinMPerpTradeHistory() GET /swap-ex/market/history/trade
getCoinMPerpPremiumIndexKlines() GET /index/market/history/swap_premium_index_kline
getCoinMPerpFundingRateKlines() GET /index/market/history/swap_estimated_rate_kline
getCoinMPerpBasisData() GET /index/market/history/swap_basis
getCoinMPerpAssetValuation() 🔐 POST /swap-api/v1/swap_balance_valuation
getCoinMPerpAccountInfo() 🔐 POST /swap-api/v1/swap_account_info
getCoinMPerpPositionInfo() 🔐 POST /swap-api/v1/swap_position_info
getCoinMPerpAccountFull() 🔐 POST /swap-api/v1/swap_account_position_info
getCoinMPerpSubPermissions() 🔐 GET /swap-api/v1/swap_sub_auth_list
updateCoinMPerpSubPermissions() 🔐 POST /swap-api/v1/swap_sub_auth
getCoinMPerpSubAccounts() 🔐 POST /swap-api/v1/swap_sub_account_list
getCoinMPerpSubAccountsAssets() 🔐 POST /swap-api/v1/swap_sub_account_info_list
getCoinMPerpSubAccountAssets() 🔐 POST /swap-api/v1/swap_sub_account_info
getCoinMPerpSubPositions() 🔐 POST /swap-api/v1/swap_sub_position_info
getCoinMPerpFinancialRecords() 🔐 POST /swap-api/v3/swap_financial_record
getCoinMPerpFinancialRecordsExact() 🔐 POST /swap-api/v3/swap_financial_record_exact
getCoinMPerpAvailableLeverage() 🔐 POST /swap-api/v1/swap_available_level_rate
getCoinMPerpOrderLimit() 🔐 POST /swap-api/v1/swap_order_limit
getCoinMPerpFee() 🔐 POST /swap-api/v1/swap_fee
getCoinMPerpTransferLimit() 🔐 POST /swap-api/v1/swap_transfer_limit
getCoinMPerpPositionLimit() 🔐 POST /swap-api/v1/swap_position_limit
transferCoinMPerpMasterSub() 🔐 POST /swap-api/v1/swap_master_sub_transfer
getCoinMPerpMasterSubTransfers() 🔐 POST /swap-api/v1/swap_master_sub_transfer_record
getCoinMPerpApiStatus() 🔐 GET /swap-api/v1/swap_api_trading_status
setCoinMPerpCancelAfter() 🔐 POST /swap-api/v1/swap-cancel-after
submitCoinMPerpOrder() 🔐 POST /swap-api/v1/swap_order
submitCoinMPerpBatchOrders() 🔐 POST /swap-api/v1/swap_batchorder
cancelCoinMPerpOrder() 🔐 POST /swap-api/v1/swap_cancel
cancelCoinMPerpAllOrders() 🔐 POST /swap-api/v1/swap_cancelall
updateCoinMPerpLeverage() 🔐 POST /swap-api/v1/swap_switch_lever_rate
getCoinMPerpOrderInfo() 🔐 POST /swap-api/v1/swap_order_info
getCoinMPerpOrderDetail() 🔐 POST /swap-api/v1/swap_order_detail
getCoinMPerpOpenOrders() 🔐 POST /swap-api/v1/swap_openorders
getCoinMPerpHistoryOrders() 🔐 POST /swap-api/v3/swap_hisorders
getCoinMPerpHistoryOrdersExact() 🔐 POST /swap-api/v3/swap_hisorders_exact
getCoinMPerpFills() 🔐 POST /swap-api/v3/swap_matchresults
getCoinMPerpFillsExact() 🔐 POST /swap-api/v3/swap_matchresults_exact
submitCoinMPerpLightningCloseOrder() 🔐 POST /swap-api/v1/swap_lightning_close_position
submitCoinMPerpTriggerOrder() 🔐 POST /swap-api/v1/swap_trigger_order
cancelCoinMPerpTriggerOrder() 🔐 POST /swap-api/v1/swap_trigger_cancel
cancelCoinMPerpAllTriggerOrders() 🔐 POST /swap-api/v1/swap_trigger_cancelall
getCoinMPerpTriggerOpenOrders() 🔐 POST /swap-api/v1/swap_trigger_openorders
getCoinMPerpTriggerHistoryOrders() 🔐 POST /swap-api/v1/swap_trigger_hisorders
submitCoinMPerpTpslOrder() 🔐 POST /swap-api/v1/swap_tpsl_order
cancelCoinMPerpTpslOrder() 🔐 POST /swap-api/v1/swap_tpsl_cancel
cancelCoinMPerpAllTpslOrders() 🔐 POST /swap-api/v1/swap_tpsl_cancelall
getCoinMPerpTpslOpenOrders() 🔐 POST /swap-api/v1/swap_tpsl_openorders
getCoinMPerpTpslHistoryOrders() 🔐 POST /swap-api/v1/swap_tpsl_hisorders
getCoinMPerpRelationTpslOrder() 🔐 POST /swap-api/v1/swap_relation_tpsl_order
submitCoinMPerpTrailingOrder() 🔐 POST /swap-api/v1/swap_track_order
cancelCoinMPerpTrailingOrder() 🔐 POST /swap-api/v1/swap_track_cancel
cancelCoinMPerpAllTrailingOrders() 🔐 POST /swap-api/v1/swap_track_cancelall
getCoinMPerpTrailingOpenOrders() 🔐 POST /swap-api/v1/swap_track_openorders
getCoinMPerpTrailingHistoryOrders() 🔐 POST /swap-api/v1/swap_track_hisorders
getCopyTraderInstruments() 🔐 GET /api/v6/copyTrading/trader/instruments
getCopyTraderStatistics() 🔐 GET /api/v6/copyTrading/trader/statistics
getCopyTraderProfitSharingHistory() 🔐 GET /api/v6/copyTrading/trader/profit-sharing-history
getCopyTraderProfitSharingHistorySummary() 🔐 GET /api/v6/copyTrading/trader/profit-sharing-history-summary
getCopyTraderUPNLSharingSummary() 🔐 GET /api/v6/copyTrading/trader/unrealized-profit-sharing-summary
getCopyTraderFollowers() 🔐 GET /api/v6/copyTrading/trader/followers
removeCopyTraderFollower() 🔐 POST /api/v6/copyTrading/trader/follower
submitCopyTraderTransfer() 🔐 POST /api/v6/copyTrading/trader/transfer
updateCopyTraderFollowerSettings() 🔐 POST /api/v6/copyTrading/trader/follower-settings
getCopyTraderConfig() 🔐 POST /api/v6/copyTrading/trader/config
createCopyTraderApikey() 🔐 POST /api/v6/copyTrading/trader/apikey

WebsocketAPIClient.ts

This table includes all endpoints from the official Exchange API docs and corresponding SDK functions for each endpoint that are found in WebsocketAPIClient.ts.

This client provides WebSocket API endpoints which allow for faster interactions with the HTX API via a WebSocket connection.

Function AUTH HTTP Method Endpoint
submitSpotOrder() 🔐 WS create-order
submitSpotBatchOrders() 🔐 WS create-batchorder
submitSpotMarginOrder() 🔐 WS create-margin-order
cancelSpotOrders() 🔐 WS cancel
cancelAllSpotOrders() 🔐 WS cancelall
submitLinearSwapOrder() 🔐 WS create_order
submitLinearSwapCrossOrder() 🔐 WS create_cross_order
submitLinearSwapBatchOrders() 🔐 WS create_batchorder
submitLinearSwapCrossBatchOrders() 🔐 WS create_cross_batchorder
cancelLinearSwapOrder() 🔐 WS cancel
cancelLinearSwapCrossOrder() 🔐 WS cross_cancel
cancelAllLinearSwapOrders() 🔐 WS cancelall
cancelAllLinearSwapCrossOrders() 🔐 WS cross_cancelall
placeLinearSwapOrder() 🔐 WS place_order
placeLinearSwapBatchOrders() 🔐 WS place_batch_orders
cancelLinearSwapV5Order() 🔐 WS cancel_order
cancelLinearSwapV5BatchOrders() 🔐 WS cancel_batch_orders
cancelAllLinearSwapV5Orders() 🔐 WS cancel_all_orders
submitCoinDeliveryOrder() 🔐 WS create_order
submitCoinDeliveryBatchOrders() 🔐 WS create_batchorder
cancelCoinDeliveryOrder() 🔐 WS cancel
cancelAllCoinDeliveryOrders() 🔐 WS cancelall
submitCoinSwapOrder() 🔐 WS create_order
submitCoinSwapBatchOrders() 🔐 WS create_batchorder
cancelCoinSwapOrder() 🔐 WS cancel
cancelAllCoinSwapOrders() 🔐 WS cancelall