Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/tiagosiebler/kucoin-api/llms.txt

Use this file to discover all available pages before exploring further.

The SpotClient funding methods cover the complete lifecycle of moving funds into, out of, and between KuCoin accounts. This includes creating and querying deposit addresses (using the modern V3 API), tracking deposit history, submitting and cancelling withdrawals (including the recommended V3 withdrawal endpoint), checking withdrawal quotas, and transferring balances between your main, trade, margin, futures, and sub-accounts via the flexible submitFlexTransfer endpoint. All funding endpoints require authentication.
Prefer createDepositAddressV3, getDepositAddressesV3, and submitWithdrawV3 for all new integrations. The V1/V2 deposit address and submitWithdraw methods are deprecated.

Deposit Addresses

Creates a new deposit address for the specified currency and chain. If a deposit address already exists, this returns the existing address.Endpoint: POST api/v3/deposit-address/create โ€” ๐Ÿ”’ Auth required
createDepositAddressV3(params: CreateDepositAddressV3Request): Promise<APISuccessResponse<CreateDepositAddressV3Response>>
currency
string
required
Currency ticker, e.g. "USDT".
chain
string
Network chain (e.g. "ETH", "TRX", "SOL"). Required for multi-chain currencies.
to
string
Account to deposit into: "main" (funding account) or "trade" (spot trading account).
amount
string
Pre-set amount for fixed-amount deposit addresses (supported on select networks).
import { SpotClient } from 'kucoin-api';

const client = new SpotClient({
  apiKey: 'apiKeyHere',
  apiSecret: 'apiSecretHere',
  apiPassphrase: 'apiPassPhraseHere',
});

const address = await client.createDepositAddressV3({
  currency: 'USDT',
  chain: 'TRX',
  to: 'main',
});
console.log('Deposit address:', address.data.address);
Returns all deposit addresses for a currency. If the returned data is empty, call createDepositAddressV3 first.Endpoint: GET api/v3/deposit-addresses โ€” ๐Ÿ”’ Auth required
getDepositAddressesV3(params: { currency: string; amount?: string; chain?: string }): Promise<APISuccessResponse<DepositAddressV3[]>>
currency
string
required
Currency ticker to query.
chain
string
Filter by network chain.
amount
string
Pre-set amount filter for fixed-amount addresses.
Returns a single deposit address using the legacy V1 endpoint.Endpoint: GET api/v1/deposit-addresses โ€” ๐Ÿ”’ Auth required
getDepositAddressV1(params: { currency: string; chain?: string }): Promise<APISuccessResponse<DepositAddress>>
Deprecated โ€” use getDepositAddressesV3 instead.
Returns multiple deposit addresses using the V2 endpoint.Endpoint: GET api/v2/deposit-addresses โ€” ๐Ÿ”’ Auth required
getDepositAddressesV2(params: { currency: string }): Promise<APISuccessResponse<DepositAddressV2[]>>
Deprecated โ€” use getDepositAddressesV3 instead.

Deposits

Returns a paginated deposit history. Items are sorted newest-first.Endpoint: GET api/v1/deposits โ€” ๐Ÿ”’ Auth required
getDeposits(params?: GetDepositsRequest): Promise<APISuccessResponse<Deposits>>
currency
string
Filter by currency ticker.
status
string
Filter by status: "PROCESSING", "SUCCESS", or "FAILURE".
startAt
number
Start timestamp in milliseconds.
endAt
number
End timestamp in milliseconds.
currentPage
number
Page number (default: 1).
pageSize
number
Items per page (default: 50, max: 500).
import { SpotClient } from 'kucoin-api';

const client = new SpotClient({
  apiKey: 'apiKeyHere',
  apiSecret: 'apiSecretHere',
  apiPassphrase: 'apiPassPhraseHere',
});

const deposits = await client.getDeposits({
  currency: 'USDT',
  status: 'SUCCESS',
});
console.log(deposits.data.items);
Returns historical deposit records from the legacy V1 endpoint.Endpoint: GET api/v1/hist-deposits โ€” ๐Ÿ”’ Auth required
getHistoricalDepositsV1(params?: GetDepositsRequest): Promise<APISuccessResponse<V1HistoricalDeposits>>
Deprecated โ€” use getDeposits instead.

Withdrawals

