Skip to content

Commit bbe6211

Browse files
authored
Merge pull request #109 from JJ-Cro/update21012026
feat(v2.3.6): enhance API client with new endpoints and update package dependencies
2 parents 6554d70 + ddb410e commit bbe6211

36 files changed

+12726
-9723
lines changed

docs/endpointFunctionList.md

Lines changed: 38 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -363,14 +363,41 @@ This table includes all endpoints from the official Exchange API docs and corres
363363

364364
| Function | AUTH | HTTP Method | Endpoint |
365365
| -------- | :------: | :------: | -------- |
366-
| [getAnnouncements()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L66) | | GET | `api/ua/v1/market/announcement` |
367-
| [getCurrency()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L76) | | GET | `api/ua/v1/market/currency` |
368-
| [getSymbols()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L86) | | GET | `api/ua/v1/market/instrument` |
369-
| [getTickers()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L96) | | GET | `api/ua/v1/market/ticker` |
370-
| [getTrades()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L106) | | GET | `api/ua/v1/market/trade` |
371-
| [getOrderBook()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L116) | | GET | `api/ua/v1/market/orderbook` |
372-
| [getKlines()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L126) | | GET | `api/ua/v1/market/kline` |
373-
| [getCurrentFundingRate()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L136) | | GET | `api/ua/v1/market/funding-rate` |
374-
| [getHistoryFundingRate()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L146) | | GET | `api/ua/v1/market/funding-rate-history` |
375-
| [getCrossMarginConfig()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L156) | | GET | `api/ua/v1/market/cross-config` |
376-
| [getServiceStatus()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L166) | | GET | `api/ua/v1/server/status` |
366+
| [getAnnouncements()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L114) | | GET | `api/ua/v1/market/announcement` |
367+
| [getCurrency()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L124) | | GET | `api/ua/v1/market/currency` |
368+
| [getSymbols()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L134) | | GET | `api/ua/v1/market/instrument` |
369+
| [getTickers()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L144) | | GET | `api/ua/v1/market/ticker` |
370+
| [getTrades()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L154) | | GET | `api/ua/v1/market/trade` |
371+
| [getOrderBook()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L164) | | GET | `api/ua/v1/market/orderbook` |
372+
| [getKlines()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L174) | | GET | `api/ua/v1/market/kline` |
373+
| [getCurrentFundingRate()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L184) | | GET | `api/ua/v1/market/funding-rate` |
374+
| [getHistoryFundingRate()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L194) | | GET | `api/ua/v1/market/funding-rate-history` |
375+
| [getCrossMarginConfig()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L204) | | GET | `api/ua/v1/market/cross-config` |
376+
| [getServiceStatus()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L214) | | GET | `api/ua/v1/server/status` |
377+
| [getClassicAccount()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L231) | :closed_lock_with_key: | GET | `api/ua/v1/account/balance` |
378+
| [getAccount()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L241) | :closed_lock_with_key: | GET | `api/ua/v1/unified/account/balance` |
379+
| [getAccountOverview()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L249) | :closed_lock_with_key: | GET | `api/ua/v1/unified/account/overview` |
380+
| [getSubAccount()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L259) | :closed_lock_with_key: | GET | `api/ua/v1/sub-account/balance` |
381+
| [getTransferQuotas()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L270) | :closed_lock_with_key: | GET | `api/ua/v1/account/transfer-quota` |
382+
| [flexTransfer()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L281) | :closed_lock_with_key: | POST | `api/ua/v1/account/transfer` |
383+
| [setSubAccountTransferPermission()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L291) | :closed_lock_with_key: | POST | `api/ua/v1/sub-account/canTransferOut` |
384+
| [getAccountMode()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L301) | :closed_lock_with_key: | GET | `api/ua/v1/account/mode` |
385+
| [setAccountMode()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L309) | :closed_lock_with_key: | POST | `api/ua/v1/account/mode` |
386+
| [getFeeRate()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L321) | :closed_lock_with_key: | GET | `api/ua/v1/user/fee-rate` |
387+
| [getAccountLedger()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L336) | :closed_lock_with_key: | GET | `api/ua/v1/account/ledger` |
388+
| [getInterestHistory()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L350) | :closed_lock_with_key: | GET | `api/ua/v1/account/interest-history` |
389+
| [modifyLeverage()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L360) | :closed_lock_with_key: | POST | `api/ua/v1/unified/account/modify-leverage` |
390+
| [getDepositAddress()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L375) | :closed_lock_with_key: | GET | `api/ua/v1/asset/deposit/address` |
391+
| [placeOrder()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L395) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/detail` |
392+
| [batchPlaceOrder()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L413) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/detail` |
393+
| [getOrderDetails()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L431) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/detail` |
394+
| [getOpenOrderList()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L445) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/open-list` |
395+
| [getOrderHistory()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L459) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/history` |
396+
| [getTradeHistory()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L472) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/order/execution` |
397+
| [cancelOrder()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L484) | :closed_lock_with_key: | POST | `api/ua/v1/dcp/set` |
398+
| [batchCancelOrders()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L501) | :closed_lock_with_key: | POST | `api/ua/v1/dcp/set` |
399+
| [setDCP()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L519) | :closed_lock_with_key: | POST | `api/ua/v1/dcp/set` |
400+
| [getDCP()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L530) | :closed_lock_with_key: | GET | `api/ua/v1/dcp/query` |
401+
| [getPositionList()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L547) | :closed_lock_with_key: | GET | `api/ua/v1/unified/position/open-list` |
402+
| [getPositionsHistory()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L560) | :closed_lock_with_key: | GET | `api/ua/v1/position/history` |
403+
| [getAccountPositionTiers()](https://github.com/tiagosiebler/kucoin-api/blob/master/src/UnifiedAPIClient.ts#L571) | :closed_lock_with_key: | GET | `api/ua/v1/{accountMode}/position/tiers` |
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/dcp/set
6+
// METHOD: POST
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.batchCancelOrders(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/{accountMode}/order/detail
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.batchPlaceOrder(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/dcp/set
6+
// METHOD: POST
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.cancelOrder(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/account/transfer
6+
// METHOD: POST
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.flexTransfer(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/unified/account/balance
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.getAccount(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/account/ledger
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.getAccountLedger(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/account/mode
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.getAccountMode(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/unified/account/overview
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.getAccountOverview(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
const { UnifiedAPIClient } = require('kucoin-api');
2+
3+
// This example shows how to call this kucoin API endpoint with either node.js, javascript (js) or typescript (ts) with the npm module "kucoin-api" for kucoin exchange
4+
// This kucoin API SDK is available on npm via "npm install kucoin-api"
5+
// ENDPOINT: api/ua/v1/{accountMode}/position/tiers
6+
// METHOD: GET
7+
// PUBLIC: NO
8+
9+
const client = new UnifiedAPIClient({
10+
apiKey: 'apiKeyHere',
11+
apiSecret: 'apiSecretHere',
12+
apiPassphrase: 'apiPassPhraseHere',
13+
});
14+
15+
client.getAccountPositionTiers(params)
16+
.then((response) => {
17+
console.log(response);
18+
})
19+
.catch((error) => {
20+
console.error(error);
21+
});

0 commit comments

Comments
 (0)