assets

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

KuCoin Assets Skill

KuCoin资产管理Skill

Assets management on KuCoin using authenticated API endpoints. Requires API Key, API Secret, and Passphrase for all endpoints. Return the result in JSON format.
Note: This skill only supports Classic REST API GET endpoints (read-only operations).
通过已认证的API端点进行KuCoin资产管理所有端点均需要API Key、API SecretPassphrase返回结果为JSON格式.
注意本Skill仅支持Classic REST API的GET端点只读operations.

Quick Reference

快速参考

Classic API -- Account & Funding

Classic API --账户与资金

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v2/user-info
Get Account Summary InfoNoneNoneYes
GET /api/v1/user/api-key
Get Apikey InfoNoneNoneYes
GET /api/v1/hf/accounts/opened
Get Account Type - SpotNoneNoneYes
GET /api/v1/accounts
Get Account List - SpotNonecurrency, typeYes
GET /api/v1/accounts/{accountId}
Get Account Detail - SpotaccountId (path)NoneYes
GET /api/v3/margin/accounts
Get Account - Cross Margin. Note: Requires margin trading to be enabled on the account.NonequoteCurrency, queryTypeYes
GET /api/v3/isolated/accounts
Get Account - Isolated Margin. Note: Requires margin trading to be enabled on the account.Nonesymbol, quoteCurrency, queryTypeYes
GET /api/v1/account-overview
Get Account - Futures. Note: Must use Futures base URL (
https://api-futures.kucoin.com
).
NonecurrencyYes
GET /api/v1/accounts/ledgers
Get Account Ledgers - Spot/MarginNonecurrency, direction, bizType, startAt, endAt, currentPage, pageSizeYes
GET /api/v1/hf/accounts/ledgers
Get Account Ledgers - Trade_hfNonecurrency, direction, bizType, lastId, limit, startAt, endAtYes
GET /api/v3/hf/margin/account/ledgers
Get Account Ledgers - Margin_hfNonecurrency, direction, bizType, lastId, limit, startAt, endAtYes
GET /api/v1/transaction-history
Get Account Ledgers - Futures. Note: Must use Futures base URL (
https://api-futures.kucoin.com
).
Nonecurrency, type, offset, forward, maxCount, startAt, endAtYes
Endpoint描述必填参数可选参数认证要求
GET /api/v2/user-info
获取账户汇总信息NoneNoneYes
GET /api/v1/user/api-key
获取API密钥信息NoneNoneYes
GET /api/v1/hf/accounts/opened
获取账户类型 -现货NoneNoneYes
GET /api/v1accounts
获取账户列表 -现货Nonecurrency, typeYes
GET /api/v1accounts/{accountId}
获取账户详情 -现货accountId path parameterNoneYes
GET /api/v3margin/accounts
获取账户 -Cross Margin. 注意账户需已开通margin trading.NonequoteCurrency, queryTypeYes
GET /api/v3isolatedaccounts
获取账户 -Isolated Margin. 注意账户需已开通margin trading.Nonesymbol quoteCurrencyqueryTypeYes
GET /api/v1account-overview
获取账户 -Futures注意必须使用Futures base URL (
https://api-futureskucoincom
).
NonecurrencyYes
GET /api/v1accounts/ledgers
获取账户流水 -Spot/MarginNonecurrency directionbizTypestartAtendAtcurrentPagepageSizeYes
GET /api/v1hfaccounts/ledgers
获取账户流水 -Trade_hfNonecurrency directionbizTypelastIdlimitstartAtendAtYes
GET /api/v3hfmarginaaccount/ledgers
获取账户流水 -Margin_hfNonecurrency directionbizTypelastIdlimitstartAtendAtYes
GET /api/v1transaction-history
获取账户流水 -Futures注意必须使用Futures base URL (
https://api-futureskucoincom
)
Nonecurrency typeoffsetforwardmaxCountstartAtendAtYes
-----------------------------------------------------------
GET /api/v2subuser
获取子账户列表 -汇总信息NonecurrentPagepageSizeYes
GET /api/v1sub-accounts/{subUserId}
获取子账户详情 -余额subUserId path parameterincludeBaseAmountbaseCurrencybaseAmountYes
GET /api/v2sub-accounts
获取子账户列表 -Spot Balance V2NonecurrentPagepageSizeYes
GET /api/v1account-overview-all
获取子账户列表 -Futures Balance V2注意必须使用Futures base URL (
https://api-futureskucoincom
)
NonecurrencyYes
-----------------------------------------------------------
GET /api/v1sub/api-key
获取子账户API列表subNameapiKeyYes
-----------------------------------------------------------
GET /api/v3deposit-addresses
获取Deposit Address V3currencychainYes
GET /api/v1deposits
获取Deposit HistorycurrencystatusstartAtendAtcurrentPagepageSizeYes
-----------------------------------------------------------
GET /api/v1withdrawals/quotas
获取Withdrawal QuotascurrencychainYes
GET /api/v1withdrawals/{withdrawalId}
获取Withdrawal History By IDwithdrawalId path parameterNoneYes
GET /api/v1withdrawals
获取Withdrawal HistorycurrencystatusstartAtendAtcurrentPagepageSizeYes
-----------------------------------------------------------
GET /api/v1accounts/transferable
获取Transfer Quotascurrency typetagYes
-----------------------------------------------------------
GET /api/v1base-fee
获取Basic Fee -Spot/MarginNonecurrencyTypeYes
GET /api/v1trade-fees
获取Actual Fee -FuturessymbolsNoneYes

