compass_api_sdk 0.9.50__py3-none-any.whl → 0.9.52__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.
Potentially problematic release.
This version of compass_api_sdk might be problematic. Click here for more details.
- compass_api_sdk/_version.py +3 -3
- compass_api_sdk/aave_v3.py +314 -260
- compass_api_sdk/aerodrome_slipstream.py +186 -184
- compass_api_sdk/erc_4626_vaults.py +82 -58
- compass_api_sdk/errors/__init__.py +3 -2
- compass_api_sdk/models/__init__.py +1742 -1516
- compass_api_sdk/models/aavereserveoverviewresponse.py +34 -3
- compass_api_sdk/models/{chain.py → compass_api_backend_config_chain_chain.py} +4 -4
- compass_api_sdk/models/compass_api_backend_models_aave_read_response_historical_transactions_aavehistoricaltransactionsresponse.py +115 -0
- compass_api_sdk/models/{borrow.py → compass_api_backend_models_aave_read_response_historical_transactions_borrow.py} +4 -2
- compass_api_sdk/models/{liquidationcall.py → compass_api_backend_models_aave_read_response_historical_transactions_liquidationcall.py} +6 -2
- compass_api_sdk/models/{redeemunderlying.py → compass_api_backend_models_aave_read_response_historical_transactions_redeemunderlying.py} +6 -2
- compass_api_sdk/models/{repay.py → compass_api_backend_models_aave_read_response_historical_transactions_repay.py} +4 -2
- compass_api_sdk/models/{supply.py → compass_api_backend_models_aave_read_response_historical_transactions_supply.py} +4 -2
- compass_api_sdk/models/{swapborrowrate.py → compass_api_backend_models_aave_read_response_historical_transactions_swapborrowrate.py} +6 -2
- compass_api_sdk/models/{usageascollateral.py → compass_api_backend_models_aave_read_response_historical_transactions_usageascollateral.py} +6 -2
- compass_api_sdk/models/{aaveborrowrequest.py → compass_api_backend_models_aave_transact_request_borrow_aaveborrowrequest.py} +24 -12
- compass_api_sdk/models/{aaverepayrequest.py → compass_api_backend_models_aave_transact_request_repay_aaverepayrequest.py} +24 -12
- compass_api_sdk/models/{aavesupplyrequest.py → compass_api_backend_models_aave_transact_request_supply_aavesupplyrequest.py} +24 -12
- compass_api_sdk/models/{aavewithdrawrequest.py → compass_api_backend_models_aave_transact_request_withdraw_aavewithdrawrequest.py} +25 -13
- compass_api_sdk/models/{aerodromelppositionsresponse.py → compass_api_backend_models_aerodrome_slipstream_read_response_positions_aerodromelppositionsresponse.py} +6 -2
- compass_api_sdk/models/compass_api_backend_models_aerodrome_slipstream_transact_request_liquidity_provision_increase_aerodromeslipstreamincreaseliquidityprovisionrequest.py +125 -0
- compass_api_sdk/models/{aerodromeslipstreammintliquidityprovisionrequest.py → compass_api_backend_models_aerodrome_slipstream_transact_request_liquidity_provision_mint_aerodromeslipstreammintliquidityprovisionrequest.py} +43 -35
- compass_api_sdk/models/compass_api_backend_models_aerodrome_slipstream_transact_request_liquidity_provision_withdraw_aerodromeslipstreamwithdrawliquidityprovisionrequest.py +68 -0
- compass_api_sdk/models/compass_api_backend_models_aerodrome_slipstream_transact_request_swap_buy_exactly_aerodromeslipstreambuyexactlyrequest.py +116 -0
- compass_api_sdk/models/{aerodromeslipstreamsellexactlyrequest.py → compass_api_backend_models_aerodrome_slipstream_transact_request_swap_sell_exactly_aerodromeslipstreamsellexactlyrequest.py} +31 -19
- compass_api_sdk/models/compass_api_backend_models_generic_read_response_chains_supportedchaininfo.py +21 -0
- compass_api_sdk/models/{portfolio.py → compass_api_backend_models_generic_read_response_portfolio_portfolio.py} +2 -2
- compass_api_sdk/models/compass_api_backend_models_generic_transact_request_allowance_setallowancerequest.py +139 -0
- compass_api_sdk/models/compass_api_backend_models_generic_transact_request_unwrap_weth_unwrapwethrequest.py +69 -0
- compass_api_sdk/models/compass_api_backend_models_generic_transact_request_wrap_eth_wrapethrequest.py +66 -0
- compass_api_sdk/models/{marketposition.py → compass_api_backend_models_morpho_read_response_check_user_position_marketposition.py} +6 -2
- compass_api_sdk/models/compass_api_backend_models_morpho_read_response_check_user_position_morphocheckuserpositionresponse.py +48 -0
- compass_api_sdk/models/{vault.py → compass_api_backend_models_morpho_read_response_check_user_position_vault.py} +4 -2
- compass_api_sdk/models/{vaultposition.py → compass_api_backend_models_morpho_read_response_check_user_position_vaultposition.py} +12 -5
- compass_api_sdk/models/{morphogetmarketresponse.py → compass_api_backend_models_morpho_read_response_get_market_morphogetmarketresponse.py} +6 -2
- compass_api_sdk/models/compass_api_backend_models_morpho_read_response_get_markets_morphogetmarketsresponse.py +26 -0
- compass_api_sdk/models/{morphomarket.py → compass_api_backend_models_morpho_read_response_get_markets_morphomarket.py} +4 -2
- compass_api_sdk/models/compass_api_backend_models_morpho_read_response_get_vaults_morphogetvaultsresponse.py +24 -0
- compass_api_sdk/models/{morphovault.py → compass_api_backend_models_morpho_read_response_get_vaults_morphovault.py} +2 -2
- compass_api_sdk/models/{morphoborrowrequest.py → compass_api_backend_models_morpho_transact_request_borrow_morphoborrowrequest.py} +22 -13
- compass_api_sdk/models/{morphodepositrequest.py → compass_api_backend_models_morpho_transact_request_deposit_morphodepositrequest.py} +26 -13
- compass_api_sdk/models/{morphorepayrequest.py → compass_api_backend_models_morpho_transact_request_repay_morphorepayrequest.py} +12 -7
- compass_api_sdk/models/{morphosupplycollateralrequest.py → compass_api_backend_models_morpho_transact_request_supply_collateral_morphosupplycollateralrequest.py} +22 -13
- compass_api_sdk/models/{morphowithdrawcollateralrequest.py → compass_api_backend_models_morpho_transact_request_withdraw_collateral_morphowithdrawcollateralrequest.py} +22 -13
- compass_api_sdk/models/{morphowithdrawrequest.py → compass_api_backend_models_morpho_transact_request_withdraw_morphowithdrawrequest.py} +18 -7
- compass_api_sdk/models/{multicallauthorizationrequest.py → compass_api_backend_models_multicall_read_request_get_authorization_multicallauthorizationrequest.py} +17 -7
- compass_api_sdk/models/{aavelooprequest.py → compass_api_backend_models_multicall_transact_request_aave_loop_request_aavelooprequest.py} +67 -13
- compass_api_sdk/models/compass_api_backend_models_multicall_transact_request_multicall_execution_request_multicallexecuterequest.py +92 -0
- compass_api_sdk/models/{useroperation.py → compass_api_backend_models_multicall_transact_request_multicall_execution_request_useroperation.py} +40 -42
- compass_api_sdk/models/{pendlegetmarketresponse.py → compass_api_backend_models_pendle_read_response_market_pendlegetmarketresponse.py} +4 -2
- compass_api_sdk/models/compass_api_backend_models_pendle_read_response_markets_pendlelistmarketsresponse.py +24 -0
- compass_api_sdk/models/{pendlemarket.py → compass_api_backend_models_pendle_read_response_markets_pendlemarket.py} +2 -2
- compass_api_sdk/models/{openposition.py → compass_api_backend_models_pendle_read_response_positions_openposition.py} +4 -2
- compass_api_sdk/models/compass_api_backend_models_pendle_read_response_positions_pendlelistuserpositionsresponse.py +24 -0
- compass_api_sdk/models/{position.py → compass_api_backend_models_pendle_read_response_positions_position.py} +18 -7
- compass_api_sdk/models/{pendleredeemyieldrequest.py → compass_api_backend_models_pendle_transact_request_redeem_yield_pendleredeemyieldrequest.py} +17 -7
- compass_api_sdk/models/{skybuyrequest.py → compass_api_backend_models_sky_transact_request_buy_skybuyrequest.py} +22 -19
- compass_api_sdk/models/{skydepositrequest.py → compass_api_backend_models_sky_transact_request_deposit_skydepositrequest.py} +26 -15
- compass_api_sdk/models/compass_api_backend_models_sky_transact_request_sell_skysellrequest.py +70 -0
- compass_api_sdk/models/{skywithdrawrequest.py → compass_api_backend_models_sky_transact_request_withdraw_skywithdrawrequest.py} +17 -10
- compass_api_sdk/models/compass_api_backend_models_smart_account_transact_request_user_operations_batcheduseroperationsrequest.py +49 -0
- compass_api_sdk/models/compass_api_backend_models_swap_transact_request_odos_odosswaprequest.py +108 -0
- compass_api_sdk/models/compass_api_backend_models_token_transact_request_transfer_tokentransferrequest.py +98 -0
- compass_api_sdk/models/compass_api_backend_models_uniswap_transact_liquidity_provision_request_increase_uniswapincreaseliquidityprovisionrequest.py +129 -0
- compass_api_sdk/models/{uniswapmintliquidityprovisionrequest.py → compass_api_backend_models_uniswap_transact_liquidity_provision_request_mint_uniswapmintliquidityprovisionrequest.py} +49 -31
- compass_api_sdk/models/compass_api_backend_models_uniswap_transact_liquidity_provision_request_withdraw_uniswapwithdrawliquidityprovisionrequest.py +68 -0
- compass_api_sdk/models/compass_api_backend_models_uniswap_transact_swap_request_buy_exactly_uniswapbuyexactlyrequest.py +123 -0
- compass_api_sdk/models/compass_api_backend_models_uniswap_transact_swap_request_sell_exactly_uniswapsellexactlyrequest.py +123 -0
- compass_api_sdk/models/{vaultgetvaultresponse.py → compass_api_backend_models_vaults_read_response_vault_vaultgetvaultresponse.py} +4 -2
- compass_api_sdk/models/compass_api_backend_models_vaults_transact_request_deposit_vaultdepositrequest.py +110 -0
- compass_api_sdk/models/compass_api_backend_models_vaults_transact_request_withdraw_vaultwithdrawrequest.py +96 -0
- compass_api_sdk/models/details.py +44 -7
- compass_api_sdk/models/movement10percent.py +65 -10
- compass_api_sdk/models/pendlemanageliquidityparams.py +81 -0
- compass_api_sdk/models/pendlemanageliquidityrequest.py +95 -0
- compass_api_sdk/models/pendletradeptparams.py +81 -0
- compass_api_sdk/models/pendletradeptrequest.py +95 -0
- compass_api_sdk/models/pendletradeytparams.py +81 -0
- compass_api_sdk/models/pendletradeytrequest.py +95 -0
- compass_api_sdk/models/pendletxresponse.py +45 -0
- compass_api_sdk/models/token_enum.py +17 -0
- compass_api_sdk/models/{tokentransferrequest.py → tokentransferparams.py} +16 -27
- compass_api_sdk/models/transactionresponse.py +40 -0
- compass_api_sdk/models/uniswapbuyexactlyparams.py +19 -24
- compass_api_sdk/models/uniswapbuyexactlytransactionresponse.py +45 -0
- compass_api_sdk/models/uniswapsellexactlyparams.py +43 -40
- compass_api_sdk/models/uniswapsellexactlytransactionresponse.py +45 -0
- compass_api_sdk/models/userstate.py +3 -3
- compass_api_sdk/models/{aave_aave_supported_tokensop.py → v1_aave_aave_supported_tokensop.py} +9 -13
- compass_api_sdk/models/{aave_avg_rateop.py → v1_aave_avg_rateop.py} +32 -19
- compass_api_sdk/models/{aave_historical_transactionsop.py → v1_aave_historical_transactionsop.py} +9 -13
- compass_api_sdk/models/{aave_liquidity_changeop.py → v1_aave_liquidity_changeop.py} +30 -17
- compass_api_sdk/models/{aave_rateop.py → v1_aave_rateop.py} +32 -19
- compass_api_sdk/models/{aave_reserve_overviewop.py → v1_aave_reserve_overviewop.py} +32 -19
- compass_api_sdk/models/{aave_std_rateop.py → v1_aave_std_rateop.py} +32 -19
- compass_api_sdk/models/{aave_token_priceop.py → v1_aave_token_priceop.py} +32 -19
- compass_api_sdk/models/{aave_user_position_per_tokenop.py → v1_aave_user_position_per_tokenop.py} +32 -19
- compass_api_sdk/models/{aave_user_position_summaryop.py → v1_aave_user_position_summaryop.py} +9 -13
- compass_api_sdk/models/{uniswap_liquidity_provision_positionsop.py → v1_aerodrome_slipstream_liquidity_provision_positionsop.py} +7 -13
- compass_api_sdk/models/{aerodrome_slipstream_pool_priceop.py → v1_aerodrome_slipstream_pool_priceop.py} +53 -25
- compass_api_sdk/models/{generic_allowanceop.py → v1_generic_allowanceop.py} +24 -25
- compass_api_sdk/models/{generic_ensop.py → v1_generic_ensop.py} +7 -13
- compass_api_sdk/models/{generic_portfolioop.py → v1_generic_portfolioop.py} +9 -13
- compass_api_sdk/models/{generic_supported_chainsop.py → v1_generic_supported_chainsop.py} +2 -2
- compass_api_sdk/models/v1_generic_supported_tokensop.py +24 -0
- compass_api_sdk/models/{morpho_market_positionop.py → v1_morpho_market_positionop.py} +9 -8
- compass_api_sdk/models/{morpho_marketop.py → v1_morpho_marketop.py} +9 -8
- compass_api_sdk/models/{morpho_marketsop.py → v1_morpho_marketsop.py} +34 -13
- compass_api_sdk/models/{morpho_user_positionop.py → v1_morpho_user_positionop.py} +9 -8
- compass_api_sdk/models/{morpho_vaultop.py → v1_morpho_vaultop.py} +9 -13
- compass_api_sdk/models/{morpho_vaultsop.py → v1_morpho_vaultsop.py} +22 -11
- compass_api_sdk/models/{pendle_marketop.py → v1_pendle_marketop.py} +9 -13
- compass_api_sdk/models/v1_pendle_marketsop.py +24 -0
- compass_api_sdk/models/{pendle_positionsop.py → v1_pendle_positionsop.py} +10 -14
- compass_api_sdk/models/{sky_positionop.py → v1_sky_positionop.py} +14 -15
- compass_api_sdk/models/{token_addressop.py → v1_token_addressop.py} +30 -17
- compass_api_sdk/models/{token_balanceop.py → v1_token_balanceop.py} +14 -18
- compass_api_sdk/models/{token_priceop.py → v1_token_priceop.py} +14 -18
- compass_api_sdk/models/v1_transaction_bundler_aave_loopop.py +24 -0
- compass_api_sdk/models/{uniswap_liquidity_provision_in_rangeop.py → v1_uniswap_liquidity_provision_in_rangeop.py} +9 -13
- compass_api_sdk/models/{aerodrome_slipstream_liquidity_provision_positionsop.py → v1_uniswap_liquidity_provision_positionsop.py} +9 -13
- compass_api_sdk/models/{uniswap_pool_priceop.py → v1_uniswap_pool_priceop.py} +59 -29
- compass_api_sdk/models/{uniswap_quote_buy_exactlyop.py → v1_uniswap_quote_buy_exactlyop.py} +65 -35
- compass_api_sdk/models/{uniswap_quote_sell_exactlyop.py → v1_uniswap_quote_sell_exactlyop.py} +65 -35
- compass_api_sdk/models/{vaults_vaultop.py → v1_vaults_vaultop.py} +9 -13
- compass_api_sdk/models/{vaultdepositrequest.py → vaultdepositparams.py} +7 -20
- compass_api_sdk/models/{vaultwithdrawrequest.py → vaultwithdrawparams.py} +2 -13
- compass_api_sdk/morpho.py +328 -228
- compass_api_sdk/pendle.py +307 -1081
- compass_api_sdk/sky.py +186 -94
- compass_api_sdk/smart_account.py +46 -18
- compass_api_sdk/swap.py +40 -26
- compass_api_sdk/token_sdk.py +76 -66
- compass_api_sdk/transaction_bundler.py +126 -76
- compass_api_sdk/uniswap_v3.py +302 -278
- compass_api_sdk/universal.py +189 -329
- compass_api_sdk/utils/__init__.py +3 -2
- {compass_api_sdk-0.9.50.dist-info → compass_api_sdk-0.9.52.dist-info}/METADATA +83 -88
- compass_api_sdk-0.9.52.dist-info/RECORD +263 -0
- compass_api_sdk/models/aavehistoricaltransactionsresponse.py +0 -65
- compass_api_sdk/models/aerodromeslipstreambuyexactlyrequest.py +0 -104
- compass_api_sdk/models/aerodromeslipstreamincreaseliquidityprovisionrequest.py +0 -123
- compass_api_sdk/models/aerodromeslipstreamwithdrawliquidityprovisionrequest.py +0 -64
- compass_api_sdk/models/batcheduseroperationsrequest.py +0 -32
- compass_api_sdk/models/generic_supported_tokensop.py +0 -28
- compass_api_sdk/models/generic_visualize_portfolioop.py +0 -37
- compass_api_sdk/models/image.py +0 -15
- compass_api_sdk/models/morphocheckuserpositionresponse.py +0 -32
- compass_api_sdk/models/morphogetmarketsresponse.py +0 -17
- compass_api_sdk/models/morphogetvaultsresponse.py +0 -17
- compass_api_sdk/models/multicallexecuterequest.py +0 -36
- compass_api_sdk/models/odosswaprequest.py +0 -86
- compass_api_sdk/models/pendle_marketsop.py +0 -28
- compass_api_sdk/models/pendle_quoteop.py +0 -128
- compass_api_sdk/models/pendleaddliquidityparams.py +0 -50
- compass_api_sdk/models/pendleaddliquidityrequest.py +0 -61
- compass_api_sdk/models/pendlebuyptparams.py +0 -48
- compass_api_sdk/models/pendlebuyptrequest.py +0 -59
- compass_api_sdk/models/pendlebuyytparams.py +0 -48
- compass_api_sdk/models/pendlebuyytrequest.py +0 -59
- compass_api_sdk/models/pendlegetquoteresponse.py +0 -15
- compass_api_sdk/models/pendlelistmarketsresponse.py +0 -17
- compass_api_sdk/models/pendlelistuserpositionsresponse.py +0 -17
- compass_api_sdk/models/pendleremoveliquidityparams.py +0 -50
- compass_api_sdk/models/pendleremoveliquidityrequest.py +0 -61
- compass_api_sdk/models/pendlesellptparams.py +0 -48
- compass_api_sdk/models/pendlesellptrequest.py +0 -61
- compass_api_sdk/models/pendlesellytparams.py +0 -48
- compass_api_sdk/models/pendlesellytrequest.py +0 -61
- compass_api_sdk/models/setallowancerequest.py +0 -109
- compass_api_sdk/models/skysellrequest.py +0 -64
- compass_api_sdk/models/supportedchaininfo.py +0 -19
- compass_api_sdk/models/txresponse.py +0 -27
- compass_api_sdk/models/uniswapbuyexactlyrequest.py +0 -112
- compass_api_sdk/models/uniswapincreaseliquidityprovisionrequest.py +0 -111
- compass_api_sdk/models/uniswapsellexactlyrequest.py +0 -104
- compass_api_sdk/models/uniswapwithdrawliquidityprovisionrequest.py +0 -63
- compass_api_sdk/models/unwrapwethrequest.py +0 -53
- compass_api_sdk/models/wrapethrequest.py +0 -52
- compass_api_sdk-0.9.50.dist-info/RECORD +0 -266
- {compass_api_sdk-0.9.50.dist-info → compass_api_sdk-0.9.52.dist-info}/WHEEL +0 -0
|
@@ -17,29 +17,38 @@ from typing import Literal, Optional, Union
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
"
|
|
20
|
+
CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmountTypedDict = TypeAliasType(
|
|
21
|
+
"CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmountTypedDict",
|
|
22
|
+
Union[float, str],
|
|
22
23
|
)
|
|
23
24
|
r"""Amount of the token to borrow from the market."""
|
|
24
25
|
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
|
|
27
|
+
CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmount = (
|
|
28
|
+
TypeAliasType(
|
|
29
|
+
"CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmount",
|
|
30
|
+
Union[float, str],
|
|
31
|
+
)
|
|
28
32
|
)
|
|
29
33
|
r"""Amount of the token to borrow from the market."""
|
|
30
34
|
|
|
31
35
|
|
|
32
|
-
class
|
|
33
|
-
|
|
34
|
-
|
|
36
|
+
class CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestChain(
|
|
37
|
+
str, Enum
|
|
38
|
+
):
|
|
39
|
+
ARBITRUM = "arbitrum"
|
|
40
|
+
BASE = "base"
|
|
41
|
+
ETHEREUM = "ethereum"
|
|
35
42
|
|
|
36
43
|
|
|
37
|
-
class
|
|
38
|
-
|
|
44
|
+
class CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestTypedDict(
|
|
45
|
+
TypedDict
|
|
46
|
+
):
|
|
47
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmountTypedDict
|
|
39
48
|
r"""Amount of the token to borrow from the market."""
|
|
40
49
|
unique_market_key: str
|
|
41
50
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
42
|
-
chain:
|
|
51
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestChain
|
|
43
52
|
sender: str
|
|
44
53
|
r"""The address of the transaction sender."""
|
|
45
54
|
action_type: Literal["MORPHO_BORROW"]
|
|
@@ -49,14 +58,14 @@ class MorphoBorrowRequestTypedDict(TypedDict):
|
|
|
49
58
|
r"""The address of the receiver of the tokens borrowed. Defaults to the transaction sender."""
|
|
50
59
|
|
|
51
60
|
|
|
52
|
-
class
|
|
53
|
-
amount:
|
|
61
|
+
class CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequest(BaseModel):
|
|
62
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestAmount
|
|
54
63
|
r"""Amount of the token to borrow from the market."""
|
|
55
64
|
|
|
56
65
|
unique_market_key: str
|
|
57
66
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
58
67
|
|
|
59
|
-
chain:
|
|
68
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestBorrowMorphoBorrowRequestChain
|
|
60
69
|
|
|
61
70
|
sender: str
|
|
62
71
|
r"""The address of the transaction sender."""
|
|
@@ -17,29 +17,38 @@ from typing import Literal, Optional, Union
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
"
|
|
20
|
+
CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmountTypedDict = TypeAliasType(
|
|
21
|
+
"CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmountTypedDict",
|
|
22
|
+
Union[float, str],
|
|
22
23
|
)
|
|
23
24
|
r"""The amount of tokens to deposit into the vault."""
|
|
24
25
|
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
|
|
27
|
+
CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmount = (
|
|
28
|
+
TypeAliasType(
|
|
29
|
+
"CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmount",
|
|
30
|
+
Union[float, str],
|
|
31
|
+
)
|
|
28
32
|
)
|
|
29
33
|
r"""The amount of tokens to deposit into the vault."""
|
|
30
34
|
|
|
31
35
|
|
|
32
|
-
class
|
|
33
|
-
|
|
34
|
-
|
|
36
|
+
class CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestChain(
|
|
37
|
+
str, Enum
|
|
38
|
+
):
|
|
39
|
+
ARBITRUM = "arbitrum"
|
|
40
|
+
BASE = "base"
|
|
41
|
+
ETHEREUM = "ethereum"
|
|
35
42
|
|
|
36
43
|
|
|
37
|
-
class
|
|
44
|
+
class CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestTypedDict(
|
|
45
|
+
TypedDict
|
|
46
|
+
):
|
|
38
47
|
vault_address: str
|
|
39
48
|
r"""The vault address you are depositing to."""
|
|
40
|
-
amount:
|
|
49
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmountTypedDict
|
|
41
50
|
r"""The amount of tokens to deposit into the vault."""
|
|
42
|
-
chain:
|
|
51
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestChain
|
|
43
52
|
sender: str
|
|
44
53
|
r"""The address of the transaction sender."""
|
|
45
54
|
action_type: Literal["MORPHO_DEPOSIT"]
|
|
@@ -47,14 +56,18 @@ class MorphoDepositRequestTypedDict(TypedDict):
|
|
|
47
56
|
r"""The address which will receive the shares from the vault representing their proportional ownership of the vault's assets. Defaults to the sender."""
|
|
48
57
|
|
|
49
58
|
|
|
50
|
-
class
|
|
59
|
+
class CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequest(
|
|
60
|
+
BaseModel
|
|
61
|
+
):
|
|
51
62
|
vault_address: str
|
|
52
63
|
r"""The vault address you are depositing to."""
|
|
53
64
|
|
|
54
|
-
amount:
|
|
65
|
+
amount: (
|
|
66
|
+
CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestAmount
|
|
67
|
+
)
|
|
55
68
|
r"""The amount of tokens to deposit into the vault."""
|
|
56
69
|
|
|
57
|
-
chain:
|
|
70
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestDepositMorphoDepositRequestChain
|
|
58
71
|
|
|
59
72
|
sender: str
|
|
60
73
|
r"""The address of the transaction sender."""
|
|
@@ -17,17 +17,22 @@ from typing import Any, Literal, Optional
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
class
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
class CompassAPIBackendModelsMorphoTransactRequestRepayMorphoRepayRequestChain(
|
|
21
|
+
str, Enum
|
|
22
|
+
):
|
|
23
|
+
ARBITRUM = "arbitrum"
|
|
24
|
+
BASE = "base"
|
|
25
|
+
ETHEREUM = "ethereum"
|
|
23
26
|
|
|
24
27
|
|
|
25
|
-
class
|
|
28
|
+
class CompassAPIBackendModelsMorphoTransactRequestRepayMorphoRepayRequestTypedDict(
|
|
29
|
+
TypedDict
|
|
30
|
+
):
|
|
26
31
|
amount: Any
|
|
27
32
|
r"""Amount of the token to repay to the market. If set to 'ALL', all debt plus interest will be paid back if the user has a sufficient token balance in their wallet."""
|
|
28
33
|
unique_market_key: str
|
|
29
34
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
30
|
-
chain:
|
|
35
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestRepayMorphoRepayRequestChain
|
|
31
36
|
sender: str
|
|
32
37
|
r"""The address of the transaction sender."""
|
|
33
38
|
action_type: Literal["MORPHO_REPAY"]
|
|
@@ -37,14 +42,14 @@ class MorphoRepayRequestTypedDict(TypedDict):
|
|
|
37
42
|
r"""An optional field for callback byte data that will be triggered upon successful repaying of debt."""
|
|
38
43
|
|
|
39
44
|
|
|
40
|
-
class
|
|
45
|
+
class CompassAPIBackendModelsMorphoTransactRequestRepayMorphoRepayRequest(BaseModel):
|
|
41
46
|
amount: Any
|
|
42
47
|
r"""Amount of the token to repay to the market. If set to 'ALL', all debt plus interest will be paid back if the user has a sufficient token balance in their wallet."""
|
|
43
48
|
|
|
44
49
|
unique_market_key: str
|
|
45
50
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
46
51
|
|
|
47
|
-
chain:
|
|
52
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestRepayMorphoRepayRequestChain
|
|
48
53
|
|
|
49
54
|
sender: str
|
|
50
55
|
r"""The address of the transaction sender."""
|
|
@@ -17,29 +17,36 @@ from typing import Literal, Optional, Union
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
"
|
|
20
|
+
CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmountTypedDict = TypeAliasType(
|
|
21
|
+
"CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmountTypedDict",
|
|
22
|
+
Union[float, str],
|
|
22
23
|
)
|
|
23
24
|
r"""Amount of the token to supply to the market as collateral."""
|
|
24
25
|
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
"
|
|
27
|
+
CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmount = TypeAliasType(
|
|
28
|
+
"CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmount",
|
|
29
|
+
Union[float, str],
|
|
28
30
|
)
|
|
29
31
|
r"""Amount of the token to supply to the market as collateral."""
|
|
30
32
|
|
|
31
33
|
|
|
32
|
-
class
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
class CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestChain(
|
|
35
|
+
str, Enum
|
|
36
|
+
):
|
|
37
|
+
ARBITRUM = "arbitrum"
|
|
38
|
+
BASE = "base"
|
|
39
|
+
ETHEREUM = "ethereum"
|
|
35
40
|
|
|
36
41
|
|
|
37
|
-
class
|
|
38
|
-
|
|
42
|
+
class CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestTypedDict(
|
|
43
|
+
TypedDict
|
|
44
|
+
):
|
|
45
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmountTypedDict
|
|
39
46
|
r"""Amount of the token to supply to the market as collateral."""
|
|
40
47
|
unique_market_key: str
|
|
41
48
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
42
|
-
chain:
|
|
49
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestChain
|
|
43
50
|
sender: str
|
|
44
51
|
r"""The address of the transaction sender."""
|
|
45
52
|
action_type: Literal["MORPHO_SUPPLY_COLLATERAL"]
|
|
@@ -49,14 +56,16 @@ class MorphoSupplyCollateralRequestTypedDict(TypedDict):
|
|
|
49
56
|
r"""An optional field for callback byte data that will be triggered upon successful supplying of collateral."""
|
|
50
57
|
|
|
51
58
|
|
|
52
|
-
class
|
|
53
|
-
|
|
59
|
+
class CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequest(
|
|
60
|
+
BaseModel
|
|
61
|
+
):
|
|
62
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestAmount
|
|
54
63
|
r"""Amount of the token to supply to the market as collateral."""
|
|
55
64
|
|
|
56
65
|
unique_market_key: str
|
|
57
66
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
58
67
|
|
|
59
|
-
chain:
|
|
68
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestSupplyCollateralMorphoSupplyCollateralRequestChain
|
|
60
69
|
|
|
61
70
|
sender: str
|
|
62
71
|
r"""The address of the transaction sender."""
|
|
@@ -17,29 +17,36 @@ from typing import Literal, Optional, Union
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypeAliasType, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
|
|
21
|
-
"
|
|
20
|
+
CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmountTypedDict = TypeAliasType(
|
|
21
|
+
"CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmountTypedDict",
|
|
22
|
+
Union[float, str],
|
|
22
23
|
)
|
|
23
24
|
r"""Amount of the token to supply to the market as collateral."""
|
|
24
25
|
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
"
|
|
27
|
+
CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmount = TypeAliasType(
|
|
28
|
+
"CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmount",
|
|
29
|
+
Union[float, str],
|
|
28
30
|
)
|
|
29
31
|
r"""Amount of the token to supply to the market as collateral."""
|
|
30
32
|
|
|
31
33
|
|
|
32
|
-
class
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestChain(
|
|
35
|
+
str, Enum
|
|
36
|
+
):
|
|
37
|
+
ARBITRUM = "arbitrum"
|
|
38
|
+
BASE = "base"
|
|
39
|
+
ETHEREUM = "ethereum"
|
|
35
40
|
|
|
36
41
|
|
|
37
|
-
class
|
|
38
|
-
|
|
42
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestTypedDict(
|
|
43
|
+
TypedDict
|
|
44
|
+
):
|
|
45
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmountTypedDict
|
|
39
46
|
r"""Amount of the token to supply to the market as collateral."""
|
|
40
47
|
unique_market_key: str
|
|
41
48
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
42
|
-
chain:
|
|
49
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestChain
|
|
43
50
|
sender: str
|
|
44
51
|
r"""The address of the transaction sender."""
|
|
45
52
|
action_type: Literal["MORPHO_WITHDRAW_COLLATERAL"]
|
|
@@ -49,14 +56,16 @@ class MorphoWithdrawCollateralRequestTypedDict(TypedDict):
|
|
|
49
56
|
r"""The address where the withdrawn collateral will be received. Defaults to sender."""
|
|
50
57
|
|
|
51
58
|
|
|
52
|
-
class
|
|
53
|
-
|
|
59
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequest(
|
|
60
|
+
BaseModel
|
|
61
|
+
):
|
|
62
|
+
amount: CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestAmount
|
|
54
63
|
r"""Amount of the token to supply to the market as collateral."""
|
|
55
64
|
|
|
56
65
|
unique_market_key: str
|
|
57
66
|
r"""The key that uniquely identifies the market. This can be found using the 'Get Markets' endpoint."""
|
|
58
67
|
|
|
59
|
-
chain:
|
|
68
|
+
chain: CompassAPIBackendModelsMorphoTransactRequestWithdrawCollateralMorphoWithdrawCollateralRequestChain
|
|
60
69
|
|
|
61
70
|
sender: str
|
|
62
71
|
r"""The address of the transaction sender."""
|
|
@@ -17,17 +17,24 @@ from typing import Any, Literal, Optional
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
class
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawMorphoWithdrawRequestChain(
|
|
21
|
+
str, Enum
|
|
22
|
+
):
|
|
23
|
+
ARBITRUM = "arbitrum"
|
|
24
|
+
BASE = "base"
|
|
25
|
+
ETHEREUM = "ethereum"
|
|
23
26
|
|
|
24
27
|
|
|
25
|
-
class
|
|
28
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawMorphoWithdrawRequestTypedDict(
|
|
29
|
+
TypedDict
|
|
30
|
+
):
|
|
26
31
|
vault_address: str
|
|
27
32
|
r"""The vault address you are withdrawing from."""
|
|
28
33
|
amount: Any
|
|
29
34
|
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
30
|
-
chain:
|
|
35
|
+
chain: (
|
|
36
|
+
CompassAPIBackendModelsMorphoTransactRequestWithdrawMorphoWithdrawRequestChain
|
|
37
|
+
)
|
|
31
38
|
sender: str
|
|
32
39
|
r"""The address of the transaction sender."""
|
|
33
40
|
action_type: Literal["MORPHO_WITHDRAW"]
|
|
@@ -35,14 +42,18 @@ class MorphoWithdrawRequestTypedDict(TypedDict):
|
|
|
35
42
|
r"""The address which will receive the tokens withdrawn. Defaults to the sender."""
|
|
36
43
|
|
|
37
44
|
|
|
38
|
-
class
|
|
45
|
+
class CompassAPIBackendModelsMorphoTransactRequestWithdrawMorphoWithdrawRequest(
|
|
46
|
+
BaseModel
|
|
47
|
+
):
|
|
39
48
|
vault_address: str
|
|
40
49
|
r"""The vault address you are withdrawing from."""
|
|
41
50
|
|
|
42
51
|
amount: Any
|
|
43
52
|
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
44
53
|
|
|
45
|
-
chain:
|
|
54
|
+
chain: (
|
|
55
|
+
CompassAPIBackendModelsMorphoTransactRequestWithdrawMorphoWithdrawRequestChain
|
|
56
|
+
)
|
|
46
57
|
|
|
47
58
|
sender: str
|
|
48
59
|
r"""The address of the transaction sender."""
|
|
@@ -1,12 +1,22 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
from .chain import Chain
|
|
5
4
|
from compass_api_sdk.types import BaseModel
|
|
5
|
+
from enum import Enum
|
|
6
6
|
from typing_extensions import TypedDict
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
class
|
|
9
|
+
class CompassAPIBackendModelsMulticallReadRequestGetAuthorizationMulticallAuthorizationRequestChain(
|
|
10
|
+
str, Enum
|
|
11
|
+
):
|
|
12
|
+
ARBITRUM = "arbitrum"
|
|
13
|
+
BASE = "base"
|
|
14
|
+
ETHEREUM = "ethereum"
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
class CompassAPIBackendModelsMulticallReadRequestGetAuthorizationMulticallAuthorizationRequestTypedDict(
|
|
18
|
+
TypedDict
|
|
19
|
+
):
|
|
10
20
|
r"""Request model for getting a multicall authorization.
|
|
11
21
|
|
|
12
22
|
This model is used to authorize a sender address to perform multicall operations,
|
|
@@ -16,13 +26,14 @@ class MulticallAuthorizationRequestTypedDict(TypedDict):
|
|
|
16
26
|
Only needs to be done once per an EOA.
|
|
17
27
|
"""
|
|
18
28
|
|
|
19
|
-
chain:
|
|
20
|
-
r"""The chain to use."""
|
|
29
|
+
chain: CompassAPIBackendModelsMulticallReadRequestGetAuthorizationMulticallAuthorizationRequestChain
|
|
21
30
|
sender: str
|
|
22
31
|
r"""The Ethereum address to use for authorization"""
|
|
23
32
|
|
|
24
33
|
|
|
25
|
-
class
|
|
34
|
+
class CompassAPIBackendModelsMulticallReadRequestGetAuthorizationMulticallAuthorizationRequest(
|
|
35
|
+
BaseModel
|
|
36
|
+
):
|
|
26
37
|
r"""Request model for getting a multicall authorization.
|
|
27
38
|
|
|
28
39
|
This model is used to authorize a sender address to perform multicall operations,
|
|
@@ -32,8 +43,7 @@ class MulticallAuthorizationRequest(BaseModel):
|
|
|
32
43
|
Only needs to be done once per an EOA.
|
|
33
44
|
"""
|
|
34
45
|
|
|
35
|
-
chain:
|
|
36
|
-
r"""The chain to use."""
|
|
46
|
+
chain: CompassAPIBackendModelsMulticallReadRequestGetAuthorizationMulticallAuthorizationRequestChain
|
|
37
47
|
|
|
38
48
|
sender: str
|
|
39
49
|
r"""The Ethereum address to use for authorization"""
|
|
@@ -1,12 +1,27 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
-
from .chain import Chain
|
|
5
4
|
from .signedauthorization import SignedAuthorization, SignedAuthorizationTypedDict
|
|
6
5
|
from .token_enum import TokenEnum
|
|
7
|
-
from compass_api_sdk.types import
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
from compass_api_sdk.types import (
|
|
7
|
+
BaseModel,
|
|
8
|
+
Nullable,
|
|
9
|
+
OptionalNullable,
|
|
10
|
+
UNSET,
|
|
11
|
+
UNSET_SENTINEL,
|
|
12
|
+
)
|
|
13
|
+
from enum import Enum
|
|
14
|
+
from pydantic import model_serializer
|
|
15
|
+
from typing import Optional, Union
|
|
16
|
+
from typing_extensions import NotRequired, TypeAliasType, TypedDict
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class CompassAPIBackendModelsMulticallTransactRequestAaveLoopRequestAaveLoopRequestChain(
|
|
20
|
+
str, Enum
|
|
21
|
+
):
|
|
22
|
+
ARBITRUM = "arbitrum"
|
|
23
|
+
BASE = "base"
|
|
24
|
+
ETHEREUM = "ethereum"
|
|
10
25
|
|
|
11
26
|
|
|
12
27
|
InitialCollateralAmountTypedDict = TypeAliasType(
|
|
@@ -45,14 +60,14 @@ LoanToValue = TypeAliasType("LoanToValue", Union[float, str])
|
|
|
45
60
|
r"""Loan To Value percentage of the loop"""
|
|
46
61
|
|
|
47
62
|
|
|
48
|
-
class
|
|
63
|
+
class CompassAPIBackendModelsMulticallTransactRequestAaveLoopRequestAaveLoopRequestTypedDict(
|
|
64
|
+
TypedDict
|
|
65
|
+
):
|
|
49
66
|
r"""Request model for executing an Aave loop strategy."""
|
|
50
67
|
|
|
51
|
-
chain:
|
|
52
|
-
r"""The chain to use."""
|
|
68
|
+
chain: CompassAPIBackendModelsMulticallTransactRequestAaveLoopRequestAaveLoopRequestChain
|
|
53
69
|
sender: str
|
|
54
70
|
r"""The address of the transaction sender."""
|
|
55
|
-
signed_authorization: SignedAuthorizationTypedDict
|
|
56
71
|
collateral_token: TokenEnum
|
|
57
72
|
r"""A class representing the token.
|
|
58
73
|
|
|
@@ -73,19 +88,22 @@ class AaveLoopRequestTypedDict(TypedDict):
|
|
|
73
88
|
r"""Maximum allowed slippage for token swaps in percentage"""
|
|
74
89
|
loan_to_value: LoanToValueTypedDict
|
|
75
90
|
r"""Loan To Value percentage of the loop"""
|
|
91
|
+
signed_authorization: NotRequired[Nullable[SignedAuthorizationTypedDict]]
|
|
92
|
+
r"""EIP-7702 authorization. Required when `is_account_abstraction` is False."""
|
|
93
|
+
is_account_abstraction: NotRequired[bool]
|
|
94
|
+
r"""Whether to use account abstraction for the transaction."""
|
|
76
95
|
|
|
77
96
|
|
|
78
|
-
class
|
|
97
|
+
class CompassAPIBackendModelsMulticallTransactRequestAaveLoopRequestAaveLoopRequest(
|
|
98
|
+
BaseModel
|
|
99
|
+
):
|
|
79
100
|
r"""Request model for executing an Aave loop strategy."""
|
|
80
101
|
|
|
81
|
-
chain:
|
|
82
|
-
r"""The chain to use."""
|
|
102
|
+
chain: CompassAPIBackendModelsMulticallTransactRequestAaveLoopRequestAaveLoopRequestChain
|
|
83
103
|
|
|
84
104
|
sender: str
|
|
85
105
|
r"""The address of the transaction sender."""
|
|
86
106
|
|
|
87
|
-
signed_authorization: SignedAuthorization
|
|
88
|
-
|
|
89
107
|
collateral_token: TokenEnum
|
|
90
108
|
r"""A class representing the token.
|
|
91
109
|
|
|
@@ -111,3 +129,39 @@ class AaveLoopRequest(BaseModel):
|
|
|
111
129
|
|
|
112
130
|
loan_to_value: LoanToValue
|
|
113
131
|
r"""Loan To Value percentage of the loop"""
|
|
132
|
+
|
|
133
|
+
signed_authorization: OptionalNullable[SignedAuthorization] = UNSET
|
|
134
|
+
r"""EIP-7702 authorization. Required when `is_account_abstraction` is False."""
|
|
135
|
+
|
|
136
|
+
is_account_abstraction: Optional[bool] = False
|
|
137
|
+
r"""Whether to use account abstraction for the transaction."""
|
|
138
|
+
|
|
139
|
+
@model_serializer(mode="wrap")
|
|
140
|
+
def serialize_model(self, handler):
|
|
141
|
+
optional_fields = ["signed_authorization", "is_account_abstraction"]
|
|
142
|
+
nullable_fields = ["signed_authorization"]
|
|
143
|
+
null_default_fields = []
|
|
144
|
+
|
|
145
|
+
serialized = handler(self)
|
|
146
|
+
|
|
147
|
+
m = {}
|
|
148
|
+
|
|
149
|
+
for n, f in type(self).model_fields.items():
|
|
150
|
+
k = f.alias or n
|
|
151
|
+
val = serialized.get(k)
|
|
152
|
+
serialized.pop(k, None)
|
|
153
|
+
|
|
154
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
155
|
+
is_set = (
|
|
156
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
157
|
+
or k in null_default_fields
|
|
158
|
+
) # pylint: disable=no-member
|
|
159
|
+
|
|
160
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
161
|
+
m[k] = val
|
|
162
|
+
elif val != UNSET_SENTINEL and (
|
|
163
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
164
|
+
):
|
|
165
|
+
m[k] = val
|
|
166
|
+
|
|
167
|
+
return m
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .compass_api_backend_models_multicall_transact_request_multicall_execution_request_useroperation import (
|
|
5
|
+
CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestUserOperation,
|
|
6
|
+
CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestUserOperationTypedDict,
|
|
7
|
+
)
|
|
8
|
+
from .signedauthorization import SignedAuthorization, SignedAuthorizationTypedDict
|
|
9
|
+
from compass_api_sdk.types import (
|
|
10
|
+
BaseModel,
|
|
11
|
+
Nullable,
|
|
12
|
+
OptionalNullable,
|
|
13
|
+
UNSET,
|
|
14
|
+
UNSET_SENTINEL,
|
|
15
|
+
)
|
|
16
|
+
from enum import Enum
|
|
17
|
+
from pydantic import model_serializer
|
|
18
|
+
from typing import List
|
|
19
|
+
from typing_extensions import NotRequired, TypedDict
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestMulticallExecuteRequestChain(
|
|
23
|
+
str, Enum
|
|
24
|
+
):
|
|
25
|
+
ARBITRUM = "arbitrum"
|
|
26
|
+
BASE = "base"
|
|
27
|
+
ETHEREUM = "ethereum"
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestMulticallExecuteRequestTypedDict(
|
|
31
|
+
TypedDict
|
|
32
|
+
):
|
|
33
|
+
r"""Request model for executing a multicall."""
|
|
34
|
+
|
|
35
|
+
chain: CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestMulticallExecuteRequestChain
|
|
36
|
+
sender: str
|
|
37
|
+
r"""The address of the transaction sender."""
|
|
38
|
+
actions: List[
|
|
39
|
+
CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestUserOperationTypedDict
|
|
40
|
+
]
|
|
41
|
+
r"""List of possible actions for multicall"""
|
|
42
|
+
signed_authorization: NotRequired[Nullable[SignedAuthorizationTypedDict]]
|
|
43
|
+
r"""EIP-7702 authorization"""
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
class CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestMulticallExecuteRequest(
|
|
47
|
+
BaseModel
|
|
48
|
+
):
|
|
49
|
+
r"""Request model for executing a multicall."""
|
|
50
|
+
|
|
51
|
+
chain: CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestMulticallExecuteRequestChain
|
|
52
|
+
|
|
53
|
+
sender: str
|
|
54
|
+
r"""The address of the transaction sender."""
|
|
55
|
+
|
|
56
|
+
actions: List[
|
|
57
|
+
CompassAPIBackendModelsMulticallTransactRequestMulticallExecutionRequestUserOperation
|
|
58
|
+
]
|
|
59
|
+
r"""List of possible actions for multicall"""
|
|
60
|
+
|
|
61
|
+
signed_authorization: OptionalNullable[SignedAuthorization] = UNSET
|
|
62
|
+
r"""EIP-7702 authorization"""
|
|
63
|
+
|
|
64
|
+
@model_serializer(mode="wrap")
|
|
65
|
+
def serialize_model(self, handler):
|
|
66
|
+
optional_fields = ["signed_authorization"]
|
|
67
|
+
nullable_fields = ["signed_authorization"]
|
|
68
|
+
null_default_fields = []
|
|
69
|
+
|
|
70
|
+
serialized = handler(self)
|
|
71
|
+
|
|
72
|
+
m = {}
|
|
73
|
+
|
|
74
|
+
for n, f in type(self).model_fields.items():
|
|
75
|
+
k = f.alias or n
|
|
76
|
+
val = serialized.get(k)
|
|
77
|
+
serialized.pop(k, None)
|
|
78
|
+
|
|
79
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
80
|
+
is_set = (
|
|
81
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
82
|
+
or k in null_default_fields
|
|
83
|
+
) # pylint: disable=no-member
|
|
84
|
+
|
|
85
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
86
|
+
m[k] = val
|
|
87
|
+
elif val != UNSET_SENTINEL and (
|
|
88
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
89
|
+
):
|
|
90
|
+
m[k] = val
|
|
91
|
+
|
|
92
|
+
return m
|