Kucoin-cli

Latest version: v1.4.6

Safety actively analyzes 623827 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

1.4.6

-----
Release Date: 2022-10-28

**POTENTIALLY BREAKING CHANGE**
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
* `cancel_order`: Previously `cancel_order` returned a list of order IDs that were cancelled and logged an error message when an order failed to cancel. This function will now return a dictionary
with the following format:

.. code-block:: python

{
'200000':
[
'635948e592d8ed0001929223',
'5da59f5ef943c033b2b643e4,
],
'errors': []
}

**If you have a system that performs validation on orders cancellations based on the `cancel_order` response it will break**.

Futures and Async classes were moved from main branch to dev branch. These features may be in development for some time and as such they have been removed.

New Features
^^^^^^^^^^^^
* `cancel_lend_order`: Cancel outstanding lending orders across your account. Alternatively, cancel a single order or list of orders by tradeId.
* `set_auto_lend`: Toggle autolend features on or off for specified currency. Check out `the auto lend documentation <https://docs.kucoin.com/#set-auto-lend>`_ **before** you use this feature.

Quality of Life
^^^^^^^^^^^^^^^
* `order`: Significant improvements were made to `order` responses. By default, KuCoin order confirmations contain only a status code and either a tradeId or
message field (dependent on whether the trade was accepted or rejected). `order` will now return the same confirmation with additional information surrounding
order parameters. This change will not break any legacy systems as the response will still come in the same format. Simply more information has been added. See
the docstring for an example of what new reponses look like.
* `borrow`: In the same vein as `order`, improved response's have been added to `borrow`. For an example, check the docstrings.
* `lend`: Lend has also received updated response features. See the docstring for an example.

Bug Fixes
^^^^^^^^^
* During multi-day REST API scraping sessions, KuCoin would eventually refuse to send a HTTP response. This error is now handled via a 10 minute timeout with a log messages
printed at the debug logging level.

-----

1.4.5

-----
Release Date: 2022-10-23

Futures API support is currently in development. Current releases may be unstable or lack proper documentation. Explore features at your own risk.

New Features
^^^^^^^^^^^^
* `mark_price`: Use this function for obtaining KuCoin official mark prices.
* `consumer`: Added basic websocket consumer processing websocket message and handling keep alive pings

Quality of Life
^^^^^^^^^^^^^^^
* `pull_by_oid` and `pull_by_cid`: As appropriate, string values are recast to float automatically. `unix` boolean argument has been added to both functions. Finally, a
`KuCoinResponseError` is now raised if an invalid OID/CID is passed to the argument.
* `order_history`: With the addition of `pull_by_oid` and `pull_by_cid` as premier live trading endpoints, `order_history`'s primary purpose is for evaluation of trade results.
As such, consolidated outputs are more often a better view. `consolidated` view will now be the default.
* `margin_balance`: Where appropriate, columns are now automatically recast from string to float.
* `get_stats`: Where appropriate, columns are now automatically recast from string to float.
* `order_history`: Symbols passed to `symbols` argument are no longer case sensitive

-----

1.4.4

-----
Release Date: 2022-10-01

Added two new functions:

* `pull_by_oid`: Pull an active or inactive order by its KuCoin autogenerated order ID. Order details are returned as a pandas Series. This is the lowest latency, most consistent way to
obtain order details.
* `pull_by_cid`: Very similar to `pull_by_oid` above, this function is a low latency, consistent function for pulling order details by specifying a user-generated order ID. User-generated
order ID's can be attached to orders via the `oid` argument of the `orders` function.

With the addition of these functions, it is highly recommended that users remove `order_history` or `recent_orders` functions from their algorithms in favor of one of the new pull functions.
Both `order_history` and `recent_orders` suffer from slow execution time and significant lag in updating new orders to the response by KuCoin.

Bug Fixes
^^^^^^^^^
* `cancel_order`: Fixed error in appending cancelled order ID to list of order IDs when several CID/OID order existed, but one did not.

-----

1.4.3

-----
Release Date: 2022-09-27

Added exception handling for ConnectionError when submitting POST request. This issue was raised due to an idled request session and effected primarily macOS.

-----

1.4.2

-----
Release Date: 2022-09-25

In `ohlcv`, `begin` argument has officially been deprecated.

Quality of Life
^^^^^^^^^^^^^^^
* `get_server_time`: Added `unix` boolean argument and added deprecation warning for old `format` argument. In a later release, `format` will be deprecated in
favor of the new argument.
* `order_history`: Added `unix` boolean argument. Set `unix=True` to return timestamps in unix epochs. Default behavior will still return timestamps in as
datetime format. For *very* minor performance increases in live trading, set `unix=True` to avoid the call to `pd.to_datetime`.
* `transfer`: Added 'spot' and 'cross' as valid inputs for `source_acc` and `dest_acc` arguments. These inputs are more descriptive than the previous 'trade'
and 'margin' terms. Note that 'trade' and 'margin' are still supported and are now synonymous with 'spot' and 'cross' respectively.
* `cancel_order`: Now supports 'spot' as an `acc_type` argument input. The prior 'trade' input is still supported and is synonymous with 'spot'.
* `margin_balance`: `tradeId` column is now automatically set as index. Previously, the returned dataframe had no set index.
* `symbols`: Reversed previous index column change from `name` to `symbol`. This change will ensure naming consistency between other functions such as OHLCV.
New index column is `symbol`. Be aware that `name` is the trading pair name and may differ from `symbol`.

-----

1.4.1

-----
Release Date: 2022-09-22

Bugs Fixes
^^^^^^^^^^
* `.cancel_order`: A few errors in parsing responses were discovered and fixed.

Quality of Life
^^^^^^^^^^^^^^^
* `get_level1_orderbook`: Now has `unix` argument, consistent with other functions (deprecated `time` argument). Output is now automatically cast to
float values (previously returned strings).
* `order_history`: Changed default for `consolidated` to `False` (previously defaulted to `True`). I expected that consolidated responses would be more
useful, but found that in live execution, I was consistently setting the argument to `False`.

---------------

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.