Classic API -- Sub Account

参数

通用参数

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v2/sub/user
Get Sub-Account List - Summary InfoNonecurrentPage, pageSizeYes
GET /api/v1/sub-accounts/{subUserId}
Get Sub-Account Detail - BalancesubUserId (path)includeBaseAmount, baseCurrency, baseAmountYes
GET /api/v2/sub-accounts
Get Sub-Account List - Spot Balance (V2)NonecurrentPage, pageSizeYes
GET /api/v1/account-overview-all
Get Sub-Account List - Futures Balance (V2). Note: Must use Futures base URL (
https://api-futures.kucoin.com
).
NonecurrencyYes
  • **currency货币代码例如
    BTCUSDTETH
    部分端点支持用逗号分隔查询多种货币.
  • chain货币的chain ID例如
    ethtrxbsc ton2arbitrum
    推荐用于多链货币.
  • startAt / endAtUnix epoch毫秒级的起始结束时间.
  • currentPage当前请求页码默认值1.
  • pageSize每页结果数量不同端点有所差异典型最小值最大值.
  • lastId上一批数据的最后一条ID用于cursor-based pagination.
  • direction划转方向
    in
    out
    .

Classic API -- Sub Account API

Classic API账户参数

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v1/sub/api-key
Get Sub-Account API ListsubNameapiKeyYes
  • typeSpot Account List账户类型
    mainfunding
    tradetrade.
  • accountId账户IDaccount detail path parameter.
  • quoteCurrency杠杆账户计价货币
    USDTKCSBTC
    .
  • queryTypeCross MarginMARGINMARGIN_V2ALL.
  • queryTypeIsolated MarginISOLATEDISOLATED_V2ALL.
  • bizTypeSpot/Margin LedgerDEPOSITWITHDRAWTRANSFERSUB_TRANSFERTRADE_EXCHANGEMARGIN_EXCHANGEKUCOIN_BONUSBROKER_TRANSFER.
  • bizTypeTrade_hf LedgerTRADE_EXCHANGETRANSFERSUB_TRANSFERRETURNED_FEESDEDUCTION_FEESOTHER.
  • bizTypeMargin_hf LedgerTRANSFERSUB_TRANSFERMARGIN_EXCHANGEISOLATED_EXCHANGELIQUIDATIONASSERT_RETURN.
  • typeFutures LedgerRealisedPNLDepositWithdrawalTransferInTransferOut.
  • offsetFutures Ledger分页起始偏移量.
  • forward布尔值true正向默认false反向.
  • maxCountFutures Ledger每页显示数量默认.
  • limitHF Ledger查询每页结果数量.

Classic API -- Deposit

Sub Account参数subUserId子账户用户IDpath parameter.

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v3/deposit-addresses
Get Deposit Address (V3)currencychainYes
GET /api/v1/deposits
Get Deposit Historycurrencystatus, startAt, endAt, currentPage, pageSizeYes
subName子账户名称API key queries. apiKey子账户API key过滤参数. includeBaseAmount布尔值true显示所有货币包括零余额. baseCurrency转换显示资产价值的货币. baseAmount过滤条件余额≥该金额.

Classic API -- Withdrawals

Deposit & Withdrawal参数statusDeposit HistoryPROCESSINGSUCCESSFAILUREWAIT_TRM_MGTTRM_MGT_REJECTED.

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v1/withdrawals/quotas
Get Withdrawal QuotascurrencychainYes
GET /api/v1/withdrawals/{withdrawalId}
Get Withdrawal History By IDwithdrawalId (path)NoneYes
GET /api/v1/withdrawals
Get Withdrawal Historycurrencystatus, startAt, endAt, currentPage, pageSizeYes
statusWithdrawal HistoryPROCESSINGREVIEWWALLET_PROCESSINGSUCCESSFAILURE. withdrawalId提现IDpath parameter.

