compass_api_sdk 1.1.1__py3-none-any.whl → 2.2.1rc3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- compass_api_sdk/_hooks/sdkhooks.py +4 -4
- compass_api_sdk/_hooks/types.py +1 -2
- compass_api_sdk/_version.py +3 -3
- compass_api_sdk/aave_v3.py +386 -114
- compass_api_sdk/aerodrome_slipstream.py +104 -54
- compass_api_sdk/basesdk.py +6 -0
- compass_api_sdk/bridge.py +536 -0
- compass_api_sdk/earn.py +2026 -0
- compass_api_sdk/erc_4626_vaults.py +28 -10
- compass_api_sdk/errors/__init__.py +8 -0
- compass_api_sdk/errors/apierror.py +1 -1
- compass_api_sdk/errors/compassapierror.py +1 -1
- compass_api_sdk/errors/httpvalidationerror.py +1 -1
- compass_api_sdk/errors/mintpreparenotfoundresponse_error.py +49 -0
- compass_api_sdk/errors/no_response_error.py +1 -1
- compass_api_sdk/errors/responsevalidationerror.py +1 -1
- compass_api_sdk/ethena.py +36 -10
- compass_api_sdk/gas_sponsorship.py +458 -0
- compass_api_sdk/httpclient.py +0 -1
- compass_api_sdk/models/__init__.py +820 -392
- compass_api_sdk/models/aaveborrowparams.py +4 -13
- compass_api_sdk/models/aaveborrowrequest.py +10 -14
- compass_api_sdk/models/aavehistoricaltransactionsresponse.py +3 -3
- compass_api_sdk/models/aavelooprequest.py +32 -28
- compass_api_sdk/models/aaveposition.py +104 -0
- compass_api_sdk/models/aaverepayparams.py +4 -13
- compass_api_sdk/models/aaverepayrequest.py +10 -14
- compass_api_sdk/models/aavesetuseremodeparams.py +28 -0
- compass_api_sdk/models/aavesetuseremoderequest.py +48 -0
- compass_api_sdk/models/aavesupplyparams.py +4 -13
- compass_api_sdk/models/aavesupplyrequest.py +10 -14
- compass_api_sdk/models/aavevenue.py +27 -0
- compass_api_sdk/models/aavewithdrawparams.py +4 -13
- compass_api_sdk/models/aavewithdrawrequest.py +10 -14
- compass_api_sdk/models/aerodromeenrichedposition.py +109 -0
- compass_api_sdk/models/aerodromelppositionsresponse.py +10 -7
- compass_api_sdk/models/aerodromeslipstreambuyexactlyparams.py +8 -25
- compass_api_sdk/models/aerodromeslipstreambuyexactlyrequest.py +14 -26
- compass_api_sdk/models/aerodromeslipstreamincreaseliquidityprovisionrequest.py +6 -1
- compass_api_sdk/models/aerodromeslipstreammintliquidityprovisionparams.py +8 -25
- compass_api_sdk/models/aerodromeslipstreammintliquidityprovisionrequest.py +14 -26
- compass_api_sdk/models/aerodromeslipstreampoolpriceresponse.py +8 -25
- compass_api_sdk/models/aerodromeslipstreamsellexactlyparams.py +8 -25
- compass_api_sdk/models/aerodromeslipstreamsellexactlyrequest.py +13 -25
- compass_api_sdk/models/aerodromeslipstreamwithdrawliquidityprovisionrequest.py +6 -1
- compass_api_sdk/models/approvetransferrequest.py +32 -0
- compass_api_sdk/models/approvetransferresponse.py +52 -0
- compass_api_sdk/models/batchedsafeoperationsresponse_input.py +52 -0
- compass_api_sdk/models/batchedsafeoperationsresponse_output.py +52 -0
- compass_api_sdk/models/batcheduseroperationsrequest.py +15 -4
- compass_api_sdk/models/chainmarketinfo.py +29 -0
- compass_api_sdk/models/{compass_api_backend_models_generic_read_response_portfolio_tokenbalance.py → compass_api_backend_v1_models_generic_read_response_portfolio_tokenbalance.py} +6 -15
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_check_user_position_apydata.py → compass_api_backend_v1_models_morpho_read_response_check_user_position_apydata.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_check_user_position_asset.py → compass_api_backend_v1_models_morpho_read_response_check_user_position_asset.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_check_user_position_marketstate.py → compass_api_backend_v1_models_morpho_read_response_check_user_position_marketstate.py} +4 -2
- compass_api_sdk/models/compass_api_backend_v1_models_morpho_read_response_check_user_position_vaultposition.py +30 -0
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_check_user_position_vaultstate.py → compass_api_backend_v1_models_morpho_read_response_check_user_position_vaultstate.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_market_apydata.py → compass_api_backend_v1_models_morpho_read_response_get_market_apydata.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_market_asset.py → compass_api_backend_v1_models_morpho_read_response_get_market_asset.py} +5 -5
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_market_marketstate.py → compass_api_backend_v1_models_morpho_read_response_get_market_marketstate.py} +4 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_markets_asset.py → compass_api_backend_v1_models_morpho_read_response_get_markets_asset.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_markets_marketstate.py → compass_api_backend_v1_models_morpho_read_response_get_markets_marketstate.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_vaults_asset.py → compass_api_backend_v1_models_morpho_read_response_get_vaults_asset.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_vaults_vaultstate.py → compass_api_backend_v1_models_morpho_read_response_get_vaults_vaultstate.py} +4 -2
- compass_api_sdk/models/{compass_api_backend_models_pendle_read_response_market_userposition.py → compass_api_backend_v1_models_pendle_read_response_market_userposition.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_pendle_read_response_positions_tokenbalance.py → compass_api_backend_v1_models_pendle_read_response_positions_tokenbalance.py} +2 -2
- compass_api_sdk/models/{compass_api_backend_models_vaults_read_response_vault_userposition.py → compass_api_backend_v1_models_vaults_read_response_vault_userposition.py} +2 -2
- compass_api_sdk/models/compass_api_backend_v1_models_wildcat_read_response_market_userposition.py +22 -0
- compass_api_sdk/models/compass_api_backend_v2_models_earn_read_response_positions_vaultposition.py +103 -0
- compass_api_sdk/models/compass_api_backend_v2_models_gas_sponsorship_permit_2_typed_data_eip712domain.py +36 -0
- compass_api_sdk/models/compass_api_backend_v2_models_gas_sponsorship_permit_2_typed_data_eip712types.py +36 -0
- compass_api_sdk/models/compass_api_backend_v2_models_gas_sponsorship_permit_typed_data_eip712domain.py +37 -0
- compass_api_sdk/models/compass_api_backend_v2_models_gas_sponsorship_permit_typed_data_eip712types.py +32 -0
- compass_api_sdk/models/compass_api_backend_v2_models_safe_transact_response_batched_safe_operations_eip712domain.py +29 -0
- compass_api_sdk/models/compass_api_backend_v2_models_safe_transact_response_batched_safe_operations_eip712types.py +34 -0
- compass_api_sdk/models/createaccountrequest.py +40 -0
- compass_api_sdk/models/createaccountresponse.py +56 -0
- compass_api_sdk/models/depositevent.py +61 -0
- compass_api_sdk/models/depositforburnrequest.py +77 -0
- compass_api_sdk/models/depositforburnresponse.py +100 -0
- compass_api_sdk/models/earnmanageparams.py +76 -0
- compass_api_sdk/models/earnmanagerequest.py +132 -0
- compass_api_sdk/models/earnmanageresponse.py +52 -0
- compass_api_sdk/models/earnpositionsresponse.py +48 -0
- compass_api_sdk/models/earnswapparams.py +74 -0
- compass_api_sdk/models/earnswaprequest.py +90 -0
- compass_api_sdk/models/earnswapresponse.py +55 -0
- compass_api_sdk/models/earntransferrequest.py +104 -0
- compass_api_sdk/models/earntransferresponse.py +71 -0
- compass_api_sdk/models/eip712domainfield.py +20 -0
- compass_api_sdk/models/eip712field.py +20 -0
- compass_api_sdk/models/ethenadepositrequest.py +6 -1
- compass_api_sdk/models/ethenagetvaultresponse.py +5 -5
- compass_api_sdk/models/ethenarequesttowithdrawrequest.py +6 -1
- compass_api_sdk/models/ethenaunstakerequest.py +6 -1
- compass_api_sdk/models/fee.py +43 -0
- compass_api_sdk/models/listaavemarketsresponse.py +21 -0
- compass_api_sdk/models/marketposition.py +5 -5
- compass_api_sdk/models/maxsupplyapyinfo.py +34 -0
- compass_api_sdk/models/mintpreparecompletedresponse.py +46 -0
- compass_api_sdk/models/mintpreparependingresponse.py +65 -0
- compass_api_sdk/models/mintpreparereadyresponse.py +43 -0
- compass_api_sdk/models/mintpreparerequest.py +25 -0
- compass_api_sdk/models/morphoborrowrequest.py +6 -1
- compass_api_sdk/models/morphocheckuserpositionresponse.py +9 -3
- compass_api_sdk/models/morphodepositrequest.py +6 -1
- compass_api_sdk/models/morphogetmarketresponse.py +72 -31
- compass_api_sdk/models/morphomarket.py +26 -20
- compass_api_sdk/models/morphorepayrequest.py +11 -1
- compass_api_sdk/models/morphosupplycollateralrequest.py +11 -1
- compass_api_sdk/models/morphovault.py +10 -10
- compass_api_sdk/models/morphowithdrawcollateralrequest.py +6 -1
- compass_api_sdk/models/morphowithdrawrequest.py +6 -1
- compass_api_sdk/models/multicallexecuterequest.py +7 -2
- compass_api_sdk/models/odosswapparams.py +9 -30
- compass_api_sdk/models/odosswaprequest.py +15 -33
- compass_api_sdk/models/oneinchswapparams.py +59 -0
- compass_api_sdk/models/openposition.py +7 -7
- compass_api_sdk/models/operationtype.py +11 -0
- compass_api_sdk/models/pendledepositevent.py +49 -0
- compass_api_sdk/models/pendlegetmarketresponse.py +5 -5
- compass_api_sdk/models/pendlemanageliquidityparams.py +2 -15
- compass_api_sdk/models/pendlemanageliquidityrequest.py +8 -16
- compass_api_sdk/models/pendlemarketinfo.py +138 -0
- compass_api_sdk/models/pendlemarketsresponse.py +30 -0
- compass_api_sdk/models/pendleptposition.py +111 -0
- compass_api_sdk/models/pendleptvenue.py +78 -0
- compass_api_sdk/models/pendleredeemyieldrequest.py +6 -1
- compass_api_sdk/models/pendletradeptparams.py +2 -15
- compass_api_sdk/models/pendletradeptrequest.py +8 -16
- compass_api_sdk/models/pendletradeytparams.py +2 -15
- compass_api_sdk/models/pendletradeytrequest.py +8 -16
- compass_api_sdk/models/pendlewithdrawalevent.py +54 -0
- compass_api_sdk/models/permit2typeddata_input.py +46 -0
- compass_api_sdk/models/permit2typeddata_output.py +46 -0
- compass_api_sdk/models/permitfield.py +20 -0
- compass_api_sdk/models/permitmessage.py +39 -0
- compass_api_sdk/models/permittransferfrommessage.py +29 -0
- compass_api_sdk/models/permittypeddataresponse_input.py +50 -0
- compass_api_sdk/models/permittypeddataresponse_output.py +50 -0
- compass_api_sdk/models/portfolio.py +5 -5
- compass_api_sdk/models/positionpnl.py +52 -0
- compass_api_sdk/models/reserve.py +6 -15
- compass_api_sdk/models/safetransactionparams.py +78 -0
- compass_api_sdk/models/safetransactionresponse.py +28 -0
- compass_api_sdk/models/safetxfield.py +20 -0
- compass_api_sdk/models/safetxmessage.py +66 -0
- compass_api_sdk/models/setallowanceparams.py +3 -16
- compass_api_sdk/models/setallowancerequest.py +9 -17
- compass_api_sdk/models/skybuyrequest.py +6 -1
- compass_api_sdk/models/skydepositrequest.py +7 -2
- compass_api_sdk/models/skysellrequest.py +7 -2
- compass_api_sdk/models/skywithdrawrequest.py +7 -2
- compass_api_sdk/models/sponsorgasrequest.py +71 -0
- compass_api_sdk/models/sponsorgasresponse.py +14 -0
- compass_api_sdk/models/tokenbalanceresponse.py +5 -15
- compass_api_sdk/models/tokenconfig.py +30 -0
- compass_api_sdk/models/tokenlistresponse.py +21 -0
- compass_api_sdk/models/tokenmarketdata.py +27 -0
- compass_api_sdk/models/tokenpermissions.py +20 -0
- compass_api_sdk/models/tokentransferparams.py +2 -15
- compass_api_sdk/models/tokentransferrequest.py +8 -16
- compass_api_sdk/models/uniswapbuyexactlyparams.py +8 -33
- compass_api_sdk/models/uniswapbuyexactlyrequest.py +14 -34
- compass_api_sdk/models/uniswapincreaseliquidityprovisionrequest.py +6 -1
- compass_api_sdk/models/uniswapmintliquidityprovisionparams.py +8 -25
- compass_api_sdk/models/uniswapmintliquidityprovisionrequest.py +14 -26
- compass_api_sdk/models/uniswappoolpriceresponse.py +8 -25
- compass_api_sdk/models/uniswapsellexactlyparams.py +4 -29
- compass_api_sdk/models/uniswapsellexactlyrequest.py +10 -30
- compass_api_sdk/models/uniswapwithdrawliquidityprovisionrequest.py +6 -1
- compass_api_sdk/models/unsignedmulticalltransaction.py +34 -3
- compass_api_sdk/models/unsignedtransaction.py +34 -3
- compass_api_sdk/models/unwrapwethrequest.py +6 -1
- compass_api_sdk/models/useroperation.py +33 -24
- compass_api_sdk/models/v1_aave_aave_supported_tokensop.py +1 -1
- compass_api_sdk/models/v1_aave_avg_rateop.py +15 -93
- compass_api_sdk/models/v1_aave_historical_transactionsop.py +15 -15
- compass_api_sdk/models/v1_aave_liquidity_changeop.py +8 -86
- compass_api_sdk/models/v1_aave_rateop.py +8 -86
- compass_api_sdk/models/v1_aave_reserve_overviewop.py +8 -86
- compass_api_sdk/models/v1_aave_std_rateop.py +15 -93
- compass_api_sdk/models/v1_aave_token_priceop.py +8 -86
- compass_api_sdk/models/v1_aave_user_position_per_tokenop.py +14 -92
- compass_api_sdk/models/v1_aave_user_position_summaryop.py +8 -8
- compass_api_sdk/models/v1_aerodrome_slipstream_liquidity_provision_positionsop.py +48 -3
- compass_api_sdk/models/v1_aerodrome_slipstream_pool_priceop.py +12 -168
- compass_api_sdk/models/v1_ethena_vaultop.py +1 -1
- compass_api_sdk/models/v1_generic_allowanceop.py +12 -26
- compass_api_sdk/models/v1_generic_ensop.py +2 -2
- compass_api_sdk/models/v1_generic_portfolioop.py +2 -2
- compass_api_sdk/models/v1_morpho_market_positionop.py +3 -3
- compass_api_sdk/models/v1_morpho_marketop.py +2 -2
- compass_api_sdk/models/v1_morpho_marketsop.py +10 -30
- compass_api_sdk/models/v1_morpho_user_positionop.py +2 -2
- compass_api_sdk/models/v1_morpho_vaultop.py +8 -8
- compass_api_sdk/models/v1_morpho_vaultsop.py +6 -16
- compass_api_sdk/models/v1_pendle_marketop.py +8 -8
- compass_api_sdk/models/v1_pendle_marketsop.py +1 -1
- compass_api_sdk/models/v1_pendle_positionsop.py +2 -2
- compass_api_sdk/models/v1_sky_positionop.py +5 -6
- compass_api_sdk/models/v1_token_balanceop.py +12 -25
- compass_api_sdk/models/{v1_generic_supported_tokensop.py → v1_token_listop.py} +6 -6
- compass_api_sdk/models/v1_token_priceop.py +8 -9
- compass_api_sdk/models/v1_transaction_bundler_aave_loopop.py +6 -6
- compass_api_sdk/models/v1_uniswap_liquidity_provision_in_rangeop.py +2 -2
- compass_api_sdk/models/v1_uniswap_liquidity_provision_positionsop.py +2 -2
- compass_api_sdk/models/v1_uniswap_pool_priceop.py +12 -168
- compass_api_sdk/models/v1_uniswap_quote_buy_exactlyop.py +20 -176
- compass_api_sdk/models/v1_uniswap_quote_sell_exactlyop.py +20 -176
- compass_api_sdk/models/v1_vaults_vaultop.py +8 -8
- compass_api_sdk/models/v1_wildcat_marketop.py +82 -0
- compass_api_sdk/models/v2_cctp_mintop.py +47 -0
- compass_api_sdk/models/v2_earn_aave_marketsop.py +57 -0
- compass_api_sdk/models/v2_earn_pendle_marketsop.py +105 -0
- compass_api_sdk/models/v2_earn_positionsop.py +31 -0
- compass_api_sdk/models/v2_earn_vaultsop.py +105 -0
- compass_api_sdk/models/v2bundlerequest.py +33 -0
- compass_api_sdk/models/v2bundleresponse.py +67 -0
- compass_api_sdk/models/v2useroperation.py +37 -0
- compass_api_sdk/models/vault.py +14 -14
- compass_api_sdk/models/vaultdepositrequest.py +6 -1
- compass_api_sdk/models/vaultgetvaultresponse.py +5 -5
- compass_api_sdk/models/vaultinfo.py +129 -0
- compass_api_sdk/models/vaultsresponse.py +30 -0
- compass_api_sdk/models/vaultvenue.py +27 -0
- compass_api_sdk/models/vaultwithdrawrequest.py +6 -1
- compass_api_sdk/models/wildcatgetmarketresponse.py +151 -0
- compass_api_sdk/models/{redeemunderlying.py → withdraw.py} +2 -2
- compass_api_sdk/models/withdrawalevent.py +61 -0
- compass_api_sdk/models/wrapethrequest.py +6 -1
- compass_api_sdk/morpho.py +126 -78
- compass_api_sdk/pendle.py +68 -44
- compass_api_sdk/sdk.py +18 -11
- compass_api_sdk/sky.py +62 -38
- compass_api_sdk/smart_account.py +10 -2
- compass_api_sdk/swap.py +22 -22
- compass_api_sdk/{token_sdk.py → token.py} +511 -103
- compass_api_sdk/transaction_bundler.py +46 -16
- compass_api_sdk/types/basemodel.py +41 -3
- compass_api_sdk/uniswap_v3.py +152 -114
- compass_api_sdk/universal.py +44 -606
- compass_api_sdk/utils/__init__.py +0 -3
- compass_api_sdk/utils/annotations.py +32 -8
- compass_api_sdk/utils/enums.py +60 -0
- compass_api_sdk/utils/forms.py +21 -10
- compass_api_sdk/utils/queryparams.py +14 -2
- compass_api_sdk/utils/requestbodies.py +3 -3
- compass_api_sdk/utils/retries.py +69 -5
- compass_api_sdk/utils/serializers.py +0 -20
- compass_api_sdk/utils/unmarshal_json_response.py +15 -1
- compass_api_sdk/wildcat.py +208 -0
- compass_api_sdk-2.2.1rc3.dist-info/METADATA +624 -0
- compass_api_sdk-2.2.1rc3.dist-info/RECORD +356 -0
- {compass_api_sdk-1.1.1.dist-info → compass_api_sdk-2.2.1rc3.dist-info}/WHEEL +1 -1
- compass_api_sdk/models/aerodromeposition.py +0 -70
- compass_api_sdk/models/token_enum.py +0 -81
- compass_api_sdk/models/tokenaddressresponse.py +0 -15
- compass_api_sdk/models/tokeninfo.py +0 -17
- compass_api_sdk/models/v1_token_addressop.py +0 -109
- compass_api_sdk/models/vaultposition.py +0 -24
- compass_api_sdk-1.1.1.dist-info/METADATA +0 -592
- compass_api_sdk-1.1.1.dist-info/RECORD +0 -275
|
@@ -2,38 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
from .feeenum import FeeEnum
|
|
5
|
-
from .token_enum import TokenEnum
|
|
6
5
|
from compass_api_sdk.types import BaseModel
|
|
7
6
|
from compass_api_sdk.utils import validate_const
|
|
8
7
|
from enum import Enum
|
|
9
8
|
import pydantic
|
|
10
9
|
from pydantic.functional_validators import AfterValidator
|
|
11
10
|
from typing import Literal, Optional, Union
|
|
12
|
-
from typing_extensions import Annotated, TypeAliasType, TypedDict
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
UniswapSellExactlyRequestTokenInTypedDict = TypeAliasType(
|
|
16
|
-
"UniswapSellExactlyRequestTokenInTypedDict", Union[TokenEnum, str]
|
|
17
|
-
)
|
|
18
|
-
r"""The symbol or address of the token to sell.."""
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
UniswapSellExactlyRequestTokenIn = TypeAliasType(
|
|
22
|
-
"UniswapSellExactlyRequestTokenIn", Union[TokenEnum, str]
|
|
23
|
-
)
|
|
24
|
-
r"""The symbol or address of the token to sell.."""
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
UniswapSellExactlyRequestTokenOutTypedDict = TypeAliasType(
|
|
28
|
-
"UniswapSellExactlyRequestTokenOutTypedDict", Union[TokenEnum, str]
|
|
29
|
-
)
|
|
30
|
-
r"""The symbol or address of the token to buy.."""
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
UniswapSellExactlyRequestTokenOut = TypeAliasType(
|
|
34
|
-
"UniswapSellExactlyRequestTokenOut", Union[TokenEnum, str]
|
|
35
|
-
)
|
|
36
|
-
r"""The symbol or address of the token to buy.."""
|
|
11
|
+
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
37
12
|
|
|
38
13
|
|
|
39
14
|
UniswapSellExactlyRequestAmountInTypedDict = TypeAliasType(
|
|
@@ -57,9 +32,9 @@ class UniswapSellExactlyRequestChain(str, Enum):
|
|
|
57
32
|
class UniswapSellExactlyRequestTypedDict(TypedDict):
|
|
58
33
|
r"""Request model for selling exactly an amount of tokens."""
|
|
59
34
|
|
|
60
|
-
token_in:
|
|
35
|
+
token_in: str
|
|
61
36
|
r"""The symbol or address of the token to sell.."""
|
|
62
|
-
token_out:
|
|
37
|
+
token_out: str
|
|
63
38
|
r"""The symbol or address of the token to buy.."""
|
|
64
39
|
fee: FeeEnum
|
|
65
40
|
r"""The transaction fee of a Uniswap pool in bips.
|
|
@@ -74,15 +49,17 @@ class UniswapSellExactlyRequestTypedDict(TypedDict):
|
|
|
74
49
|
sender: str
|
|
75
50
|
r"""The address of the transaction sender."""
|
|
76
51
|
action_type: Literal["UNISWAP_SELL_EXACTLY"]
|
|
52
|
+
estimate_gas: NotRequired[bool]
|
|
53
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
77
54
|
|
|
78
55
|
|
|
79
56
|
class UniswapSellExactlyRequest(BaseModel):
|
|
80
57
|
r"""Request model for selling exactly an amount of tokens."""
|
|
81
58
|
|
|
82
|
-
token_in:
|
|
59
|
+
token_in: str
|
|
83
60
|
r"""The symbol or address of the token to sell.."""
|
|
84
61
|
|
|
85
|
-
token_out:
|
|
62
|
+
token_out: str
|
|
86
63
|
r"""The symbol or address of the token to buy.."""
|
|
87
64
|
|
|
88
65
|
fee: FeeEnum
|
|
@@ -109,3 +86,6 @@ class UniswapSellExactlyRequest(BaseModel):
|
|
|
109
86
|
],
|
|
110
87
|
pydantic.Field(alias="action_type"),
|
|
111
88
|
] = "UNISWAP_SELL_EXACTLY"
|
|
89
|
+
|
|
90
|
+
estimate_gas: Optional[bool] = None
|
|
91
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
@@ -7,7 +7,7 @@ from enum import Enum
|
|
|
7
7
|
import pydantic
|
|
8
8
|
from pydantic.functional_validators import AfterValidator
|
|
9
9
|
from typing import Literal, Optional, Union
|
|
10
|
-
from typing_extensions import Annotated, TypeAliasType, TypedDict
|
|
10
|
+
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
UniswapWithdrawLiquidityProvisionRequestPercentageForWithdrawalTypedDict = (
|
|
@@ -42,6 +42,8 @@ class UniswapWithdrawLiquidityProvisionRequestTypedDict(TypedDict):
|
|
|
42
42
|
sender: str
|
|
43
43
|
r"""The address of the transaction sender."""
|
|
44
44
|
action_type: Literal["UNISWAP_WITHDRAW_LIQUIDITY_PROVISION"]
|
|
45
|
+
estimate_gas: NotRequired[bool]
|
|
46
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
45
47
|
|
|
46
48
|
|
|
47
49
|
class UniswapWithdrawLiquidityProvisionRequest(BaseModel):
|
|
@@ -65,3 +67,6 @@ class UniswapWithdrawLiquidityProvisionRequest(BaseModel):
|
|
|
65
67
|
],
|
|
66
68
|
pydantic.Field(alias="action_type"),
|
|
67
69
|
] = "UNISWAP_WITHDRAW_LIQUIDITY_PROVISION"
|
|
70
|
+
|
|
71
|
+
estimate_gas: Optional[bool] = None
|
|
72
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
from .signedauthorization import SignedAuthorization, SignedAuthorizationTypedDict
|
|
5
|
-
from compass_api_sdk.types import BaseModel
|
|
5
|
+
from compass_api_sdk.types import BaseModel, Nullable, UNSET_SENTINEL
|
|
6
6
|
import pydantic
|
|
7
|
+
from pydantic import model_serializer
|
|
7
8
|
from typing import List, Optional
|
|
8
9
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
9
10
|
|
|
@@ -15,7 +16,7 @@ class UnsignedMulticallTransactionTypedDict(TypedDict):
|
|
|
15
16
|
r"""The data of the transaction"""
|
|
16
17
|
from_: str
|
|
17
18
|
r"""The sender of the transaction"""
|
|
18
|
-
gas: str
|
|
19
|
+
gas: Nullable[str]
|
|
19
20
|
r"""The gas of the transaction"""
|
|
20
21
|
to: str
|
|
21
22
|
r"""The recipient of the transaction"""
|
|
@@ -41,7 +42,7 @@ class UnsignedMulticallTransaction(BaseModel):
|
|
|
41
42
|
from_: Annotated[str, pydantic.Field(alias="from")]
|
|
42
43
|
r"""The sender of the transaction"""
|
|
43
44
|
|
|
44
|
-
gas: str
|
|
45
|
+
gas: Nullable[str]
|
|
45
46
|
r"""The gas of the transaction"""
|
|
46
47
|
|
|
47
48
|
to: str
|
|
@@ -65,3 +66,33 @@ class UnsignedMulticallTransaction(BaseModel):
|
|
|
65
66
|
Optional[List[SignedAuthorization]], pydantic.Field(alias="authorizationList")
|
|
66
67
|
] = None
|
|
67
68
|
r"""EIP-7702 authorization"""
|
|
69
|
+
|
|
70
|
+
@model_serializer(mode="wrap")
|
|
71
|
+
def serialize_model(self, handler):
|
|
72
|
+
optional_fields = ["authorizationList"]
|
|
73
|
+
nullable_fields = ["gas"]
|
|
74
|
+
null_default_fields = []
|
|
75
|
+
|
|
76
|
+
serialized = handler(self)
|
|
77
|
+
|
|
78
|
+
m = {}
|
|
79
|
+
|
|
80
|
+
for n, f in type(self).model_fields.items():
|
|
81
|
+
k = f.alias or n
|
|
82
|
+
val = serialized.get(k)
|
|
83
|
+
serialized.pop(k, None)
|
|
84
|
+
|
|
85
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
86
|
+
is_set = (
|
|
87
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
88
|
+
or k in null_default_fields
|
|
89
|
+
) # pylint: disable=no-member
|
|
90
|
+
|
|
91
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
92
|
+
m[k] = val
|
|
93
|
+
elif val != UNSET_SENTINEL and (
|
|
94
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
95
|
+
):
|
|
96
|
+
m[k] = val
|
|
97
|
+
|
|
98
|
+
return m
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
from compass_api_sdk.types import BaseModel
|
|
4
|
+
from compass_api_sdk.types import BaseModel, Nullable, UNSET_SENTINEL
|
|
5
5
|
import pydantic
|
|
6
|
+
from pydantic import model_serializer
|
|
6
7
|
from typing_extensions import Annotated, TypedDict
|
|
7
8
|
|
|
8
9
|
|
|
@@ -13,7 +14,7 @@ class UnsignedTransactionTypedDict(TypedDict):
|
|
|
13
14
|
r"""The data of the transaction"""
|
|
14
15
|
from_: str
|
|
15
16
|
r"""The sender of the transaction"""
|
|
16
|
-
gas: str
|
|
17
|
+
gas: Nullable[str]
|
|
17
18
|
r"""The gas of the transaction"""
|
|
18
19
|
to: str
|
|
19
20
|
r"""The recipient of the transaction"""
|
|
@@ -37,7 +38,7 @@ class UnsignedTransaction(BaseModel):
|
|
|
37
38
|
from_: Annotated[str, pydantic.Field(alias="from")]
|
|
38
39
|
r"""The sender of the transaction"""
|
|
39
40
|
|
|
40
|
-
gas: str
|
|
41
|
+
gas: Nullable[str]
|
|
41
42
|
r"""The gas of the transaction"""
|
|
42
43
|
|
|
43
44
|
to: str
|
|
@@ -56,3 +57,33 @@ class UnsignedTransaction(BaseModel):
|
|
|
56
57
|
str, pydantic.Field(alias="maxPriorityFeePerGas")
|
|
57
58
|
]
|
|
58
59
|
r"""The max priority fee per gas of the transaction"""
|
|
60
|
+
|
|
61
|
+
@model_serializer(mode="wrap")
|
|
62
|
+
def serialize_model(self, handler):
|
|
63
|
+
optional_fields = []
|
|
64
|
+
nullable_fields = ["gas"]
|
|
65
|
+
null_default_fields = []
|
|
66
|
+
|
|
67
|
+
serialized = handler(self)
|
|
68
|
+
|
|
69
|
+
m = {}
|
|
70
|
+
|
|
71
|
+
for n, f in type(self).model_fields.items():
|
|
72
|
+
k = f.alias or n
|
|
73
|
+
val = serialized.get(k)
|
|
74
|
+
serialized.pop(k, None)
|
|
75
|
+
|
|
76
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
77
|
+
is_set = (
|
|
78
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
79
|
+
or k in null_default_fields
|
|
80
|
+
) # pylint: disable=no-member
|
|
81
|
+
|
|
82
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
83
|
+
m[k] = val
|
|
84
|
+
elif val != UNSET_SENTINEL and (
|
|
85
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
86
|
+
):
|
|
87
|
+
m[k] = val
|
|
88
|
+
|
|
89
|
+
return m
|
|
@@ -7,7 +7,7 @@ from enum import Enum
|
|
|
7
7
|
import pydantic
|
|
8
8
|
from pydantic.functional_validators import AfterValidator
|
|
9
9
|
from typing import Literal, Optional, Union
|
|
10
|
-
from typing_extensions import Annotated, TypeAliasType, TypedDict
|
|
10
|
+
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
UnwrapWethRequestAmountTypedDict = TypeAliasType(
|
|
@@ -35,6 +35,8 @@ class UnwrapWethRequestTypedDict(TypedDict):
|
|
|
35
35
|
sender: str
|
|
36
36
|
r"""The address of the transaction sender."""
|
|
37
37
|
action_type: Literal["UNWRAP_WETH"]
|
|
38
|
+
estimate_gas: NotRequired[bool]
|
|
39
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
38
40
|
|
|
39
41
|
|
|
40
42
|
class UnwrapWethRequest(BaseModel):
|
|
@@ -55,3 +57,6 @@ class UnwrapWethRequest(BaseModel):
|
|
|
55
57
|
],
|
|
56
58
|
pydantic.Field(alias="action_type"),
|
|
57
59
|
] = "UNWRAP_WETH"
|
|
60
|
+
|
|
61
|
+
estimate_gas: Optional[bool] = None
|
|
62
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
from .aaveborrowparams import AaveBorrowParams, AaveBorrowParamsTypedDict
|
|
5
5
|
from .aaverepayparams import AaveRepayParams, AaveRepayParamsTypedDict
|
|
6
|
+
from .aavesetuseremodeparams import (
|
|
7
|
+
AaveSetUserEModeParams,
|
|
8
|
+
AaveSetUserEModeParamsTypedDict,
|
|
9
|
+
)
|
|
6
10
|
from .aavesupplyparams import AaveSupplyParams, AaveSupplyParamsTypedDict
|
|
7
11
|
from .aavewithdrawparams import AaveWithdrawParams, AaveWithdrawParamsTypedDict
|
|
8
12
|
from .aerodromeslipstreambuyexactlyparams import (
|
|
@@ -44,6 +48,7 @@ from .morphowithdrawcollateralparams import (
|
|
|
44
48
|
)
|
|
45
49
|
from .morphowithdrawparams import MorphoWithdrawParams, MorphoWithdrawParamsTypedDict
|
|
46
50
|
from .odosswapparams import OdosSwapParams, OdosSwapParamsTypedDict
|
|
51
|
+
from .oneinchswapparams import OneInchSwapParams, OneInchSwapParamsTypedDict
|
|
47
52
|
from .pendlemanageliquidityparams import (
|
|
48
53
|
PendleManageLiquidityParams,
|
|
49
54
|
PendleManageLiquidityParamsTypedDict,
|
|
@@ -91,55 +96,58 @@ from typing import Union
|
|
|
91
96
|
from typing_extensions import Annotated, TypeAliasType, TypedDict
|
|
92
97
|
|
|
93
98
|
|
|
94
|
-
|
|
95
|
-
"
|
|
99
|
+
UserOperationBodyTypedDict = TypeAliasType(
|
|
100
|
+
"UserOperationBodyTypedDict",
|
|
96
101
|
Union[
|
|
97
|
-
|
|
102
|
+
PendleRedeemYieldParamsTypedDict,
|
|
98
103
|
WrapEthParamsTypedDict,
|
|
104
|
+
AaveSetUserEModeParamsTypedDict,
|
|
99
105
|
UnwrapWethParamsTypedDict,
|
|
100
|
-
PendleRedeemYieldParamsTypedDict,
|
|
101
106
|
EthenaUnstakeParamsTypedDict,
|
|
102
|
-
|
|
103
|
-
UniswapWithdrawLiquidityProvisionParamsTypedDict,
|
|
107
|
+
EthenaRequestToWithdrawParamsTypedDict,
|
|
104
108
|
SkySellParamsTypedDict,
|
|
105
|
-
AerodromeSlipstreamWithdrawLiquidityProvisionParamsTypedDict,
|
|
106
|
-
EthenaDepositParamsTypedDict,
|
|
107
109
|
SkyDepositParamsTypedDict,
|
|
108
110
|
SkyBuyParamsTypedDict,
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
MorphoWithdrawParamsTypedDict,
|
|
111
|
+
AerodromeSlipstreamWithdrawLiquidityProvisionParamsTypedDict,
|
|
112
|
+
EthenaDepositParamsTypedDict,
|
|
113
|
+
SkyWithdrawParamsTypedDict,
|
|
114
|
+
UniswapWithdrawLiquidityProvisionParamsTypedDict,
|
|
114
115
|
TokenTransferParamsTypedDict,
|
|
116
|
+
VaultWithdrawParamsTypedDict,
|
|
115
117
|
AaveWithdrawParamsTypedDict,
|
|
118
|
+
AaveSupplyParamsTypedDict,
|
|
119
|
+
MorphoWithdrawParamsTypedDict,
|
|
116
120
|
MorphoDepositParamsTypedDict,
|
|
117
|
-
|
|
121
|
+
SetAllowanceParamsTypedDict,
|
|
122
|
+
VaultDepositParamsTypedDict,
|
|
123
|
+
AaveRepayParamsTypedDict,
|
|
118
124
|
MorphoBorrowParamsTypedDict,
|
|
125
|
+
AaveBorrowParamsTypedDict,
|
|
126
|
+
OneInchSwapParamsTypedDict,
|
|
127
|
+
OdosSwapParamsTypedDict,
|
|
119
128
|
MorphoWithdrawCollateralParamsTypedDict,
|
|
120
129
|
MorphoSupplyCollateralParamsTypedDict,
|
|
121
|
-
AaveBorrowParamsTypedDict,
|
|
122
130
|
MorphoRepayParamsTypedDict,
|
|
123
|
-
|
|
124
|
-
|
|
131
|
+
AerodromeSlipstreamSellExactlyParamsTypedDict,
|
|
132
|
+
AerodromeSlipstreamBuyExactlyParamsTypedDict,
|
|
125
133
|
UniswapIncreaseLiquidityProvisionParamsTypedDict,
|
|
126
134
|
UniswapBuyExactlyParamsTypedDict,
|
|
127
135
|
UniswapSellExactlyParamsTypedDict,
|
|
136
|
+
AerodromeSlipstreamIncreaseLiquidityProvisionParamsTypedDict,
|
|
137
|
+
PendleTradeYtParamsTypedDict,
|
|
128
138
|
PendleTradePtParamsTypedDict,
|
|
129
139
|
PendleManageLiquidityParamsTypedDict,
|
|
130
|
-
AerodromeSlipstreamBuyExactlyParamsTypedDict,
|
|
131
|
-
AerodromeSlipstreamIncreaseLiquidityProvisionParamsTypedDict,
|
|
132
|
-
AerodromeSlipstreamSellExactlyParamsTypedDict,
|
|
133
|
-
AerodromeSlipstreamMintLiquidityProvisionParamsTypedDict,
|
|
134
140
|
UniswapMintLiquidityProvisionParamsTypedDict,
|
|
141
|
+
AerodromeSlipstreamMintLiquidityProvisionParamsTypedDict,
|
|
135
142
|
],
|
|
136
143
|
)
|
|
137
144
|
|
|
138
145
|
|
|
139
|
-
|
|
146
|
+
UserOperationBody = Annotated[
|
|
140
147
|
Union[
|
|
141
148
|
Annotated[AaveBorrowParams, Tag("AAVE_BORROW")],
|
|
142
149
|
Annotated[AaveRepayParams, Tag("AAVE_REPAY")],
|
|
150
|
+
Annotated[AaveSetUserEModeParams, Tag("AAVE_SET_USER_EMODE")],
|
|
143
151
|
Annotated[AaveSupplyParams, Tag("AAVE_SUPPLY")],
|
|
144
152
|
Annotated[AaveWithdrawParams, Tag("AAVE_WITHDRAW")],
|
|
145
153
|
Annotated[
|
|
@@ -171,6 +179,7 @@ Body = Annotated[
|
|
|
171
179
|
Annotated[MorphoWithdrawParams, Tag("MORPHO_WITHDRAW")],
|
|
172
180
|
Annotated[MorphoWithdrawCollateralParams, Tag("MORPHO_WITHDRAW_COLLATERAL")],
|
|
173
181
|
Annotated[OdosSwapParams, Tag("ODOS_SWAP")],
|
|
182
|
+
Annotated[OneInchSwapParams, Tag("ONE_INCH_SWAP")],
|
|
174
183
|
Annotated[PendleManageLiquidityParams, Tag("PENDLE_MANAGE_LIQUIDITY")],
|
|
175
184
|
Annotated[PendleRedeemYieldParams, Tag("PENDLE_REDEEM_YIELD")],
|
|
176
185
|
Annotated[PendleTradePtParams, Tag("PENDLE_TRADE_PT")],
|
|
@@ -203,8 +212,8 @@ Body = Annotated[
|
|
|
203
212
|
|
|
204
213
|
|
|
205
214
|
class UserOperationTypedDict(TypedDict):
|
|
206
|
-
body:
|
|
215
|
+
body: UserOperationBodyTypedDict
|
|
207
216
|
|
|
208
217
|
|
|
209
218
|
class UserOperation(BaseModel):
|
|
210
|
-
body:
|
|
219
|
+
body: UserOperationBody
|
|
@@ -30,7 +30,7 @@ class V1AaveAaveSupportedTokensRequest(BaseModel):
|
|
|
30
30
|
chain: Annotated[
|
|
31
31
|
V1AaveAaveSupportedTokensChain,
|
|
32
32
|
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
33
|
-
]
|
|
33
|
+
]
|
|
34
34
|
|
|
35
35
|
block: Annotated[
|
|
36
36
|
OptionalNullable[int],
|
|
@@ -20,116 +20,38 @@ class V1AaveAvgRateChain(str, Enum):
|
|
|
20
20
|
ETHEREUM = "ethereum"
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
class V1AaveAvgRateToken(str, Enum):
|
|
24
|
-
r"""A class representing the token.
|
|
25
|
-
|
|
26
|
-
This class is used to represent the token in the system. Notice individual
|
|
27
|
-
endpoints' documentation where per chain tokens are presented.
|
|
28
|
-
"""
|
|
29
|
-
|
|
30
|
-
ONE_INCH = "1INCH"
|
|
31
|
-
AAVE = "AAVE"
|
|
32
|
-
AERO = "AERO"
|
|
33
|
-
ARB = "ARB"
|
|
34
|
-
BAL = "BAL"
|
|
35
|
-
BNKR = "BNKR"
|
|
36
|
-
CB_BTC = "cbBTC"
|
|
37
|
-
CB_ETH = "cbETH"
|
|
38
|
-
CLANKER = "CLANKER"
|
|
39
|
-
COPI = "COPI"
|
|
40
|
-
CRV = "CRV"
|
|
41
|
-
CRV_USD = "crvUSD"
|
|
42
|
-
CYBER = "CYBER"
|
|
43
|
-
DAI = "DAI"
|
|
44
|
-
DOGINME = "DOGINME"
|
|
45
|
-
E_BTC = "eBTC"
|
|
46
|
-
ENS = "ENS"
|
|
47
|
-
ETH = "ETH"
|
|
48
|
-
ETHFI = "ETHFI"
|
|
49
|
-
ET_HX = "ETHx"
|
|
50
|
-
EURC = "EURC"
|
|
51
|
-
EUR = "EUR"
|
|
52
|
-
EURS = "EURS"
|
|
53
|
-
E_US_DE = "eUSDe"
|
|
54
|
-
EZ_ETH = "ezETH"
|
|
55
|
-
FBTC = "FBTC"
|
|
56
|
-
FRAX = "FRAX"
|
|
57
|
-
FXS = "FXS"
|
|
58
|
-
GHO = "GHO"
|
|
59
|
-
KNC = "KNC"
|
|
60
|
-
LBTC = "LBTC"
|
|
61
|
-
LDO = "LDO"
|
|
62
|
-
LINK = "LINK"
|
|
63
|
-
LS_ETH = "LsETH"
|
|
64
|
-
LUSD = "LUSD"
|
|
65
|
-
MAI = "MAI"
|
|
66
|
-
MKR = "MKR"
|
|
67
|
-
OS_ETH = "osETH"
|
|
68
|
-
PT_E_USDE_14_AUG2025 = "PT-eUSDE-14AUG2025"
|
|
69
|
-
PT_E_USDE_29_MAY2025 = "PT-eUSDE-29MAY2025"
|
|
70
|
-
PT_S_USDE_25_SEP2025 = "PT-sUSDE-25SEP2025"
|
|
71
|
-
PT_S_USDE_31_JUL2025 = "PT-sUSDE-31JUL2025"
|
|
72
|
-
PT_US_DE_31_JUL2025 = "PT-USDe-31JUL2025"
|
|
73
|
-
PYUSD = "PYUSD"
|
|
74
|
-
R_ETH = "rETH"
|
|
75
|
-
RLUSD = "RLUSD"
|
|
76
|
-
RPL = "RPL"
|
|
77
|
-
RS_ETH = "rsETH"
|
|
78
|
-
S_DAI = "sDAI"
|
|
79
|
-
SNX = "SNX"
|
|
80
|
-
STG = "STG"
|
|
81
|
-
S_US_DE = "sUSDe"
|
|
82
|
-
T_BTC = "tBTC"
|
|
83
|
-
UNI = "UNI"
|
|
84
|
-
US_DB_C = "USDbC"
|
|
85
|
-
USD_CE = "USDCe"
|
|
86
|
-
USDC = "USDC"
|
|
87
|
-
US_DE = "USDe"
|
|
88
|
-
USDS = "USDS"
|
|
89
|
-
US_DTB = "USDtb"
|
|
90
|
-
USDT = "USDT"
|
|
91
|
-
VIRTUAL = "VIRTUAL"
|
|
92
|
-
WBTC = "WBTC"
|
|
93
|
-
WE_ETH = "weETH"
|
|
94
|
-
WELL = "WELL"
|
|
95
|
-
WETH = "WETH"
|
|
96
|
-
WRS_ETH = "wrsETH"
|
|
97
|
-
WST_ETH = "wstETH"
|
|
98
|
-
|
|
99
|
-
|
|
100
23
|
class V1AaveAvgRateRequestTypedDict(TypedDict):
|
|
101
24
|
chain: V1AaveAvgRateChain
|
|
102
|
-
|
|
103
|
-
r"""
|
|
104
|
-
token: V1AaveAvgRateToken
|
|
105
|
-
r"""The symbol of the token.."""
|
|
25
|
+
token: str
|
|
26
|
+
r"""The symbol or address of the token.."""
|
|
106
27
|
days: int
|
|
107
28
|
r"""The number of days for which the average shall be calculated."""
|
|
29
|
+
block: NotRequired[Nullable[int]]
|
|
30
|
+
r"""Optional block number (defaults to latest)."""
|
|
108
31
|
|
|
109
32
|
|
|
110
33
|
class V1AaveAvgRateRequest(BaseModel):
|
|
111
34
|
chain: Annotated[
|
|
112
35
|
V1AaveAvgRateChain,
|
|
113
36
|
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
114
|
-
]
|
|
115
|
-
|
|
116
|
-
block: Annotated[
|
|
117
|
-
OptionalNullable[int],
|
|
118
|
-
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
119
|
-
] = UNSET
|
|
120
|
-
r"""Optional block number (defaults to latest)."""
|
|
37
|
+
]
|
|
121
38
|
|
|
122
39
|
token: Annotated[
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
r"""The symbol of the token.."""
|
|
40
|
+
str, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
41
|
+
]
|
|
42
|
+
r"""The symbol or address of the token.."""
|
|
127
43
|
|
|
128
44
|
days: Annotated[
|
|
129
45
|
int, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
130
|
-
]
|
|
46
|
+
]
|
|
131
47
|
r"""The number of days for which the average shall be calculated."""
|
|
132
48
|
|
|
49
|
+
block: Annotated[
|
|
50
|
+
OptionalNullable[int],
|
|
51
|
+
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
52
|
+
] = UNSET
|
|
53
|
+
r"""Optional block number (defaults to latest)."""
|
|
54
|
+
|
|
133
55
|
@model_serializer(mode="wrap")
|
|
134
56
|
def serialize_model(self, handler):
|
|
135
57
|
optional_fields = ["block"]
|
|
@@ -15,34 +15,34 @@ class V1AaveHistoricalTransactionsChain(str, Enum):
|
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
class V1AaveHistoricalTransactionsRequestTypedDict(TypedDict):
|
|
18
|
+
chain: V1AaveHistoricalTransactionsChain
|
|
19
|
+
user_address: str
|
|
20
|
+
r"""The address of the user to get historical transactions for."""
|
|
18
21
|
offset: NotRequired[int]
|
|
19
22
|
r"""The offset of the first item to return."""
|
|
20
23
|
limit: NotRequired[int]
|
|
21
24
|
r"""The number of items to return."""
|
|
22
|
-
chain: V1AaveHistoricalTransactionsChain
|
|
23
|
-
user_address: str
|
|
24
|
-
r"""The address of the user to get historical transactions for."""
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
class V1AaveHistoricalTransactionsRequest(BaseModel):
|
|
28
|
+
chain: Annotated[
|
|
29
|
+
V1AaveHistoricalTransactionsChain,
|
|
30
|
+
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
31
|
+
]
|
|
32
|
+
|
|
33
|
+
user_address: Annotated[
|
|
34
|
+
str, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
35
|
+
]
|
|
36
|
+
r"""The address of the user to get historical transactions for."""
|
|
37
|
+
|
|
28
38
|
offset: Annotated[
|
|
29
39
|
Optional[int],
|
|
30
40
|
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
31
|
-
] =
|
|
41
|
+
] = None
|
|
32
42
|
r"""The offset of the first item to return."""
|
|
33
43
|
|
|
34
44
|
limit: Annotated[
|
|
35
45
|
Optional[int],
|
|
36
46
|
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
37
|
-
] =
|
|
47
|
+
] = None
|
|
38
48
|
r"""The number of items to return."""
|
|
39
|
-
|
|
40
|
-
chain: Annotated[
|
|
41
|
-
V1AaveHistoricalTransactionsChain,
|
|
42
|
-
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
43
|
-
] = V1AaveHistoricalTransactionsChain.BASE
|
|
44
|
-
|
|
45
|
-
user_address: Annotated[
|
|
46
|
-
str, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
47
|
-
] = "0x3254f3b1918637ba924e3F18968Cb74219974b63"
|
|
48
|
-
r"""The address of the user to get historical transactions for."""
|
|
@@ -13,87 +13,10 @@ class V1AaveLiquidityChangeChain(str, Enum):
|
|
|
13
13
|
ETHEREUM = "ethereum"
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
class V1AaveLiquidityChangeToken(str, Enum):
|
|
17
|
-
r"""A class representing the token.
|
|
18
|
-
|
|
19
|
-
This class is used to represent the token in the system. Notice individual
|
|
20
|
-
endpoints' documentation where per chain tokens are presented.
|
|
21
|
-
"""
|
|
22
|
-
|
|
23
|
-
ONE_INCH = "1INCH"
|
|
24
|
-
AAVE = "AAVE"
|
|
25
|
-
AERO = "AERO"
|
|
26
|
-
ARB = "ARB"
|
|
27
|
-
BAL = "BAL"
|
|
28
|
-
BNKR = "BNKR"
|
|
29
|
-
CB_BTC = "cbBTC"
|
|
30
|
-
CB_ETH = "cbETH"
|
|
31
|
-
CLANKER = "CLANKER"
|
|
32
|
-
COPI = "COPI"
|
|
33
|
-
CRV = "CRV"
|
|
34
|
-
CRV_USD = "crvUSD"
|
|
35
|
-
CYBER = "CYBER"
|
|
36
|
-
DAI = "DAI"
|
|
37
|
-
DOGINME = "DOGINME"
|
|
38
|
-
E_BTC = "eBTC"
|
|
39
|
-
ENS = "ENS"
|
|
40
|
-
ETH = "ETH"
|
|
41
|
-
ETHFI = "ETHFI"
|
|
42
|
-
ET_HX = "ETHx"
|
|
43
|
-
EURC = "EURC"
|
|
44
|
-
EUR = "EUR"
|
|
45
|
-
EURS = "EURS"
|
|
46
|
-
E_US_DE = "eUSDe"
|
|
47
|
-
EZ_ETH = "ezETH"
|
|
48
|
-
FBTC = "FBTC"
|
|
49
|
-
FRAX = "FRAX"
|
|
50
|
-
FXS = "FXS"
|
|
51
|
-
GHO = "GHO"
|
|
52
|
-
KNC = "KNC"
|
|
53
|
-
LBTC = "LBTC"
|
|
54
|
-
LDO = "LDO"
|
|
55
|
-
LINK = "LINK"
|
|
56
|
-
LS_ETH = "LsETH"
|
|
57
|
-
LUSD = "LUSD"
|
|
58
|
-
MAI = "MAI"
|
|
59
|
-
MKR = "MKR"
|
|
60
|
-
OS_ETH = "osETH"
|
|
61
|
-
PT_E_USDE_14_AUG2025 = "PT-eUSDE-14AUG2025"
|
|
62
|
-
PT_E_USDE_29_MAY2025 = "PT-eUSDE-29MAY2025"
|
|
63
|
-
PT_S_USDE_25_SEP2025 = "PT-sUSDE-25SEP2025"
|
|
64
|
-
PT_S_USDE_31_JUL2025 = "PT-sUSDE-31JUL2025"
|
|
65
|
-
PT_US_DE_31_JUL2025 = "PT-USDe-31JUL2025"
|
|
66
|
-
PYUSD = "PYUSD"
|
|
67
|
-
R_ETH = "rETH"
|
|
68
|
-
RLUSD = "RLUSD"
|
|
69
|
-
RPL = "RPL"
|
|
70
|
-
RS_ETH = "rsETH"
|
|
71
|
-
S_DAI = "sDAI"
|
|
72
|
-
SNX = "SNX"
|
|
73
|
-
STG = "STG"
|
|
74
|
-
S_US_DE = "sUSDe"
|
|
75
|
-
T_BTC = "tBTC"
|
|
76
|
-
UNI = "UNI"
|
|
77
|
-
US_DB_C = "USDbC"
|
|
78
|
-
USD_CE = "USDCe"
|
|
79
|
-
USDC = "USDC"
|
|
80
|
-
US_DE = "USDe"
|
|
81
|
-
USDS = "USDS"
|
|
82
|
-
US_DTB = "USDtb"
|
|
83
|
-
USDT = "USDT"
|
|
84
|
-
VIRTUAL = "VIRTUAL"
|
|
85
|
-
WBTC = "WBTC"
|
|
86
|
-
WE_ETH = "weETH"
|
|
87
|
-
WELL = "WELL"
|
|
88
|
-
WETH = "WETH"
|
|
89
|
-
WRS_ETH = "wrsETH"
|
|
90
|
-
WST_ETH = "wstETH"
|
|
91
|
-
|
|
92
|
-
|
|
93
16
|
class V1AaveLiquidityChangeRequestTypedDict(TypedDict):
|
|
94
17
|
chain: V1AaveLiquidityChangeChain
|
|
95
|
-
token:
|
|
96
|
-
r"""The symbol of the asset to get liquidity change for.."""
|
|
18
|
+
token: str
|
|
19
|
+
r"""The symbol or address of the asset to get liquidity change for.."""
|
|
97
20
|
start_block: int
|
|
98
21
|
r"""The start block to calculate liquidity change from."""
|
|
99
22
|
end_block: int
|
|
@@ -104,20 +27,19 @@ class V1AaveLiquidityChangeRequest(BaseModel):
|
|
|
104
27
|
chain: Annotated[
|
|
105
28
|
V1AaveLiquidityChangeChain,
|
|
106
29
|
FieldMetadata(query=QueryParamMetadata(style="form", explode=True)),
|
|
107
|
-
]
|
|
30
|
+
]
|
|
108
31
|
|
|
109
32
|
token: Annotated[
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
r"""The symbol of the asset to get liquidity change for.."""
|
|
33
|
+
str, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
34
|
+
]
|
|
35
|
+
r"""The symbol or address of the asset to get liquidity change for.."""
|
|
114
36
|
|
|
115
37
|
start_block: Annotated[
|
|
116
38
|
int, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
117
|
-
]
|
|
39
|
+
]
|
|
118
40
|
r"""The start block to calculate liquidity change from."""
|
|
119
41
|
|
|
120
42
|
end_block: Annotated[
|
|
121
43
|
int, FieldMetadata(query=QueryParamMetadata(style="form", explode=True))
|
|
122
|
-
]
|
|
44
|
+
]
|
|
123
45
|
r"""The end block to calculate liquidity change to."""
|