diff --git a/pybit/_v5_account.py b/pybit/_v5_account.py index 8ba7f2a..8229c09 100644 --- a/pybit/_v5_account.py +++ b/pybit/_v5_account.py @@ -25,6 +25,25 @@ def get_wallet_balance(self, **kwargs): auth=True, ) + def get_coin_withdrawal(self, **kwargs): + """Query the available amount to transfer of a specific coin in the Unified wallet. + + Required args: + coinName (string): Coin name, uppercase only + + Returns: + Request results as dictionary. + + Additional information: + https://bybit-exchange.github.io/docs/v5/account/unified-trans-amnt + """ + return self._submit_request( + method="GET", + path=f"{self.endpoint}{Account.GET_COIN_WITHDRAWAL}", + query=kwargs, + auth=True, + ) + def upgrade_to_unified_trading_account(self, **kwargs): """Upgrade Unified Account diff --git a/pybit/account.py b/pybit/account.py index 2ea82bd..4e01b23 100644 --- a/pybit/account.py +++ b/pybit/account.py @@ -3,6 +3,7 @@ class Account(str, Enum): GET_WALLET_BALANCE = "/v5/account/wallet-balance" + GET_COIN_WITHDRAWAL = "/v5/account/withdrawal" UPGRADE_TO_UNIFIED_ACCOUNT = "/v5/account/upgrade-to-uta" GET_BORROW_HISTORY = "/v5/account/borrow-history" REPAY_LIABILITY = "/v5/account/quick-repayment"