Classic API -- Transfer

Transfer参数typeTransfer Quotas账户类型MAINTRADEMARGINISOLATEDMARGIN_V2ISOLATED_V2.

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v1/accounts/transferable
Get Transfer Quotascurrency, typetagYes
tagISOLATED账户类型时需交易对例如
BTC-USDT
.

Classic API -- Trade Fee

Trade Fee参数currencyType货币类型加密货币法币默认.

EndpointDescriptionRequiredOptionalAuthentication
GET /api/v1/base-fee
Get Basic Fee - Spot/MarginNonecurrencyTypeYes
GET /api/v1/trade-fees
Get Actual Fee - FuturessymbolsNoneYes

symbols合约手续费查询交易对例如XBTUSDTM.

Parameters

枚举值Account Types Classic API

Common Parameters

  • currency: Currency code (e.g.,
    BTC
    ,
    USDT
    ,
    ETH
    ). Some endpoints support querying multiple currencies separated by commas.
  • chain: The chain ID of a currency (e.g.,
    eth
    ,
    trx
    ,
    bsc
    ,
    ton2
    ,
    arbitrum
    ). Recommended for multi-chain currencies.
  • startAt / endAt: Start and end time in milliseconds since Unix epoch.
  • currentPage: Current request page, default 1.
  • pageSize: Number of results per page. Varies by endpoint (typical min 10, max 100-500).
  • lastId: The ID of the last set of data from the previous batch. Used for cursor-based pagination.
  • direction: Direction of transfer:
    in
    or
    out
    .
| 值 | 描述 | Value | Description | |-------|-------------| mainfunding account. tradetrade account. MAINfunding accounttransfer context. TRADEtrade accounttransfer context. CONTRACTfutures accounttransfer context. MARGINmargin accountHF. ISOLATEDisolated accountHF. MARGIN_V2legacy margin accountphasing out. ISOLATED_V2legacy isolated accountphasing out.

Classic API Account Parameters

Deposit StatusPROCESSING处理中SUCCESS成功FAILURE失败WAIT_TRM_MGT等待旅行规则TRM_MGT_REJECTED拒绝.

Withdrawal StatusREVIEW审核PROCESSING钱包处理SUCCESS成功FAILURE失败.

  • type (Spot Account List): Account type:
    main
    (funding),
    trade
    (spot).
  • accountId: Account ID (path parameter for account detail).
  • quoteCurrency: Quote currency for margin accounts:
    USDT
    ,
    KCS
    ,
    BTC
    .
  • queryType (Cross Margin):
    MARGIN
    ,
    MARGIN_V2
    ,
    ALL
    .
  • queryType (Isolated Margin):
    ISOLATED
    ,
    ISOLATED_V2
    ,
    ALL
    .
  • bizType (Spot/Margin Ledger):
    DEPOSIT
    ,
    WITHDRAW
    ,
    TRANSFER
    ,
    SUB_TRANSFER
    ,
    TRADE_EXCHANGE
    ,
    MARGIN_EXCHANGE
    ,
    KUCOIN_BONUS
    ,
    BROKER_TRANSFER
    .
  • bizType (Trade_hf Ledger):
    TRADE_EXCHANGE
    ,
    TRANSFER
    ,
    SUB_TRANSFER
    ,
    RETURNED_FEES
    ,
    DEDUCTION_FEES
    ,
    OTHER
    .
  • bizType (Margin_hf Ledger):
    TRANSFER
    ,
    MARGIN_EXCHANGE
    ,
    ISOLATED_EXCHANGE
    ,
    LIQUIDATION
    ,
    ASSERT_RETURN
    .
  • type (Futures Ledger):
    RealisedPNL
    ,
    Deposit
    ,
    Withdrawal
    ,
    TransferIn
    ,
    TransferOut
    .
  • offset: Start offset for futures ledger pagination.
  • forward: Boolean.
    true
    for forward lookup (default),
    false
    for backward.
  • maxCount: Displayed size per page for futures ledger. Default 50.
  • limit: Number of results per page for HF ledger queries.

Sub Account Parameters

认证所有端点需提供KuCoin API凭证.

  • subUserId: The user ID of a sub-account (path parameter).
  • subName: Sub-account name (for API key queries).
  • apiKey: API key of the sub-account (filter parameter).
  • includeBaseAmount: Boolean.
    true
    to display all currencies including zero-balance ones.
  • baseCurrency: Currency used to convert and display asset values.
  • baseAmount: Filter: currency balance must be >= this amount.