Returns the current withdrawal quota for a currency: minimum/maximum amounts, available quota, and applicable fees.Endpoint: GET api/v1/withdrawals/quotas โ€” ๐Ÿ”’ Auth required
getWithdrawalQuotas(params: { currency: string; chain?: string }): Promise<APISuccessResponse<WithdrawalQuotas>>
currency
string
required
Currency ticker.
chain
string
Network chain to check quotas for.
currency
string
Currency ticker.
limitBTCAmount
string
Remaining 24-hour withdrawal limit expressed in BTC.
usedBTCAmount
string
Used portion of the 24-hour BTC limit.
remainAmount
string
Remaining withdrawable amount in the currencyโ€™s own unit.
withdrawMinFee
string
Minimum withdrawal fee.
innerWithdrawMinFee
string
Fee for on-platform (internal) withdrawals.
Submits a withdrawal request using the V3 API, which supports address-based, UID, email, and phone number withdrawal targets.Endpoint: POST api/v3/withdrawals โ€” ๐Ÿ”’ Auth required
submitWithdrawV3(params: SubmitWithdrawV3Request): Promise<APISuccessResponse<{ withdrawalId: string }>>
currency
string
required
Currency to withdraw, e.g. "USDT".
toAddress
string
required
Destination address, UID, email, or phone number (depending on withdrawType).
amount
number
required
Withdrawal amount.
withdrawType
string
required
Destination type: "ADDRESS", "UID", "MAIL", or "PHONE".
chain
string
Network chain for address withdrawals (e.g. "TRX", "ETH").
memo
string
Memo or tag required by some networks (e.g. XRP, XLM).
isInner
boolean
Set true for on-platform (KuCoin-to-KuCoin) transfers.
remark
string
Optional note for the withdrawal.
feeDeductType
string
Fee deduction method: "INTERNAL" (deduct from withdrawal amount) or "EXTERNAL" (deduct separately).
import { SpotClient } from 'kucoin-api';

const client = new SpotClient({
  apiKey: 'apiKeyHere',
  apiSecret: 'apiSecretHere',
  apiPassphrase: 'apiPassPhraseHere',
});

const withdrawal = await client.submitWithdrawV3({
  currency: 'USDT',
  toAddress: 'TXyz...abc',
  amount: 50,
  withdrawType: 'ADDRESS',
  chain: 'TRX',
});
console.log('Withdrawal ID:', withdrawal.data.withdrawalId);
Cancels a pending withdrawal. Only withdrawals in PROCESSING status can be cancelled.Endpoint: DELETE api/v1/withdrawals/{withdrawalId} โ€” ๐Ÿ”’ Auth required
cancelWithdrawal(params: { withdrawalId: string }): Promise<APISuccessResponse<string | null>>
withdrawalId
string
required
The ID of the withdrawal to cancel (returned by submitWithdrawV3).
Returns a paginated withdrawal history, sorted newest-first.Endpoint: GET api/v1/withdrawals โ€” ๐Ÿ”’ Auth required
getWithdrawals(params?: GetWithdrawalsRequest): Promise<APISuccessResponse<Withdrawals>>
currency
string
Filter by currency.
status
string
Filter by status: "PROCESSING", "WALLET_PROCESSING", "SUCCESS", or "FAILURE".
startAt
number
Start timestamp in milliseconds.
endAt
number
End timestamp in milliseconds.
currentPage
number
Page number.
pageSize
number
Items per page (max: 500).
Returns historical withdrawal records from the legacy V1 endpoint.Endpoint: GET api/v1/hist-withdrawals โ€” ๐Ÿ”’ Auth required
getHistoricalWithdrawalsV1(params?: GetWithdrawalsRequest): Promise<APISuccessResponse<HistoricalWithdrawalsV1>>
currency
string
Filter by currency.
status
string
Filter by status: "PROCESSING", "WALLET_PROCESSING", "SUCCESS", or "FAILURE".
startAt
number
Start timestamp in milliseconds.
endAt
number
End timestamp in milliseconds.
currentPage
number
Page number.
pageSize
number
Items per page (max: 500).
Deprecated โ€” use getWithdrawals instead.
Returns the full details of a single withdrawal by its ID.Endpoint: GET api/v1/withdrawals/{withdrawalId} โ€” ๐Ÿ”’ Auth required
getWithdrawalById(params: { withdrawalId: string }): Promise<APISuccessResponse<WithdrawalById>>
withdrawalId
string
required
Withdrawal ID to look up.

