@@ -29,8 +29,8 @@ public function getOverview(array $params = [])
2929 /**
3030 * Get a transaction history of accounts.
3131 *
32- * @param array $params
33- * @param array $pagination
32+ * @param array $params
33+ * @param array $pagination
3434 * @return array
3535 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
3636 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
@@ -43,11 +43,8 @@ public function getTransactionHistory(array $params = [], array $pagination = []
4343 }
4444
4545 /**
46- * @deprecated
47- *
4846 * KuCoin transfer to kuCoin futures account.
49- *
50- * @param number amount
47+ * @param string amount
5148 * @return array
5249 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
5350 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
@@ -62,8 +59,8 @@ public function transferIn($amount)
6259 /**
6360 * kuCoin futures transfer to KuCoin account.
6461 *
65- * @param string bizNo
66- * @param number amount
62+ * @param string bizNo
63+ * @param string amount
6764 * @return array
6865 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
6966 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
@@ -77,12 +74,12 @@ public function transferOut($bizNo, $amount)
7774
7875 /**
7976 * Cancel an transfer out.
80- *
81- * @param string $applyId
77+ * @param string $applyId
8278 * @return array
8379 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
8480 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
8581 * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
82+ * @deprecated
8683 */
8784 public function cancelTransferOut ($ applyId )
8885 {
@@ -93,8 +90,8 @@ public function cancelTransferOut($applyId)
9390 /**
9491 * Get a transfer list.
9592 *
96- * @param array $params
97- * @param array $pagination
93+ * @param array $params
94+ * @param array $pagination
9895 * @return array
9996 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
10097 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
@@ -108,10 +105,10 @@ public function getTransferList(array $params = [], array $pagination = [])
108105
109106 /**
110107 * kuCoin futures transfer to KuCoin account.
111- *
112- * @param string bizNo
113- * @param number amount
114- * @param string currency
108+ * [It is recommended to call transferOutV3() instead]
109+ * @param string bizNo
110+ * @param string amount
111+ * @param string currency
115112 * @return array
116113 * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
117114 * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
@@ -122,4 +119,81 @@ public function transferOutV2($bizNo, $amount, $currency)
122119 $ response = $ this ->call (Request::METHOD_POST , '/api/v2/transfer-out ' , compact ('bizNo ' , 'amount ' , 'currency ' ));
123120 return $ response ->getApiData ();
124121 }
122+
123+ /**
124+ * Get list of Futures APIs pertaining to a sub-accounts.
125+ *
126+ * @param array $params
127+ * @return array
128+ * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
129+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
130+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
131+ */
132+ public function getSubApikey (array $ params )
133+ {
134+ $ response = $ this ->call (Request::METHOD_GET , '/api/v1/sub/api-key ' , $ params );
135+ return $ response ->getApiData ();
136+ }
137+
138+ /**
139+ * Create futures APIs for sub-accounts.
140+ *
141+ * @param array $params
142+ * @return array
143+ * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
144+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
145+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
146+ */
147+ public function createSubApikey (array $ params )
148+ {
149+ $ response = $ this ->call (Request::METHOD_POST , '/api/v1/sub/api-key ' , $ params );
150+ return $ response ->getApiData ();
151+ }
152+
153+ /**
154+ * Modify futures APIs for sub-accounts.
155+ *
156+ * @param array $params
157+ * @return array
158+ * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
159+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
160+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
161+ */
162+ public function modifySubApikey (array $ params )
163+ {
164+ $ response = $ this ->call (Request::METHOD_POST , '/api/v1/sub/api-key/update ' , $ params );
165+ return $ response ->getApiData ();
166+ }
167+
168+ /**
169+ * Delete futures APIs for sub-accounts.
170+ *
171+ * @param array $params
172+ * @return array
173+ * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
174+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
175+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
176+ */
177+ public function deleteSubApikey (array $ params )
178+ {
179+ $ response = $ this ->call (Request::METHOD_DELETE , '/api/v1/sub/api-key ' , $ params );
180+ return $ response ->getApiData ();
181+ }
182+
183+ /**
184+ * kuCoin futures transfer to KuCoin account.
185+ *
186+ * @param string recAccountType
187+ * @param string amount
188+ * @param string currency
189+ * @return array
190+ * @throws \KuCoin\Futures\SDK\Exceptions\BusinessException
191+ * @throws \KuCoin\Futures\SDK\Exceptions\HttpException
192+ * @throws \KuCoin\Futures\SDK\Exceptions\InvalidApiUriException
193+ */
194+ public function transferOutV3 ($ recAccountType , $ amount , $ currency )
195+ {
196+ $ response = $ this ->call (Request::METHOD_POST , '/api/v3/transfer-out ' , compact ('recAccountType ' , 'amount ' , 'currency ' ));
197+ return $ response ->getApiData ();
198+ }
125199}
0 commit comments