必填凭证API KeyKuCoin API keyKC-API-KEY header. API SecretKuCoin API secretHMAC-SHA256签名. Passphrase创建API key时设置KC-API-PASSPHRASE headerAPI Key Version加密. 基础URL环境Production URLapi kucoincom.

Deposit & Withdrawal Parameters

安全共享凭证用户可发送文件提供格式如下bashyour-api-key your-api-secret your-passphrase.

  • status (Deposit History):
    PROCESSING
    ,
    SUCCESS
    ,
    FAILURE
    ,
    WAIT_TRM_MGT
    ,
    TRM_MGT_REJECTED
    .
  • status (Withdrawal History):
    PROCESSING
    ,
    REVIEW
    ,
    WALLET_PROCESSING
    ,
    SUCCESS
    ,
    FAILURE
    .
  • withdrawalId: Withdrawal ID (path parameter).

切勿泄露API KeySecretPassphrase文件位置. 切勿发送至除KuCoin生产API外网站. 切勿显示完整凭证API Key显示前+后例如68d4a...841d. Secret Key仅显示最后例如***...b2340. Passphrase完全隐藏***... 示例回复账户mainAPI Key68d4a...841dSecret***...b2340Passphrase***...环境Production. 账户列表仅显示名称环境KuCoin账户mainProduction sub-keysProduction. 交易操作修改数据划转提现创建子账户需用户确认输入CONFIRM.

Transfer Parameters

KuCoin账户mainAPI Keyyour_api_keySecretyour_api_secretPassphraseyour_passphrase

  • type (Transfer Quotas): Account type:
    MAIN
    ,
    TRADE
    ,
    MARGIN
    ,
    ISOLATED
    ,
    MARGIN_V2
    ,
    ISOLATED_V2
    .
  • tag: Trading pair required when account type is
    ISOLATED
    (e.g.,
    BTC-USDT
    ).

Trade Fee Parameters

  • currencyType: Currency type:
    0
    (crypto currency),
    1
    (fiat currency). Default
    0
    .
  • symbols: Trading pair symbols for futures fee query (e.g.,
    XBTUSDTM
    ).

Enums

Account Types (Classic API)

ValueDescription
main
Funding account
trade
Spot trading account
MAIN
Funding account (transfer context)
TRADE
Spot trading account (transfer context)
CONTRACT
Futures account (transfer context)
MARGIN
Cross margin account (HF)
ISOLATED
Isolated margin account (HF)
MARGIN_V2
Cross margin account (legacy, phasing out)
ISOLATED_V2
Isolated margin account (legacy, phasing out)

Deposit Status

ValueDescription
PROCESSING
Deposit is being processed
SUCCESS
Deposit completed successfully
FAILURE
Deposit failed
WAIT_TRM_MGT
Waiting for travel rule management
TRM_MGT_REJECTED
Rejected by travel rule management

Withdrawal Status

ValueDescription
REVIEW
Under review
PROCESSING
Processing
WALLET_PROCESSING
Wallet processing
SUCCESS
Withdrawal completed successfully
FAILURE
Withdrawal failed

Authentication

For all endpoints, you must provide KuCoin API credentials.
Required credentials:
  • API Key: Your KuCoin API key (sent as
    KC-API-KEY
    header)
  • API Secret: Your KuCoin API secret (used for HMAC-SHA256 signing)
  • Passphrase: The passphrase you set when creating the API key (sent as
    KC-API-PASSPHRASE
    header, encrypted for API Key Version 2)
Base URLs:
EnvironmentURL
Production
https://api.kucoin.com

Security

Share Credentials

Users can provide KuCoin API credentials by sending a file where the content is in the following format:
bash
your-api-key
your-api-secret
your-passphrase

Never Disclose API Key, Secret, and Passphrase

Never disclose the location of the API key, secret, and passphrase file.
Never send the API key, secret, or passphrase to any website other than the production KuCoin API.

Never Display Full Secrets

When showing credentials to users:
  • API Key: Show first 5 + last 4 characters:
    68d4a...841d
  • Secret Key: Always mask, show only last 5:
    ***...b2340
  • Passphrase: Always fully mask:
    ***...
Example response when asked for credentials: Account: main API Key: 68d4a...841d Secret: ***...b2340 Passphrase: ***... Environment: Production

Listing Accounts

When listing accounts, show names and environment only -- never keys: KuCoin Accounts:
  • main (Production)
  • sub-keys (Production)

Transactions

When performing operations that modify data (transfers, withdrawals, creating sub-accounts), always confirm with the user before proceeding by asking them to write "CONFIRM" to proceed.

KuCoin Accounts

main

  • API Key: your_api_key
  • Secret: your_api_secret
  • Passphrase: your_passphrase