Transfers

Returns the transferable balance for a specified account type and currency.Endpoint: GET api/v1/accounts/transferable โ€” ๐Ÿ”’ Auth required
getTransferable(params: GetTransferableRequest): Promise<APISuccessResponse<TransferableFunds>>
currency
string
required
Currency ticker.
type
string
required
Account type: "MAIN", "TRADE", "TRADE_HF", "MARGIN", "ISOLATED", "OPTION", "MARGIN_V2", or "ISOLATED_V2".
tag
string
Additional tag for isolated margin accounts (the trading pair symbol).
Transfers funds between accounts in a flexible manner โ€” including master-to-sub, sub-to-master, and internal transfers across account types. This is the recommended transfer endpoint for all new integrations.Endpoint: POST api/v3/accounts/universal-transfer โ€” ๐Ÿ”’ Auth required
submitFlexTransfer(params: FlexTransferRequest): Promise<APISuccessResponse<{ orderId: string }>>
clientOid
string
required
Unique client-assigned transfer ID.
amount
string
required
Amount to transfer.
fromAccountType
string
required
Source account type: "MAIN", "TRADE", "CONTRACT", "MARGIN", "ISOLATED", "TRADE_HF", "MARGIN_V2", "ISOLATED_V2", "UNIFIED", or "OPTION".
toAccountType
string
required
Destination account type (same options as fromAccountType).
type
string
required
Transfer type: "INTERNAL" (between own accounts), "PARENT_TO_SUB", or "SUB_TO_PARENT".
currency
string
Currency to transfer. Optional โ€” required for most transfer types.
fromUserId
string
Source user ID (required for sub-to-parent transfers).
toUserId
string
Destination user ID (required for parent-to-sub transfers).
fromAccountTag
string
Isolated-margin symbol for the source account.
toAccountTag
string
Isolated-margin symbol for the destination account.
import { SpotClient } from 'kucoin-api';

const client = new SpotClient({
  apiKey: 'apiKeyHere',
  apiSecret: 'apiSecretHere',
  apiPassphrase: 'apiPassPhraseHere',
});

// Transfer USDT from main account to HF trade account
const transfer = await client.submitFlexTransfer({
  clientOid: 'flex-transfer-001',
  currency: 'USDT',
  amount: '100',
  fromAccountType: 'MAIN',
  toAccountType: 'TRADE_HF',
  type: 'INTERNAL',
});
console.log('Transfer order ID:', transfer.data.orderId);
Transfers funds between account types for the same user (e.g. main to trade, trade to margin).Endpoint: POST api/v2/accounts/inner-transfer โ€” ๐Ÿ”’ Auth required
submitInnerTransfer(params: InnerTransferRequest): Promise<APISuccessResponse<{ orderId: string }>>
clientOid
string
required
Unique client-assigned transfer ID.
currency
string
required
Currency to transfer.
from
string
required
Source account type (lowercase): "main", "trade", "trade_hf", "margin", "isolated", "margin_v2", "isolated_v2", "contract", or "option".
to
string
required
Destination account type (same options as from).
amount
string
required
Amount to transfer.
fromTag
string
Tag for isolated-margin source (trading pair symbol).
toTag
string
Tag for isolated-margin destination.
Deprecated โ€” use submitFlexTransfer with type: "INTERNAL" instead.
Transfers funds between a master account and a sub-account.Endpoint: POST api/v2/accounts/sub-transfer โ€” ๐Ÿ”’ Auth required
submitTransferMasterSub(params: submitTransferMasterSubRequest): Promise<APISuccessResponse<{ orderId: string }>>
clientOid
string
required
Unique client-assigned transfer ID.
currency
string
required
Currency to transfer.
amount
string
required
Amount to transfer.
direction
string
required
"OUT" (master to sub) or "IN" (sub to master).
subUserId
string
required
The sub-accountโ€™s user ID.
accountType
string
Master account type: "MAIN", "TRADE", "TRADE_HF", "MARGIN", "CONTRACT", or "OPTION".
subAccountType
string
Sub-account type (same options as accountType).
Deprecated โ€” use submitFlexTransfer with type: "PARENT_TO_SUB" or "SUB_TO_PARENT" instead.

Build docs developers (and LLMs) love