Pybit

Latest version: v5.10.0

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

Scan your dependencies

Page 2 of 14

5.5.0

Added
- `helpers.py` which includes the `Helpers` class and the `close_position` method, which can be imported and employed like so:
python
from pybit.helpers import Helpers
my_helper = Helpers(session) your HTTP session object (eg, from pybit.unified_trading import HTTP)
print(my_helper.close_position(category="linear", symbol="BTCUSDT"))

5.4.0

Added
- The following new endpoints to `unified_trading`:
- `get_broker_earnings`
- `get_announcement`
- `get_pre_upgrade_order_history`
- `get_pre_upgrade_trade_history`
- `get_pre_upgrade_closed_pnl`
- `get_pre_upgrade_transaction_log`
- `get_pre_upgrade_option_delivery_record`
- `get_pre_upgrade_usdc_session_settlement`
- `get_affiliate_user_info`
- `get_uid_wallet_type`

5.3.0

Added
- Multiple symbol support for WebSocket topics (pass `symbol` as a list)
- Extra logging (log response headers) when passing `log_requests=True`
- Argument `return_response_headers` for `HTTP` to allow returning the response headers to the user

Modified
- Add response headers to exceptions

Fixed
- Update PyPI package's python version so that only =>3.9 is supported to prevent the error: `TypeError: 'type' object is not subscriptable`
- Fix API rate limit handling
- Remove unnecessary `print` statements in two methods

5.2.0

Added
- New asset endpoints: `set_deposit_account()`, `get_internal_deposit_records()`, `get_withdrawable_amount()`

Fixed
- Ensure that `legacy` submodule is packaged by `setup.py`
- Fix non-UTA (normal account) spot margin trading endpoints
- Fix wrong request method for `set_dcp()`

5.1.1

Added
- HTTP endpoints to the `copy_trading` module

Modified
- Docstrings in the `copy_trading` module to make it easier to find the API documentation for reference
- Example files

Fixed
- `ticker_stream` method in the `unified_trading` module, which was subscribing to the wrong WebSocket topic

5.0.0

This version upgrades pybit to Bybit's [version 5 (v5) APIs](https://bybit-exchange.github.io/docs/v5/intro). It supports both [Unified Trading Accounts](https://www.bybit.com/en-US/help-center/s/article/Introduction-to-Bybit-Unified-Trading-Account) (UTA) and non-UTA accounts. Bybit is not expected to develop any more major API versions in the future, so Bybit's v5 API (and subsequently, pybit's 5.0.0) is expected to be supported in the long-term.

See the [examples folder](https://github.com/bybit-exchange/pybit/tree/master/examples) for examples on how to interact with the latest modules.

Added
- Bybit's v5 HTTP and WebSocket APIs in the `unified_trading` module. See what markets All-In-One V5 API supports in the [upgrade guide](https://bybit-exchange.github.io/docs/v5/upgrade-guide).

Modified
- Non-v5 modules like `copy_trading`, `usdc_options`, and `usdc_perpetuals` to continue to work from a `legacy` subpackage. Import like so: `from pybit.legacy.copy_trading import HTTP
`. These modules are maintained because they are currently not supported by the v5 API; see the [upgrade guide](https://bybit-exchange.github.io/docs/v5/upgrade-guide).

Removed
- Various legacy modules which have been superseded by the v5 API via the `unified_trading` module

Fixed
- Tests for V5 endpoints

Page 2 of 14

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.