compass_api_sdk 0.9.35__py3-none-any.whl → 2.0.21rc1__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 +971 -728
- compass_api_sdk/aerodrome_slipstream.py +367 -390
- compass_api_sdk/basesdk.py +21 -5
- compass_api_sdk/bridge.py +536 -0
- compass_api_sdk/earn.py +1780 -0
- compass_api_sdk/erc_4626_vaults.py +127 -154
- compass_api_sdk/errors/__init__.py +38 -4
- compass_api_sdk/errors/apierror.py +32 -14
- compass_api_sdk/errors/compassapierror.py +30 -0
- compass_api_sdk/errors/httpvalidationerror.py +15 -8
- compass_api_sdk/errors/mintpreparenotfoundresponse_error.py +49 -0
- compass_api_sdk/errors/no_response_error.py +17 -0
- compass_api_sdk/errors/responsevalidationerror.py +27 -0
- compass_api_sdk/{token_sdk.py → ethena.py} +318 -293
- compass_api_sdk/gas_sponsorship.py +446 -0
- compass_api_sdk/httpclient.py +0 -1
- compass_api_sdk/models/__init__.py +1701 -945
- compass_api_sdk/models/aaveborrowparams.py +4 -13
- compass_api_sdk/models/aaveborrowrequest.py +19 -19
- compass_api_sdk/models/aavehistoricaltransactionsresponse.py +8 -8
- compass_api_sdk/models/aavelooprequest.py +88 -36
- compass_api_sdk/models/aaveposition.py +49 -0
- compass_api_sdk/models/aaverepayparams.py +4 -13
- compass_api_sdk/models/aaverepayrequest.py +19 -19
- compass_api_sdk/models/aavereserveoverviewresponse.py +34 -3
- 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 +19 -19
- compass_api_sdk/models/aavesupportedtokenmetadata.py +30 -0
- compass_api_sdk/models/aavesupportedtokensresponse.py +20 -0
- compass_api_sdk/models/aavevenue.py +27 -0
- compass_api_sdk/models/aavewithdrawparams.py +4 -13
- compass_api_sdk/models/aavewithdrawrequest.py +19 -19
- 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 +21 -31
- compass_api_sdk/models/aerodromeslipstreamincreaseliquidityprovisionrequest.py +13 -6
- compass_api_sdk/models/aerodromeslipstreammintliquidityprovisionparams.py +8 -25
- compass_api_sdk/models/aerodromeslipstreammintliquidityprovisionrequest.py +21 -31
- compass_api_sdk/models/aerodromeslipstreampoolpriceresponse.py +8 -25
- compass_api_sdk/models/aerodromeslipstreamsellexactlyparams.py +8 -25
- compass_api_sdk/models/aerodromeslipstreamsellexactlyrequest.py +20 -30
- compass_api_sdk/models/aerodromeslipstreamwithdrawliquidityprovisionrequest.py +13 -6
- compass_api_sdk/models/approvetransferrequest.py +32 -0
- compass_api_sdk/models/{curator.py → approvetransferresponse.py} +12 -13
- compass_api_sdk/models/apy.py +3 -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 +24 -9
- compass_api_sdk/models/bundlertransactionresponse.py +17 -0
- compass_api_sdk/models/chain.py +3 -3
- 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_vault_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_v1_models_morpho_read_response_get_vaults_vaultstate.py +73 -0
- compass_api_sdk/models/compass_api_backend_v1_models_pendle_read_response_market_userposition.py +82 -0
- 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_v1_models_vaults_read_response_vault_userposition.py +20 -0
- 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 +49 -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/cooldownposition.py +35 -0
- compass_api_sdk/models/createaccountrequest.py +40 -0
- compass_api_sdk/models/createaccountresponse.py +56 -0
- compass_api_sdk/models/depositforburnrequest.py +77 -0
- compass_api_sdk/models/depositforburnresponse.py +100 -0
- compass_api_sdk/models/details.py +44 -7
- compass_api_sdk/models/earnmanageparams.py +74 -0
- compass_api_sdk/models/earnmanagerequest.py +130 -0
- compass_api_sdk/models/{compass_api_backend_models_morpho_read_response_get_market_asset.py → earnmanageresponse.py} +13 -21
- compass_api_sdk/models/earnpositionsresponse.py +39 -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/ethenadepositparams.py +82 -0
- compass_api_sdk/models/ethenadepositrequest.py +100 -0
- compass_api_sdk/models/ethenagetvaultresponse.py +109 -0
- compass_api_sdk/models/ethenarequesttowithdrawparams.py +28 -0
- compass_api_sdk/models/ethenarequesttowithdrawrequest.py +46 -0
- compass_api_sdk/models/ethenarequesttowithdrawtransactionresponse.py +37 -0
- compass_api_sdk/models/ethenaunstakeparams.py +65 -0
- compass_api_sdk/models/ethenaunstakerequest.py +83 -0
- compass_api_sdk/models/fee.py +42 -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 +9 -3
- compass_api_sdk/models/morphocheckuserpositionresponse.py +9 -3
- compass_api_sdk/models/morphodepositrequest.py +9 -3
- compass_api_sdk/models/morphogetmarketresponse.py +72 -31
- compass_api_sdk/models/morphomarket.py +26 -20
- compass_api_sdk/models/morphorepayrequest.py +14 -3
- compass_api_sdk/models/morphosupplycollateralrequest.py +14 -3
- compass_api_sdk/models/morphovault.py +10 -10
- compass_api_sdk/models/morphowithdrawcollateralrequest.py +9 -3
- compass_api_sdk/models/morphowithdrawrequest.py +9 -3
- compass_api_sdk/models/movement10percent.py +65 -10
- compass_api_sdk/models/multicallauthorizationrequest.py +9 -9
- compass_api_sdk/models/multicallexecuterequest.py +59 -11
- compass_api_sdk/models/odosswapparams.py +52 -0
- compass_api_sdk/models/odosswaprequest.py +72 -0
- compass_api_sdk/models/odostransactionresponse.py +37 -0
- 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/pendlegetmarketresponse.py +52 -2
- compass_api_sdk/models/pendlemanageliquidityparams.py +68 -0
- compass_api_sdk/models/pendlemanageliquidityrequest.py +87 -0
- compass_api_sdk/models/pendleredeemyieldrequest.py +15 -6
- compass_api_sdk/models/pendletradeptparams.py +68 -0
- compass_api_sdk/models/pendletradeptrequest.py +87 -0
- compass_api_sdk/models/pendletradeytparams.py +68 -0
- compass_api_sdk/models/pendletradeytrequest.py +87 -0
- compass_api_sdk/models/pendletxresponse.py +36 -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/protocol.py +13 -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 +5 -16
- compass_api_sdk/models/setallowancerequest.py +19 -22
- compass_api_sdk/models/skybuyrequest.py +12 -9
- compass_api_sdk/models/skydepositrequest.py +13 -9
- compass_api_sdk/models/skysellrequest.py +12 -9
- compass_api_sdk/models/skywithdrawrequest.py +13 -9
- compass_api_sdk/models/sponsorgasrequest.py +71 -0
- compass_api_sdk/models/sponsorgasresponse.py +14 -0
- compass_api_sdk/models/supportedchaininfo.py +19 -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 +54 -0
- compass_api_sdk/models/tokentransferrequest.py +23 -27
- compass_api_sdk/models/transactionresponse.py +31 -0
- compass_api_sdk/models/{compass_api_backend_models_vaults_read_response_vault_asset.py → underlyingtoken.py} +2 -2
- compass_api_sdk/models/uniswapbuyexactlyparams.py +19 -41
- compass_api_sdk/models/uniswapbuyexactlyrequest.py +31 -44
- compass_api_sdk/models/uniswapbuyexactlytransactionresponse.py +37 -0
- compass_api_sdk/models/uniswapincreaseliquidityprovisionrequest.py +15 -6
- compass_api_sdk/models/uniswapmintliquidityprovisionparams.py +8 -25
- compass_api_sdk/models/uniswapmintliquidityprovisionrequest.py +23 -31
- compass_api_sdk/models/uniswappoolpriceresponse.py +8 -25
- compass_api_sdk/models/uniswappositionssolidityresponse.py +42 -2
- compass_api_sdk/models/uniswapsellexactlyparams.py +19 -41
- compass_api_sdk/models/uniswapsellexactlyrequest.py +31 -44
- compass_api_sdk/models/uniswapsellexactlytransactionresponse.py +37 -0
- compass_api_sdk/models/uniswapwithdrawliquidityprovisionrequest.py +15 -6
- compass_api_sdk/models/unsignedmulticalltransaction.py +44 -13
- compass_api_sdk/models/unsignedtransaction.py +44 -13
- compass_api_sdk/models/unwrapwethrequest.py +15 -6
- compass_api_sdk/models/useroperation.py +61 -49
- compass_api_sdk/models/useroperationresponse.py +2 -2
- compass_api_sdk/models/userstate.py +3 -3
- compass_api_sdk/models/v1_aave_aave_supported_tokensop.py +69 -0
- compass_api_sdk/models/v1_aave_avg_rateop.py +83 -0
- compass_api_sdk/models/{aave_historical_transactionsop.py → v1_aave_historical_transactionsop.py} +21 -25
- compass_api_sdk/models/v1_aave_liquidity_changeop.py +45 -0
- compass_api_sdk/models/{pendle_marketop.py → v1_aave_rateop.py} +16 -20
- compass_api_sdk/models/v1_aave_reserve_overviewop.py +76 -0
- compass_api_sdk/models/v1_aave_std_rateop.py +83 -0
- compass_api_sdk/models/v1_aave_token_priceop.py +76 -0
- compass_api_sdk/models/v1_aave_user_position_per_tokenop.py +83 -0
- compass_api_sdk/models/{aave_user_position_summaryop.py → v1_aave_user_position_summaryop.py} +16 -20
- compass_api_sdk/models/v1_aerodrome_slipstream_liquidity_provision_positionsop.py +76 -0
- compass_api_sdk/models/v1_aerodrome_slipstream_pool_priceop.py +45 -0
- compass_api_sdk/models/v1_ethena_vaultop.py +75 -0
- compass_api_sdk/models/{generic_allowanceop.py → v1_generic_allowanceop.py} +28 -41
- compass_api_sdk/models/{generic_ensop.py → v1_generic_ensop.py} +8 -14
- compass_api_sdk/models/{generic_portfolioop.py → v1_generic_portfolioop.py} +10 -14
- compass_api_sdk/models/v1_generic_supported_chainsop.py +57 -0
- compass_api_sdk/models/{morpho_market_positionop.py → v1_morpho_market_positionop.py} +11 -10
- compass_api_sdk/models/{morpho_marketop.py → v1_morpho_marketop.py} +10 -9
- compass_api_sdk/models/{morpho_marketsop.py → v1_morpho_marketsop.py} +13 -12
- compass_api_sdk/models/{morpho_user_positionop.py → v1_morpho_user_positionop.py} +10 -9
- compass_api_sdk/models/{vaults_vaultop.py → v1_morpho_vaultop.py} +16 -20
- compass_api_sdk/models/{morpho_vaultsop.py → v1_morpho_vaultsop.py} +11 -10
- compass_api_sdk/models/{pendle_positionop.py → v1_pendle_marketop.py} +24 -27
- 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/v1_sky_positionop.py +29 -0
- compass_api_sdk/models/v1_token_balanceop.py +38 -0
- compass_api_sdk/models/v1_token_listop.py +24 -0
- compass_api_sdk/models/v1_token_priceop.py +76 -0
- compass_api_sdk/models/v1_transaction_bundler_aave_loopop.py +27 -0
- compass_api_sdk/models/{uniswap_liquidity_provision_in_rangeop.py → v1_uniswap_liquidity_provision_in_rangeop.py} +10 -14
- compass_api_sdk/models/{uniswap_liquidity_provision_positionsop.py → v1_uniswap_liquidity_provision_positionsop.py} +10 -14
- compass_api_sdk/models/v1_uniswap_pool_priceop.py +58 -0
- compass_api_sdk/models/v1_uniswap_quote_buy_exactlyop.py +79 -0
- compass_api_sdk/models/v1_uniswap_quote_sell_exactlyop.py +79 -0
- compass_api_sdk/models/v1_vaults_vaultop.py +84 -0
- 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_positionsop.py +56 -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/vaultdepositparams.py +85 -0
- compass_api_sdk/models/vaultdepositrequest.py +15 -6
- compass_api_sdk/models/vaultgetvaultresponse.py +21 -11
- 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/vaultwithdrawparams.py +75 -0
- compass_api_sdk/models/vaultwithdrawrequest.py +15 -6
- compass_api_sdk/models/wildcatgetmarketresponse.py +151 -0
- compass_api_sdk/models/{redeemunderlying.py → withdraw.py} +2 -2
- compass_api_sdk/models/wrapethrequest.py +15 -6
- compass_api_sdk/morpho.py +481 -816
- compass_api_sdk/pendle.py +495 -1384
- compass_api_sdk/sdk.py +39 -13
- compass_api_sdk/sky.py +275 -240
- compass_api_sdk/smart_account.py +37 -50
- compass_api_sdk/swap.py +248 -0
- compass_api_sdk/token.py +1192 -0
- compass_api_sdk/transaction_bundler.py +151 -184
- compass_api_sdk/uniswap_v3.py +531 -620
- compass_api_sdk/universal.py +181 -932
- compass_api_sdk/utils/__init__.py +18 -5
- compass_api_sdk/utils/annotations.py +32 -8
- compass_api_sdk/utils/eventstreaming.py +10 -0
- compass_api_sdk/utils/forms.py +21 -10
- compass_api_sdk/utils/queryparams.py +14 -2
- compass_api_sdk/utils/retries.py +69 -5
- compass_api_sdk/utils/serializers.py +3 -2
- compass_api_sdk/utils/unmarshal_json_response.py +38 -0
- compass_api_sdk/wildcat.py +208 -0
- compass_api_sdk-2.0.21rc1.dist-info/METADATA +623 -0
- compass_api_sdk-2.0.21rc1.dist-info/RECORD +346 -0
- {compass_api_sdk-0.9.35.dist-info → compass_api_sdk-2.0.21rc1.dist-info}/WHEEL +1 -1
- compass_api_sdk/models/aave_avg_rateop.py +0 -141
- compass_api_sdk/models/aave_liquidity_changeop.py +0 -103
- compass_api_sdk/models/aave_rateop.py +0 -134
- compass_api_sdk/models/aave_reserve_overviewop.py +0 -134
- compass_api_sdk/models/aave_std_rateop.py +0 -141
- compass_api_sdk/models/aave_token_priceop.py +0 -134
- compass_api_sdk/models/aave_user_position_per_tokenop.py +0 -141
- compass_api_sdk/models/aerodrome_slipstream_liquidity_provision_positionsop.py +0 -37
- compass_api_sdk/models/aerodrome_slipstream_pool_priceop.py +0 -159
- compass_api_sdk/models/aerodromeposition.py +0 -70
- compass_api_sdk/models/compass_api_backend_models_morpho_read_response_get_vault_vaultstate.py +0 -53
- compass_api_sdk/models/compass_api_backend_models_morpho_read_response_get_vaults_vaultstate.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/liquidity.py +0 -16
- compass_api_sdk/models/metadata.py +0 -50
- compass_api_sdk/models/morpho_vault_positionop.py +0 -37
- compass_api_sdk/models/morpho_vaultop.py +0 -30
- compass_api_sdk/models/morphocheckvaultpositionresponse.py +0 -20
- compass_api_sdk/models/morphogetvaultresponse.py +0 -86
- compass_api_sdk/models/pendle_marketsop.py +0 -28
- 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/pendlegetuserpositionresponse.py +0 -56
- 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/sky_positionop.py +0 -31
- compass_api_sdk/models/token_addressop.py +0 -89
- compass_api_sdk/models/token_balanceop.py +0 -55
- compass_api_sdk/models/token_enum.py +0 -57
- compass_api_sdk/models/token_priceop.py +0 -89
- compass_api_sdk/models/tokenaddressresponse.py +0 -15
- compass_api_sdk/models/tokeninfo.py +0 -17
- compass_api_sdk/models/tokentransfererc20params.py +0 -63
- compass_api_sdk/models/txresponse.py +0 -27
- compass_api_sdk/models/uniswap_pool_priceop.py +0 -170
- compass_api_sdk/models/uniswap_quote_buy_exactlyop.py +0 -191
- compass_api_sdk/models/uniswap_quote_sell_exactlyop.py +0 -191
- compass_api_sdk/models/userposition.py +0 -16
- compass_api_sdk/models/vaultposition.py +0 -24
- compass_api_sdk-0.9.35.dist-info/METADATA +0 -558
- compass_api_sdk-0.9.35.dist-info/RECORD +0 -260
|
@@ -1,7 +1,6 @@
|
|
|
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 (
|
|
6
5
|
BaseModel,
|
|
7
6
|
Nullable,
|
|
@@ -10,6 +9,7 @@ from compass_api_sdk.types import (
|
|
|
10
9
|
UNSET_SENTINEL,
|
|
11
10
|
)
|
|
12
11
|
from compass_api_sdk.utils import validate_const
|
|
12
|
+
from enum import Enum
|
|
13
13
|
import pydantic
|
|
14
14
|
from pydantic import model_serializer
|
|
15
15
|
from pydantic.functional_validators import AfterValidator
|
|
@@ -29,18 +29,25 @@ VaultDepositRequestAmount = TypeAliasType(
|
|
|
29
29
|
r"""The amount of tokens to deposit into the vault."""
|
|
30
30
|
|
|
31
31
|
|
|
32
|
+
class VaultDepositRequestChain(str, Enum):
|
|
33
|
+
ARBITRUM = "arbitrum"
|
|
34
|
+
BASE = "base"
|
|
35
|
+
ETHEREUM = "ethereum"
|
|
36
|
+
|
|
37
|
+
|
|
32
38
|
class VaultDepositRequestTypedDict(TypedDict):
|
|
33
39
|
vault_address: str
|
|
34
40
|
r"""The vault address you are depositing to."""
|
|
35
41
|
amount: VaultDepositRequestAmountTypedDict
|
|
36
42
|
r"""The amount of tokens to deposit into the vault."""
|
|
37
|
-
chain:
|
|
38
|
-
r"""The chain to use."""
|
|
43
|
+
chain: VaultDepositRequestChain
|
|
39
44
|
sender: str
|
|
40
45
|
r"""The address of the transaction sender."""
|
|
41
46
|
action_type: Literal["VAULT_DEPOSIT"]
|
|
42
47
|
receiver: NotRequired[Nullable[str]]
|
|
43
48
|
r"""The address which will receive the shares from the vault representing their proportional ownership of the vault's assets. Defaults to the sender."""
|
|
49
|
+
estimate_gas: NotRequired[bool]
|
|
50
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
44
51
|
|
|
45
52
|
|
|
46
53
|
class VaultDepositRequest(BaseModel):
|
|
@@ -50,8 +57,7 @@ class VaultDepositRequest(BaseModel):
|
|
|
50
57
|
amount: VaultDepositRequestAmount
|
|
51
58
|
r"""The amount of tokens to deposit into the vault."""
|
|
52
59
|
|
|
53
|
-
chain:
|
|
54
|
-
r"""The chain to use."""
|
|
60
|
+
chain: VaultDepositRequestChain
|
|
55
61
|
|
|
56
62
|
sender: str
|
|
57
63
|
r"""The address of the transaction sender."""
|
|
@@ -67,9 +73,12 @@ class VaultDepositRequest(BaseModel):
|
|
|
67
73
|
receiver: OptionalNullable[str] = UNSET
|
|
68
74
|
r"""The address which will receive the shares from the vault representing their proportional ownership of the vault's assets. Defaults to the sender."""
|
|
69
75
|
|
|
76
|
+
estimate_gas: Optional[bool] = None
|
|
77
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
78
|
+
|
|
70
79
|
@model_serializer(mode="wrap")
|
|
71
80
|
def serialize_model(self, handler):
|
|
72
|
-
optional_fields = ["action_type", "receiver"]
|
|
81
|
+
optional_fields = ["action_type", "receiver", "estimate_gas"]
|
|
73
82
|
nullable_fields = ["receiver"]
|
|
74
83
|
null_default_fields = []
|
|
75
84
|
|
|
@@ -2,14 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
from .apy import Apy, ApyTypedDict
|
|
5
|
-
from .
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
from .compass_api_backend_v1_models_vaults_read_response_vault_userposition import (
|
|
6
|
+
CompassAPIBackendV1ModelsVaultsReadResponseVaultUserPosition,
|
|
7
|
+
CompassAPIBackendV1ModelsVaultsReadResponseVaultUserPositionTypedDict,
|
|
8
|
+
)
|
|
9
|
+
from .underlyingtoken import UnderlyingToken, UnderlyingTokenTypedDict
|
|
10
|
+
from compass_api_sdk.types import (
|
|
11
|
+
BaseModel,
|
|
12
|
+
Nullable,
|
|
13
|
+
OptionalNullable,
|
|
14
|
+
UNSET,
|
|
15
|
+
UNSET_SENTINEL,
|
|
8
16
|
)
|
|
9
|
-
from .userposition import UserPosition, UserPositionTypedDict
|
|
10
|
-
from compass_api_sdk.types import BaseModel, Nullable, UNSET_SENTINEL
|
|
11
17
|
from pydantic import model_serializer
|
|
12
|
-
from typing_extensions import TypedDict
|
|
18
|
+
from typing_extensions import NotRequired, TypedDict
|
|
13
19
|
|
|
14
20
|
|
|
15
21
|
class VaultGetVaultResponseTypedDict(TypedDict):
|
|
@@ -25,9 +31,11 @@ class VaultGetVaultResponseTypedDict(TypedDict):
|
|
|
25
31
|
r"""Total amount of shares issued from the vault."""
|
|
26
32
|
share_price: str
|
|
27
33
|
r"""The price of one vault share in terms of the underlying asset."""
|
|
28
|
-
|
|
34
|
+
underlying_token: UnderlyingTokenTypedDict
|
|
29
35
|
apy: ApyTypedDict
|
|
30
|
-
user_position:
|
|
36
|
+
user_position: NotRequired[
|
|
37
|
+
Nullable[CompassAPIBackendV1ModelsVaultsReadResponseVaultUserPositionTypedDict]
|
|
38
|
+
]
|
|
31
39
|
r"""The user's position in the vault."""
|
|
32
40
|
|
|
33
41
|
|
|
@@ -50,16 +58,18 @@ class VaultGetVaultResponse(BaseModel):
|
|
|
50
58
|
share_price: str
|
|
51
59
|
r"""The price of one vault share in terms of the underlying asset."""
|
|
52
60
|
|
|
53
|
-
|
|
61
|
+
underlying_token: UnderlyingToken
|
|
54
62
|
|
|
55
63
|
apy: Apy
|
|
56
64
|
|
|
57
|
-
user_position:
|
|
65
|
+
user_position: OptionalNullable[
|
|
66
|
+
CompassAPIBackendV1ModelsVaultsReadResponseVaultUserPosition
|
|
67
|
+
] = UNSET
|
|
58
68
|
r"""The user's position in the vault."""
|
|
59
69
|
|
|
60
70
|
@model_serializer(mode="wrap")
|
|
61
71
|
def serialize_model(self, handler):
|
|
62
|
-
optional_fields = []
|
|
72
|
+
optional_fields = ["user_position"]
|
|
63
73
|
nullable_fields = ["user_position"]
|
|
64
74
|
null_default_fields = []
|
|
65
75
|
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from compass_api_sdk.types import (
|
|
5
|
+
BaseModel,
|
|
6
|
+
Nullable,
|
|
7
|
+
OptionalNullable,
|
|
8
|
+
UNSET,
|
|
9
|
+
UNSET_SENTINEL,
|
|
10
|
+
)
|
|
11
|
+
from pydantic import model_serializer
|
|
12
|
+
from typing_extensions import NotRequired, TypedDict
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class VaultInfoTypedDict(TypedDict):
|
|
16
|
+
r"""Information about a single ERC-4626 vault from the database."""
|
|
17
|
+
|
|
18
|
+
vault_address: str
|
|
19
|
+
r"""The vault contract address."""
|
|
20
|
+
chain: str
|
|
21
|
+
r"""Blockchain name (e.g., 'ethereum', 'base')."""
|
|
22
|
+
owner: str
|
|
23
|
+
r"""The vault owner address."""
|
|
24
|
+
asset: str
|
|
25
|
+
r"""The underlying asset contract address."""
|
|
26
|
+
name: NotRequired[Nullable[str]]
|
|
27
|
+
r"""The name of the vault."""
|
|
28
|
+
symbol: NotRequired[Nullable[str]]
|
|
29
|
+
r"""The vault share token symbol."""
|
|
30
|
+
asset_name: NotRequired[Nullable[str]]
|
|
31
|
+
r"""The name of the underlying asset."""
|
|
32
|
+
asset_symbol: NotRequired[Nullable[str]]
|
|
33
|
+
r"""The symbol of the underlying asset (e.g., 'USDC')."""
|
|
34
|
+
tvl_usd: NotRequired[Nullable[str]]
|
|
35
|
+
r"""Total Value Locked in USD."""
|
|
36
|
+
apy_7d: NotRequired[Nullable[str]]
|
|
37
|
+
r"""7-day APY as a percentage (e.g., 5.25 = 5.25%)."""
|
|
38
|
+
apy_30d: NotRequired[Nullable[str]]
|
|
39
|
+
r"""30-day APY as a percentage."""
|
|
40
|
+
apy_90d: NotRequired[Nullable[str]]
|
|
41
|
+
r"""90-day APY as a percentage."""
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
class VaultInfo(BaseModel):
|
|
45
|
+
r"""Information about a single ERC-4626 vault from the database."""
|
|
46
|
+
|
|
47
|
+
vault_address: str
|
|
48
|
+
r"""The vault contract address."""
|
|
49
|
+
|
|
50
|
+
chain: str
|
|
51
|
+
r"""Blockchain name (e.g., 'ethereum', 'base')."""
|
|
52
|
+
|
|
53
|
+
owner: str
|
|
54
|
+
r"""The vault owner address."""
|
|
55
|
+
|
|
56
|
+
asset: str
|
|
57
|
+
r"""The underlying asset contract address."""
|
|
58
|
+
|
|
59
|
+
name: OptionalNullable[str] = UNSET
|
|
60
|
+
r"""The name of the vault."""
|
|
61
|
+
|
|
62
|
+
symbol: OptionalNullable[str] = UNSET
|
|
63
|
+
r"""The vault share token symbol."""
|
|
64
|
+
|
|
65
|
+
asset_name: OptionalNullable[str] = UNSET
|
|
66
|
+
r"""The name of the underlying asset."""
|
|
67
|
+
|
|
68
|
+
asset_symbol: OptionalNullable[str] = UNSET
|
|
69
|
+
r"""The symbol of the underlying asset (e.g., 'USDC')."""
|
|
70
|
+
|
|
71
|
+
tvl_usd: OptionalNullable[str] = UNSET
|
|
72
|
+
r"""Total Value Locked in USD."""
|
|
73
|
+
|
|
74
|
+
apy_7d: OptionalNullable[str] = UNSET
|
|
75
|
+
r"""7-day APY as a percentage (e.g., 5.25 = 5.25%)."""
|
|
76
|
+
|
|
77
|
+
apy_30d: OptionalNullable[str] = UNSET
|
|
78
|
+
r"""30-day APY as a percentage."""
|
|
79
|
+
|
|
80
|
+
apy_90d: OptionalNullable[str] = UNSET
|
|
81
|
+
r"""90-day APY as a percentage."""
|
|
82
|
+
|
|
83
|
+
@model_serializer(mode="wrap")
|
|
84
|
+
def serialize_model(self, handler):
|
|
85
|
+
optional_fields = [
|
|
86
|
+
"name",
|
|
87
|
+
"symbol",
|
|
88
|
+
"asset_name",
|
|
89
|
+
"asset_symbol",
|
|
90
|
+
"tvl_usd",
|
|
91
|
+
"apy_7d",
|
|
92
|
+
"apy_30d",
|
|
93
|
+
"apy_90d",
|
|
94
|
+
]
|
|
95
|
+
nullable_fields = [
|
|
96
|
+
"name",
|
|
97
|
+
"symbol",
|
|
98
|
+
"asset_name",
|
|
99
|
+
"asset_symbol",
|
|
100
|
+
"tvl_usd",
|
|
101
|
+
"apy_7d",
|
|
102
|
+
"apy_30d",
|
|
103
|
+
"apy_90d",
|
|
104
|
+
]
|
|
105
|
+
null_default_fields = []
|
|
106
|
+
|
|
107
|
+
serialized = handler(self)
|
|
108
|
+
|
|
109
|
+
m = {}
|
|
110
|
+
|
|
111
|
+
for n, f in type(self).model_fields.items():
|
|
112
|
+
k = f.alias or n
|
|
113
|
+
val = serialized.get(k)
|
|
114
|
+
serialized.pop(k, None)
|
|
115
|
+
|
|
116
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
117
|
+
is_set = (
|
|
118
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
119
|
+
or k in null_default_fields
|
|
120
|
+
) # pylint: disable=no-member
|
|
121
|
+
|
|
122
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
123
|
+
m[k] = val
|
|
124
|
+
elif val != UNSET_SENTINEL and (
|
|
125
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
126
|
+
):
|
|
127
|
+
m[k] = val
|
|
128
|
+
|
|
129
|
+
return m
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .vaultinfo import VaultInfo, VaultInfoTypedDict
|
|
5
|
+
from compass_api_sdk.types import BaseModel
|
|
6
|
+
from typing import List
|
|
7
|
+
from typing_extensions import TypedDict
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class VaultsResponseTypedDict(TypedDict):
|
|
11
|
+
r"""Response model for a paginated list of ERC-4626 vaults."""
|
|
12
|
+
|
|
13
|
+
total: int
|
|
14
|
+
offset: int
|
|
15
|
+
limit: int
|
|
16
|
+
vaults: List[VaultInfoTypedDict]
|
|
17
|
+
r"""A list of vault information objects."""
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
class VaultsResponse(BaseModel):
|
|
21
|
+
r"""Response model for a paginated list of ERC-4626 vaults."""
|
|
22
|
+
|
|
23
|
+
total: int
|
|
24
|
+
|
|
25
|
+
offset: int
|
|
26
|
+
|
|
27
|
+
limit: int
|
|
28
|
+
|
|
29
|
+
vaults: List[VaultInfo]
|
|
30
|
+
r"""A list of vault information objects."""
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from compass_api_sdk.types import BaseModel
|
|
5
|
+
from compass_api_sdk.utils import validate_const
|
|
6
|
+
import pydantic
|
|
7
|
+
from pydantic.functional_validators import AfterValidator
|
|
8
|
+
from typing import Literal
|
|
9
|
+
from typing_extensions import Annotated, TypedDict
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class VaultVenueTypedDict(TypedDict):
|
|
13
|
+
vault_address: str
|
|
14
|
+
r"""The vault address you are interacting with for this action."""
|
|
15
|
+
type: Literal["VAULT"]
|
|
16
|
+
r"""The venue type discriminator."""
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class VaultVenue(BaseModel):
|
|
20
|
+
vault_address: str
|
|
21
|
+
r"""The vault address you are interacting with for this action."""
|
|
22
|
+
|
|
23
|
+
TYPE: Annotated[
|
|
24
|
+
Annotated[Literal["VAULT"], AfterValidator(validate_const("VAULT"))],
|
|
25
|
+
pydantic.Field(alias="type"),
|
|
26
|
+
] = "VAULT"
|
|
27
|
+
r"""The venue type discriminator."""
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from compass_api_sdk.types import (
|
|
5
|
+
BaseModel,
|
|
6
|
+
Nullable,
|
|
7
|
+
OptionalNullable,
|
|
8
|
+
UNSET,
|
|
9
|
+
UNSET_SENTINEL,
|
|
10
|
+
)
|
|
11
|
+
from compass_api_sdk.utils import validate_const
|
|
12
|
+
import pydantic
|
|
13
|
+
from pydantic import model_serializer
|
|
14
|
+
from pydantic.functional_validators import AfterValidator
|
|
15
|
+
from typing import Any, Literal, Optional
|
|
16
|
+
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class VaultWithdrawParamsTypedDict(TypedDict):
|
|
20
|
+
vault_address: str
|
|
21
|
+
r"""The vault address you are withdrawing from."""
|
|
22
|
+
amount: Any
|
|
23
|
+
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
24
|
+
action_type: Literal["VAULT_WITHDRAW"]
|
|
25
|
+
receiver: NotRequired[Nullable[str]]
|
|
26
|
+
r"""The address which will receive the tokens withdrawn. Defaults to the sender."""
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class VaultWithdrawParams(BaseModel):
|
|
30
|
+
vault_address: str
|
|
31
|
+
r"""The vault address you are withdrawing from."""
|
|
32
|
+
|
|
33
|
+
amount: Any
|
|
34
|
+
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
35
|
+
|
|
36
|
+
ACTION_TYPE: Annotated[
|
|
37
|
+
Annotated[
|
|
38
|
+
Optional[Literal["VAULT_WITHDRAW"]],
|
|
39
|
+
AfterValidator(validate_const("VAULT_WITHDRAW")),
|
|
40
|
+
],
|
|
41
|
+
pydantic.Field(alias="action_type"),
|
|
42
|
+
] = "VAULT_WITHDRAW"
|
|
43
|
+
|
|
44
|
+
receiver: OptionalNullable[str] = UNSET
|
|
45
|
+
r"""The address which will receive the tokens withdrawn. Defaults to the sender."""
|
|
46
|
+
|
|
47
|
+
@model_serializer(mode="wrap")
|
|
48
|
+
def serialize_model(self, handler):
|
|
49
|
+
optional_fields = ["action_type", "receiver"]
|
|
50
|
+
nullable_fields = ["receiver"]
|
|
51
|
+
null_default_fields = []
|
|
52
|
+
|
|
53
|
+
serialized = handler(self)
|
|
54
|
+
|
|
55
|
+
m = {}
|
|
56
|
+
|
|
57
|
+
for n, f in type(self).model_fields.items():
|
|
58
|
+
k = f.alias or n
|
|
59
|
+
val = serialized.get(k)
|
|
60
|
+
serialized.pop(k, None)
|
|
61
|
+
|
|
62
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
63
|
+
is_set = (
|
|
64
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
65
|
+
or k in null_default_fields
|
|
66
|
+
) # pylint: disable=no-member
|
|
67
|
+
|
|
68
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
69
|
+
m[k] = val
|
|
70
|
+
elif val != UNSET_SENTINEL and (
|
|
71
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
72
|
+
):
|
|
73
|
+
m[k] = val
|
|
74
|
+
|
|
75
|
+
return m
|
|
@@ -1,7 +1,6 @@
|
|
|
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 (
|
|
6
5
|
BaseModel,
|
|
7
6
|
Nullable,
|
|
@@ -10,6 +9,7 @@ from compass_api_sdk.types import (
|
|
|
10
9
|
UNSET_SENTINEL,
|
|
11
10
|
)
|
|
12
11
|
from compass_api_sdk.utils import validate_const
|
|
12
|
+
from enum import Enum
|
|
13
13
|
import pydantic
|
|
14
14
|
from pydantic import model_serializer
|
|
15
15
|
from pydantic.functional_validators import AfterValidator
|
|
@@ -17,18 +17,25 @@ from typing import Any, Literal, Optional
|
|
|
17
17
|
from typing_extensions import Annotated, NotRequired, TypedDict
|
|
18
18
|
|
|
19
19
|
|
|
20
|
+
class VaultWithdrawRequestChain(str, Enum):
|
|
21
|
+
ARBITRUM = "arbitrum"
|
|
22
|
+
BASE = "base"
|
|
23
|
+
ETHEREUM = "ethereum"
|
|
24
|
+
|
|
25
|
+
|
|
20
26
|
class VaultWithdrawRequestTypedDict(TypedDict):
|
|
21
27
|
vault_address: str
|
|
22
28
|
r"""The vault address you are withdrawing from."""
|
|
23
29
|
amount: Any
|
|
24
30
|
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
25
|
-
chain:
|
|
26
|
-
r"""The chain to use."""
|
|
31
|
+
chain: VaultWithdrawRequestChain
|
|
27
32
|
sender: str
|
|
28
33
|
r"""The address of the transaction sender."""
|
|
29
34
|
action_type: Literal["VAULT_WITHDRAW"]
|
|
30
35
|
receiver: NotRequired[Nullable[str]]
|
|
31
36
|
r"""The address which will receive the tokens withdrawn. Defaults to the sender."""
|
|
37
|
+
estimate_gas: NotRequired[bool]
|
|
38
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
32
39
|
|
|
33
40
|
|
|
34
41
|
class VaultWithdrawRequest(BaseModel):
|
|
@@ -38,8 +45,7 @@ class VaultWithdrawRequest(BaseModel):
|
|
|
38
45
|
amount: Any
|
|
39
46
|
r"""The amount of tokens to withdraw from the vault. If set to 'ALL', your total deposited token amount will be withdrawn."""
|
|
40
47
|
|
|
41
|
-
chain:
|
|
42
|
-
r"""The chain to use."""
|
|
48
|
+
chain: VaultWithdrawRequestChain
|
|
43
49
|
|
|
44
50
|
sender: str
|
|
45
51
|
r"""The address of the transaction sender."""
|
|
@@ -55,9 +61,12 @@ class VaultWithdrawRequest(BaseModel):
|
|
|
55
61
|
receiver: OptionalNullable[str] = UNSET
|
|
56
62
|
r"""The address which will receive the tokens withdrawn. Defaults to the sender."""
|
|
57
63
|
|
|
64
|
+
estimate_gas: Optional[bool] = None
|
|
65
|
+
r"""Determines whether to estimate gas costs for transactions, also verifying that the transaction can be successfully executed."""
|
|
66
|
+
|
|
58
67
|
@model_serializer(mode="wrap")
|
|
59
68
|
def serialize_model(self, handler):
|
|
60
|
-
optional_fields = ["action_type", "receiver"]
|
|
69
|
+
optional_fields = ["action_type", "receiver", "estimate_gas"]
|
|
61
70
|
nullable_fields = ["receiver"]
|
|
62
71
|
null_default_fields = []
|
|
63
72
|
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .compass_api_backend_v1_models_wildcat_read_response_market_userposition import (
|
|
5
|
+
CompassAPIBackendV1ModelsWildcatReadResponseMarketUserPosition,
|
|
6
|
+
CompassAPIBackendV1ModelsWildcatReadResponseMarketUserPositionTypedDict,
|
|
7
|
+
)
|
|
8
|
+
from .underlyingtoken import UnderlyingToken, UnderlyingTokenTypedDict
|
|
9
|
+
from compass_api_sdk.types import (
|
|
10
|
+
BaseModel,
|
|
11
|
+
Nullable,
|
|
12
|
+
OptionalNullable,
|
|
13
|
+
UNSET,
|
|
14
|
+
UNSET_SENTINEL,
|
|
15
|
+
)
|
|
16
|
+
from pydantic import model_serializer
|
|
17
|
+
from typing_extensions import NotRequired, TypedDict
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
class WildcatGetMarketResponseTypedDict(TypedDict):
|
|
21
|
+
market_address: str
|
|
22
|
+
r"""The address of the market."""
|
|
23
|
+
name: str
|
|
24
|
+
r"""Name of the vault."""
|
|
25
|
+
symbol: str
|
|
26
|
+
r"""Symbol of the vault."""
|
|
27
|
+
decimals: int
|
|
28
|
+
r"""Number of decimals used for the vault's share precision."""
|
|
29
|
+
available_to_lend: str
|
|
30
|
+
r"""The borrower's remaining available credit."""
|
|
31
|
+
loaned: str
|
|
32
|
+
r"""The total value of all funds supplied by lenders, including interest."""
|
|
33
|
+
max_borrowing_capacity: str
|
|
34
|
+
r"""The maximum limit of funds that borrowers can access in the market."""
|
|
35
|
+
gross_interest_accrued: str
|
|
36
|
+
r"""The total gross interest generated by the loan before being split between lenders, reserves, and protocol fees."""
|
|
37
|
+
minimum_deposit: str
|
|
38
|
+
r"""The minimum amount of underlying asset required for a single deposit transaction."""
|
|
39
|
+
minimum_reserve_ratio: str
|
|
40
|
+
r"""A required percentage of market funds that must remain liquid and unavailable for borrowing."""
|
|
41
|
+
base_lender_apr: str
|
|
42
|
+
r"""The fixed annual percentage rate (excluding any protocol fees) that borrowers pay to lenders for assets within the market."""
|
|
43
|
+
protocol_fee_apr: str
|
|
44
|
+
r"""An additional APR that accrues to the protocol by slowly increasing required reserves. Derived by the fee configuration of the protocol as a percentage of the current base APR."""
|
|
45
|
+
effective_lender_apr: str
|
|
46
|
+
r"""The current interest rate being paid to lenders: the base APR plus penalty APR if applicable."""
|
|
47
|
+
penalty_apr: str
|
|
48
|
+
r"""An additional interest rate charged if the market remains delinquent—failing to maintain required reserves—after the grace period has elapsed."""
|
|
49
|
+
maximum_grace_period: int
|
|
50
|
+
r"""The number of seconds borrowers have to resolve reserve deficiencies or correct delinquency in the market before penalties take effect."""
|
|
51
|
+
available_grace_period: int
|
|
52
|
+
r"""The portion of the grace period left for borrowers to fix non-compliance issues, such as restoring reserves."""
|
|
53
|
+
withdrawal_cycle_duration: int
|
|
54
|
+
r"""The number of seconds for which withdrawal requests are grouped and processed."""
|
|
55
|
+
underlying_token: UnderlyingTokenTypedDict
|
|
56
|
+
user_position: NotRequired[
|
|
57
|
+
Nullable[
|
|
58
|
+
CompassAPIBackendV1ModelsWildcatReadResponseMarketUserPositionTypedDict
|
|
59
|
+
]
|
|
60
|
+
]
|
|
61
|
+
r"""The user's position in the vault."""
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
class WildcatGetMarketResponse(BaseModel):
|
|
65
|
+
market_address: str
|
|
66
|
+
r"""The address of the market."""
|
|
67
|
+
|
|
68
|
+
name: str
|
|
69
|
+
r"""Name of the vault."""
|
|
70
|
+
|
|
71
|
+
symbol: str
|
|
72
|
+
r"""Symbol of the vault."""
|
|
73
|
+
|
|
74
|
+
decimals: int
|
|
75
|
+
r"""Number of decimals used for the vault's share precision."""
|
|
76
|
+
|
|
77
|
+
available_to_lend: str
|
|
78
|
+
r"""The borrower's remaining available credit."""
|
|
79
|
+
|
|
80
|
+
loaned: str
|
|
81
|
+
r"""The total value of all funds supplied by lenders, including interest."""
|
|
82
|
+
|
|
83
|
+
max_borrowing_capacity: str
|
|
84
|
+
r"""The maximum limit of funds that borrowers can access in the market."""
|
|
85
|
+
|
|
86
|
+
gross_interest_accrued: str
|
|
87
|
+
r"""The total gross interest generated by the loan before being split between lenders, reserves, and protocol fees."""
|
|
88
|
+
|
|
89
|
+
minimum_deposit: str
|
|
90
|
+
r"""The minimum amount of underlying asset required for a single deposit transaction."""
|
|
91
|
+
|
|
92
|
+
minimum_reserve_ratio: str
|
|
93
|
+
r"""A required percentage of market funds that must remain liquid and unavailable for borrowing."""
|
|
94
|
+
|
|
95
|
+
base_lender_apr: str
|
|
96
|
+
r"""The fixed annual percentage rate (excluding any protocol fees) that borrowers pay to lenders for assets within the market."""
|
|
97
|
+
|
|
98
|
+
protocol_fee_apr: str
|
|
99
|
+
r"""An additional APR that accrues to the protocol by slowly increasing required reserves. Derived by the fee configuration of the protocol as a percentage of the current base APR."""
|
|
100
|
+
|
|
101
|
+
effective_lender_apr: str
|
|
102
|
+
r"""The current interest rate being paid to lenders: the base APR plus penalty APR if applicable."""
|
|
103
|
+
|
|
104
|
+
penalty_apr: str
|
|
105
|
+
r"""An additional interest rate charged if the market remains delinquent—failing to maintain required reserves—after the grace period has elapsed."""
|
|
106
|
+
|
|
107
|
+
maximum_grace_period: int
|
|
108
|
+
r"""The number of seconds borrowers have to resolve reserve deficiencies or correct delinquency in the market before penalties take effect."""
|
|
109
|
+
|
|
110
|
+
available_grace_period: int
|
|
111
|
+
r"""The portion of the grace period left for borrowers to fix non-compliance issues, such as restoring reserves."""
|
|
112
|
+
|
|
113
|
+
withdrawal_cycle_duration: int
|
|
114
|
+
r"""The number of seconds for which withdrawal requests are grouped and processed."""
|
|
115
|
+
|
|
116
|
+
underlying_token: UnderlyingToken
|
|
117
|
+
|
|
118
|
+
user_position: OptionalNullable[
|
|
119
|
+
CompassAPIBackendV1ModelsWildcatReadResponseMarketUserPosition
|
|
120
|
+
] = UNSET
|
|
121
|
+
r"""The user's position in the vault."""
|
|
122
|
+
|
|
123
|
+
@model_serializer(mode="wrap")
|
|
124
|
+
def serialize_model(self, handler):
|
|
125
|
+
optional_fields = ["user_position"]
|
|
126
|
+
nullable_fields = ["user_position"]
|
|
127
|
+
null_default_fields = []
|
|
128
|
+
|
|
129
|
+
serialized = handler(self)
|
|
130
|
+
|
|
131
|
+
m = {}
|
|
132
|
+
|
|
133
|
+
for n, f in type(self).model_fields.items():
|
|
134
|
+
k = f.alias or n
|
|
135
|
+
val = serialized.get(k)
|
|
136
|
+
serialized.pop(k, None)
|
|
137
|
+
|
|
138
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
139
|
+
is_set = (
|
|
140
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
141
|
+
or k in null_default_fields
|
|
142
|
+
) # pylint: disable=no-member
|
|
143
|
+
|
|
144
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
145
|
+
m[k] = val
|
|
146
|
+
elif val != UNSET_SENTINEL and (
|
|
147
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
148
|
+
):
|
|
149
|
+
m[k] = val
|
|
150
|
+
|
|
151
|
+
return m
|
|
@@ -7,7 +7,7 @@ import pydantic
|
|
|
7
7
|
from typing_extensions import Annotated, TypedDict
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
class
|
|
10
|
+
class WithdrawTypedDict(TypedDict):
|
|
11
11
|
id: str
|
|
12
12
|
r"""The id of a historical transaction on aave"""
|
|
13
13
|
timestamp: int
|
|
@@ -24,7 +24,7 @@ class RedeemUnderlyingTypedDict(TypedDict):
|
|
|
24
24
|
block: int
|
|
25
25
|
|
|
26
26
|
|
|
27
|
-
class
|
|
27
|
+
class Withdraw(BaseModel):
|
|
28
28
|
id: str
|
|
29
29
|
r"""The id of a historical transaction on aave"""
|
|
30
30
|
|