2 个稳定版本
1.0.1 | 2024 年 4 月 17 日 |
---|---|
1.0.0 | 2024 年 1 月 26 日 |
#2052 在 魔法豆
525KB
9K SLoC
moonsdk 的 Rust API 客户端
未提供描述(由 Openapi Generator 生成 https://github.com/openapitools/openapi-generator)
概览
此 API 客户端是由 OpenAPI Generator 项目生成的。通过使用来自远程服务器的 openapi-spec,您可以轻松地生成 API 客户端。
- API 版本:1.0.0
- 包版本:1.0.0
- 构建包:
org.openapitools.codegen.languages.RustClientCodegen
安装
将包放置在项目文件夹中名为 moonsdk
的目录下,并在 Cargo.toml
下的 [dependencies]
中添加以下内容:
moonsdk = { path = "./moonsdk" }
API 端点文档
所有 URI 都相对于 https://beta.usemoon.ai
类 | 方法 | HTTP 请求 | 描述 |
---|---|---|---|
AaveApi | borrow | POST /aave/{name}/borrow | |
AaveApi | lend | POST /aave/{name}/lend | |
AaveApi | repay | POST /aave/{name}/repay | |
AaveApi | user_reserve_data | POST /aave/{name}/user-reserve-data | |
AccountsApi | broadcast_tx | POST /accounts/{accountName}/broadcast-tx | |
AccountsApi | create_account | POST /accounts | |
AccountsApi | delete_account | DELETE /accounts/{accountName} | |
AccountsApi | deploy_contract | POST /accounts/{accountName}/deploy | |
AccountsApi | get_account | GET /accounts/{accountName} | |
AccountsApi | get_balance | GET /accounts/{accountName}/balance | |
AccountsApi | get_nonce | GET /accounts/{accountName}/nonce | |
AccountsApi | list_accounts | GET /accounts | |
AccountsApi | sign_message | POST /accounts/{accountName}/sign-message | |
AccountsApi | sign_transaction | POST /accounts/{accountName}/sign-transaction | |
AccountsApi | sign_typed_data | POST /accounts/{accountName}/sign-typed-data | |
AccountsApi | transfer_eth | POST /accounts/{accountName}/transfer-eth | |
BitcoinApi | create_bitcoin_account | POST /bitcoin | |
BitcoinApi | get_bitcoin_account | GET /bitcoin/{accountName} | |
BitcoinApi | list_bitcoin_accounts | GET /bitcoin | |
BitcoinApi | sign_bitcoin_transaction | POST /bitcoin/{accountName}/sign-tx | |
BitcoincashApi | create_bitcoin_cash_account | POST /bitcoincash | |
BitcoincashApi | get_bitcoin_cash_account | GET /bitcoincash/{accountName} | |
BitcoincashApi | list_bitcoin_cash_accounts | GET /bitcoincash | |
BitcoincashApi | sign_bitcoin_cash_transaction | POST /bitcoincash/{accountName}/sign-tx | |
ConveyorFinanceApi | swap | POST /conveyorfinance/{name}/swap | |
CosmosApi | create_cosmos_account | POST /cosmos | |
CosmosApi | get_cosmos_account | GET /cosmos/{accountName} | |
CosmosApi | list_cosmos_accounts | GET /cosmos | |
CosmosApi | sign_cosmos_transaction | POST /cosmos/{accountName}/sign-tx | |
DefaultApi | get_message | GET /ping | |
DogeCoinApi | create_doge_coin_account | POST /dogecoin | |
DogeCoinApi | get_doge_coin_account | GET /dogecoin/{accountName} | |
DogeCoinApi | list_doge_coin_accounts | GET /dogecoin | |
DogeCoinApi | sign_doge_coin_transaction | POST /dogecoin/{accountName}/sign-tx | |
EnsApi | resolve | POST /ens/resolve | |
Erc1155Api | balance_of | POST /erc1155/{name}/balance-of | |
Erc1155Api | balance_of_batch | POST /erc1155/{name}/balance-of-batch | |
Erc1155Api | is_approved_for_all | POST /erc1155/{name}/is-approved-for-all | |
Erc1155Api | safe_batch_transfer_from | POST /erc1155/{name}/safe-batch-transfer-from | |
Erc1155Api | safe_transfer_from | POST /erc1155/{name}/safe-transfer-from | |
Erc1155Api | set_approval_for_all | POST /erc1155/{name}/set-approval-for-all | |
EosApi | create_eos_account | POST /eos | |
EosApi | get_eos_account | GET /eos/{accountName} | |
EosApi | list_eos_accounts | GET /eos | |
EosApi | sign_eos_transaction | POST /eos/{accountName}/sign-tx | |
Erc20Api | allowance_erc20 | POST /erc20/{name}/allowance | |
Erc20Api | approve_erc20 | POST /erc20/{name}/approve | |
Erc20Api | balance_of_erc20 | POST /erc20/{name}/balance-of | |
Erc20Api | decimals_erc20 | POST /erc20/{name}/decimals | |
Erc20Api | name_erc20 | POST /erc20/{name}/name | |
Erc20Api | symbol_erc20 | POST /erc20/{name}/symbol | |
Erc20Api | total_supply_erc20 | POST /erc20/{name}/total-supply | |
Erc20Api | transfer_erc20 | POST /erc20/{name}/transfer | |
Erc20Api | transfer_from_erc20 | POST /erc20/{name}/transfer-from | |
Erc721Api | approve | POST /erc721/{name}/approve | |
Erc721Api | balance_of | POST /erc721/{name}/balance-of | |
Erc721Api | get_approved | POST /erc721/{name}/get-approved | |
Erc721Api | is_approved_for_all | POST /erc721/{name}/is-approved-for-all | |
Erc721Api | name | POST /erc721/{name}/name | |
Erc721Api | owner_of | POST /erc721/{name}/owner-of | |
Erc721Api | safe_transfer_from | POST /erc721/{name}/safe-transfer-from | |
Erc721Api | set_approval_for_all | POST /erc721/{name}/set-approval-for-all | |
Erc721Api | symbol | POST /erc721/{name}/symbol | |
Erc721Api | token_uri | POST /erc721/{name}/token-uri | |
Erc721Api | transfer | POST /erc721/{name}/transfer | |
Erc721Api | transfer_from | POST /erc721/{name}/transfer-from | |
LitecoinApi | create_litecoin_account | POST /litecoin | |
LitecoinApi | get_litecoin_account | GET /litecoin/{accountName} | |
LitecoinApi | list_litecoin_accounts | GET /litecoin | |
LitecoinApi | sign_litecoin_transaction | POST /litecoin/{accountName}/sign-tx | |
OneinchApi | approve_call_data | POST /oneinch/approve-call-data | |
OneinchApi | approve_spender | POST /oneinch/approve-spender | |
OneinchApi | protocols | POST /oneinch/protocols | |
OneinchApi | quote | POST /oneinch/quote | |
OneinchApi | swap | POST /oneinch/{accountName}/swap | |
OneinchApi | tokens | POST /oneinch/tokens | |
OnramperApi | on_ramper_checkout | POST /onramper/fund/${accountName} | |
OnramperApi | on_ramper_get_quotes_buy | GET /onramper/quotes/buy | |
OnramperApi | on_ramper_get_quotes_sell | GET /onramper/quotes/sell | |
OnramperApi | on_ramper_get_supported_assets | GET /onramper/assets | |
OnramperApi | on_ramper_get_supported_currencies | GET /onramper/currencies | |
OnramperApi | on_ramper_get_supported_defaults_all | GET /onramper/defaults | |
OnramperApi | on_ramper_get_supported_on_ramps_all | GET /onramper/onramps | |
OnramperApi | on_ramper_get_supported_payment_types | GET /onramper/payment-types | |
OnramperApi | on_ramper_get_supported_payment_types_fiat | GET /onramper/payment-types/fiat | |
RippleApi | create_ripple_account | POST /ripple | |
RippleApi | get_ripple_account | GET /ripple/{accountName} | |
RippleApi | list_ripple_accounts | GET /ripple | |
RippleApi | sign_ripple_transaction | POST /ripple/{accountName}/sign-tx | |
SolanaApi | create_solana_account | POST /solana | |
SolanaApi | get_solana_account | GET /solana/{accountName} | |
SolanaApi | list_solana_accounts | GET /solana | |
SolanaApi | sign_solana_transaction | POST /solana/{accountName}/sign-tx | |
TronApi | create_tron_account | POST /tron | |
TronApi | get_tron_account | GET /tron/{accountName} | |
TronApi | list_tron_accounts | GET /tron | |
TronApi | sign_tron_transaction | POST /tron/{accountName}/sign-tx | |
UniSwapApi | add_liquidity | POST /uniswap/{name}/add-liquidity | |
UniSwapApi | remove_liquidity | POST /uniswap/{name}/remove-liquidity | |
UniSwapApi | swap_exact_eth_for_tokens | POST /uniswap/{name}/swap-exact-eth-for-tokens | |
UniSwapApi | swap_exact_tokens_for_tokens | POST /uniswap/{name}/swap-exact-tokens-for-tokens | |
YearnApi | add_liquidity | POST /yearn/{name}/add-liquidity | |
YearnApi | add_liquidity_weth | POST /yearn/{name}/add-liquidity-weth | |
YearnApi | remove_liquidity | POST /yearn/{name}/remove-liquidity | |
YearnApi | remove_liquidity_weth | POST /yearn/{name}/remove-liquidity-weth |
模型文档
- AaveInput
- AaveReservesApiResponse
- AaveReservesData
- AccountApiResponse
- AccountData
- AccountResponse
- AvailablePaymentMethod
- BalanceApiResponse
- BalanceResponse
- BitcoinApiResponse
- BitcoinCashApiResponse
- BitcoinCashInput
- BitcoinCashTransactionInput
- BitcoinCashTransactionOutput
- BitcoinInput
- BitcoinTransactionInput
- BitcoinTransactionOutput
- BroadCastRawTransactionApiResponse
- BroadCastRawTransactionResponse
- BroadcastInput
- ConveyorFinanceControllerResponse
- CosmosApiResponse
- CosmosInput
- CosmosTransactionInput
- CosmosTransactionOutput
- CreateAccountInput
- CryptoCurrency
- DeployInput
- DogeCoinApiResponse
- DogeCoinInput
- DogeCoinTransactionInput
- DogeCoinTransactionOutput
- EnsResolveApiResponse
- EnsResolveInput
- EnsResolveResponse
- EosApiResponse
- EosInput
- EosTransactionInput
- EosTransactionOutput
- Erc1155Request
- Erc721Request
- FiatCurrency
- GetSupportedOnRampsResponse
- GetSupportedOnRampsResponseMessageInner
- GetSupportedOnRampsResponseMessageInnerIcons
- GetSupportedOnRampsResponseMessageInnerIconsPng
- GetSwapDto
- InputBody
- LitecoinApiResponse
- LitecoinInput
- LitecoinTransactionInput
- LitecoinTransactionOutput
- Message
- NonceApiResponse
- NonceResponse
- PaymentType
- PingResponse
- Quote
- RippleApiResponse
- RippleInput
- RippleTransactionInput
- RippleTransactionOutput
- SellQuote
- SignMessage
- SignMessageApiResponse
- SignTypedData
- SolanaApiResponse
- SolanaInput
- SolanaTransactionInput
- SolanaTransactionOutput
- SupportedAssetResponse
- SupportedAssetResponseAssetsInner
- SupportedCurrenciesResponse
- SupportedDefaultResponse
- SupportedDefaultResponseDefaults
- SupportedDefaultResponseDefaultsId
- SupportedPaymentTypesCurrencyResponse
- SupportedPaymentTypesMessage
- TokenSwapParams
- Transaction
- TransactionApiResponse
- TransactionData
- TransactionInput
- TransactionInputMetaData
- TransactionInputSupportedParams
- TransactionInputSupportedParamsPartnerData
- TransactionInputSupportedParamsPartnerDataRedirectUrl
- TransactionInputSupportedParamsTheme
- TransactionInputWallet
- TransactionRequest
- TransactionResponse
- TransactionResponseInfo
- TransactionResponseTx
- TronApiResponse
- TronInput
- Tron 交易输入
- Tron 交易输出
- Tx
- Uniswap 输入
要获取该模块生成的文档,请使用
cargo doc --open
作者
依赖项
~4–16MB
~247K SLoC