mirror of
https://github.com/aljazceru/bitfinex-api-py.git
synced 2025-12-19 14:54:21 +01:00
Apply isort to all python files (bfxapi/**/*.py).
This commit is contained in:
@@ -1,2 +1,6 @@
|
||||
from .endpoints import BfxRestInterface, RestPublicEndpoints, RestAuthEndpoints, \
|
||||
RestMerchantEndpoints
|
||||
from .endpoints import (
|
||||
BfxRestInterface,
|
||||
RestAuthEndpoints,
|
||||
RestMerchantEndpoints,
|
||||
RestPublicEndpoints,
|
||||
)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
from .bfx_rest_interface import BfxRestInterface
|
||||
|
||||
from .rest_public_endpoints import RestPublicEndpoints
|
||||
from .rest_auth_endpoints import RestAuthEndpoints
|
||||
from .rest_merchant_endpoints import RestMerchantEndpoints
|
||||
from .rest_public_endpoints import RestPublicEndpoints
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
from .rest_public_endpoints import RestPublicEndpoints
|
||||
from .rest_auth_endpoints import RestAuthEndpoints
|
||||
from .rest_merchant_endpoints import RestMerchantEndpoints
|
||||
from .rest_public_endpoints import RestPublicEndpoints
|
||||
|
||||
|
||||
class BfxRestInterface:
|
||||
VERSION = 2
|
||||
|
||||
@@ -1,24 +1,43 @@
|
||||
from typing import Dict, List, Tuple, Union, Literal, Optional
|
||||
|
||||
from decimal import Decimal
|
||||
from typing import Dict, List, Literal, Optional, Tuple, Union
|
||||
|
||||
from ...types import (
|
||||
BalanceAvailable,
|
||||
BaseMarginInfo,
|
||||
DepositAddress,
|
||||
DerivativePositionCollateral,
|
||||
DerivativePositionCollateralLimits,
|
||||
FundingAutoRenew,
|
||||
FundingCredit,
|
||||
FundingInfo,
|
||||
FundingLoan,
|
||||
FundingOffer,
|
||||
FundingTrade,
|
||||
Ledger,
|
||||
LightningNetworkInvoice,
|
||||
LoginHistory,
|
||||
Movement,
|
||||
Notification,
|
||||
Order,
|
||||
OrderTrade,
|
||||
Position,
|
||||
PositionAudit,
|
||||
PositionClaim,
|
||||
PositionHistory,
|
||||
PositionIncrease,
|
||||
PositionIncreaseInfo,
|
||||
PositionSnapshot,
|
||||
SymbolMarginInfo,
|
||||
Trade,
|
||||
Transfer,
|
||||
UserInfo,
|
||||
Wallet,
|
||||
Withdrawal,
|
||||
serializers,
|
||||
)
|
||||
from ...types.serializers import _Notification
|
||||
from ..middleware import Middleware
|
||||
|
||||
from ...types import Notification, \
|
||||
UserInfo, LoginHistory, BalanceAvailable, \
|
||||
Order, Position, Trade, \
|
||||
FundingTrade, OrderTrade, Ledger, \
|
||||
FundingOffer, FundingCredit, FundingLoan, \
|
||||
FundingAutoRenew, FundingInfo, Wallet, \
|
||||
Transfer, Withdrawal, DepositAddress, \
|
||||
LightningNetworkInvoice, Movement, SymbolMarginInfo, \
|
||||
BaseMarginInfo, PositionClaim, PositionIncreaseInfo, \
|
||||
PositionIncrease, PositionHistory, PositionSnapshot, \
|
||||
PositionAudit, DerivativePositionCollateral, DerivativePositionCollateralLimits
|
||||
|
||||
from ...types import serializers
|
||||
|
||||
from ...types.serializers import _Notification
|
||||
|
||||
#pylint: disable-next=too-many-public-methods
|
||||
class RestAuthEndpoints(Middleware):
|
||||
|
||||
@@ -1,19 +1,15 @@
|
||||
from typing import \
|
||||
TypedDict, Dict, List, \
|
||||
Union, Literal, Optional, \
|
||||
Any
|
||||
|
||||
from decimal import Decimal
|
||||
from typing import Any, Dict, List, Literal, Optional, TypedDict, Union
|
||||
|
||||
from bfxapi.rest.middleware import Middleware
|
||||
|
||||
from bfxapi.types import \
|
||||
InvoiceSubmission, \
|
||||
InvoicePage, \
|
||||
InvoiceStats, \
|
||||
CurrencyConversion, \
|
||||
MerchantDeposit, \
|
||||
MerchantUnlinkedDeposit
|
||||
from bfxapi.types import (
|
||||
CurrencyConversion,
|
||||
InvoicePage,
|
||||
InvoiceStats,
|
||||
InvoiceSubmission,
|
||||
MerchantDeposit,
|
||||
MerchantUnlinkedDeposit,
|
||||
)
|
||||
|
||||
_CustomerInfo = TypedDict("_CustomerInfo", {
|
||||
"nationality": str,
|
||||
|
||||
@@ -1,19 +1,32 @@
|
||||
from typing import List, Dict, Union, Literal, Optional, Any, cast
|
||||
|
||||
from decimal import Decimal
|
||||
from typing import Any, Dict, List, Literal, Optional, Union, cast
|
||||
|
||||
from ...types import (
|
||||
Candle,
|
||||
DerivativesStatus,
|
||||
FundingCurrencyBook,
|
||||
FundingCurrencyRawBook,
|
||||
FundingCurrencyTicker,
|
||||
FundingCurrencyTrade,
|
||||
FundingMarketAveragePrice,
|
||||
FundingStatistic,
|
||||
FxRate,
|
||||
Leaderboard,
|
||||
Liquidation,
|
||||
PlatformStatus,
|
||||
PulseMessage,
|
||||
PulseProfile,
|
||||
Statistic,
|
||||
TickersHistory,
|
||||
TradingMarketAveragePrice,
|
||||
TradingPairBook,
|
||||
TradingPairRawBook,
|
||||
TradingPairTicker,
|
||||
TradingPairTrade,
|
||||
serializers,
|
||||
)
|
||||
from ..middleware import Middleware
|
||||
|
||||
from ...types import \
|
||||
PlatformStatus, TradingPairTicker, FundingCurrencyTicker, \
|
||||
TickersHistory, TradingPairTrade, FundingCurrencyTrade, \
|
||||
TradingPairBook, FundingCurrencyBook, TradingPairRawBook, \
|
||||
FundingCurrencyRawBook, Statistic, Candle, \
|
||||
DerivativesStatus, Liquidation, Leaderboard, \
|
||||
FundingStatistic, PulseProfile, PulseMessage, \
|
||||
TradingMarketAveragePrice, FundingMarketAveragePrice, FxRate
|
||||
|
||||
from ...types import serializers
|
||||
|
||||
#pylint: disable-next=too-many-public-methods
|
||||
class RestPublicEndpoints(Middleware):
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
from bfxapi.exceptions import BfxBaseException
|
||||
|
||||
|
||||
class NotFoundError(BfxBaseException):
|
||||
pass
|
||||
|
||||
|
||||
@@ -1,16 +1,17 @@
|
||||
from typing import TYPE_CHECKING, Optional, Any
|
||||
|
||||
import hashlib
|
||||
import hmac
|
||||
import json
|
||||
import time
|
||||
from enum import IntEnum
|
||||
|
||||
from http import HTTPStatus
|
||||
from typing import TYPE_CHECKING, Any, Optional
|
||||
|
||||
import time, hmac, hashlib, json, requests
|
||||
import requests
|
||||
|
||||
from ..exceptions import NotFoundError, RequestParametersError, UnknownGenericError
|
||||
|
||||
from ...exceptions import InvalidCredentialError
|
||||
from ..._utils.json_encoder import JSONEncoder
|
||||
from ..._utils.json_decoder import JSONDecoder
|
||||
from ..._utils.json_encoder import JSONEncoder
|
||||
from ...exceptions import InvalidCredentialError
|
||||
from ..exceptions import NotFoundError, RequestParametersError, UnknownGenericError
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from requests.sessions import _Params
|
||||
|
||||
Reference in New Issue
Block a user