From 6ed35aaa1af8d3f6ad622a8c438fec7e2f2834b0 Mon Sep 17 00:00:00 2001 From: Milad Date: Wed, 23 Jul 2025 16:56:05 +0330 Subject: [PATCH 1/3] update version --- package-lock.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index 052e330..f53b620 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "kucoin-node-api", - "version": "2.1.4", + "version": "2.1.6", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "kucoin-node-api", - "version": "2.1.4", + "version": "2.1.6", "license": "ISC", "dependencies": { "axios": "^0.21.1", diff --git a/package.json b/package.json index 161c39d..8543638 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "kucoin-node-api", - "version": "2.1.5", + "version": "2.1.6", "description": "Node.js KuCoin Cryptocurrency Exchange v2 API Wrapper/SDK", "main": "kucoin.js", "scripts": { From 5f7395f2022837a3ec04c4ff1ef8ed0aa3a99940 Mon Sep 17 00:00:00 2001 From: Milad Date: Wed, 23 Jul 2025 16:57:17 +0330 Subject: [PATCH 2/3] add new method to the README.md file --- README.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/README.md b/README.md index 84acb95..1251dbd 100644 --- a/README.md +++ b/README.md @@ -330,6 +330,34 @@ api.getMarginAccount() api.getWithdrawalsList(params) ``` +```javascript +/* + Get Withdrawal info By ID + GET /api/v1/withdrawals/ + params = { + withdrawalId: string + } + response : { + { + "code": "200000", + "data": { + "id": "5bd6e9286d99522a52e458de", + "currency": "BTC", + "address": "1ABCdefGhiJkl...", + "memo": "", + "amount": "0.5", + "fee": "0.0005", + "walletTxId": "b6f7a12d8e4f...", + "status": "SUCCESS", + "createdAt": 1609400000000, + "updatedAt": 1609401000000 + } + } + } +*/ +api.getWithdrawalByID(params) +``` + ```javascript /* Get Repay Record From 348d4b9e0e192c9ad8c149b4d965f90c376fbaa0 Mon Sep 17 00:00:00 2001 From: Milad Date: Wed, 23 Jul 2025 16:57:34 +0330 Subject: [PATCH 3/3] get withdrawal method --- lib/user.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/lib/user.js b/lib/user.js index ce6c51a..8267d4d 100644 --- a/lib/user.js +++ b/lib/user.js @@ -204,6 +204,21 @@ User.getWithdrawalsList = async function(params = {}) { return result.data } +/* + Get Withdrawal info By ID + GET /api/v1/withdrawals/ + params = { + withdrawalId: string + } +*/ +User.getWithdrawalByID = async function(params = {}) { + let endpoint = '/api/v1/withdrawals/' + params.withdrawalId + delete params.withdrawalId + let url = this.baseURL + endpoint + let result = await axios.get(url, this.sign(endpoint, params, 'GET')) + return result.data +} + /* Get Withdrawal Quotas GET /api/v1/withdrawals/quotas