Uniswap Api
uniswap_apiUniswap Trading API for executing swaps and managing liquidity across 25+ blockchain networks
Acciones disponibles (7)
Cada acción es una operación que el agente puede ejecutar contra este conector. Haz clic en una acción para ver sus parámetros.
Check Token ApprovalUNISWAP_API_CHECK_APPROVALAcciónTool to check if a wallet has sufficient token approval for a specified transaction amount. Returns an approval transaction if needed, or null if approval already exists. Use this before executing a swap to verify or obtain the necessary token approval.
UNISWAP_API_CHECK_APPROVALAcciónTool to check if a wallet has sufficient token approval for a specified transaction amount. Returns an approval transaction if needed, or null if approval already exists. Use this before executing a swap to verify or obtain the necessary token approval.
Parámetros de entrada
tokenstringObligatorioThe token which will be sent, specified by its token address.
amountstringObligatorioThe quantity of tokens denominated in the token's base units. For example, for an ERC20 token one token is 1x10^18 base units. For one USDC token one token is 1x10^6 base units.
chainIdintegerObligatorioThe unique ID of the blockchain.
urgencystringenumThe urgency impacts the estimated gas price of the transaction. The higher the urgency, the higher the gas price.
normalfasturgenttokenOutstringThe token which will be received, specified by its token address.
walletAddressstringObligatorioThe wallet address which will be used to send the token.
includeGasInfobooleanIf set to true, the response will include the estimated gas fee for the proposed transaction.
tokenOutChainIdintegerThe unique ID of the blockchain for the output token.
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Check Wallet DelegationUNISWAP_API_CHECK_WALLET_DELEGATIONAcciónGet the current delegation status and message for a smart contract wallet across different chains. Returns delegation information for each chain ID in the request, including whether the wallet is delegated, the delegate address, and delegator information. Use when checking if a smart contract wallet has delegated its swap permissions to another address or if someone has delegated to it.
UNISWAP_API_CHECK_WALLET_DELEGATIONAcciónGet the current delegation status and message for a smart contract wallet across different chains. Returns delegation information for each chain ID in the request, including whether the wallet is delegated, the delegate address, and delegator information. Use when checking if a smart contract wallet has delegated its swap permissions to another address or if someone has delegated to it.
Parámetros de entrada
chain_idsinteger[]ObligatorioArray of chain IDs to check delegation status for each wallet. Supported chain IDs include: 1 (Ethereum), 10 (Optimism), 56 (BNB Chain), 137 (Polygon), and others.
wallet_addressesstring[]ObligatorioArray of smart contract wallet addresses to check delegation status for. Each address must be a valid Ethereum-style address (0x followed by 40 hex characters).
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Encode 7702 transactionsUNISWAP_API_ENCODE7702_TRANSACTIONSAcciónEncode a list of transactions into a single transaction for smart contract wallet execution (EIP-7702). All transactions must have the same chainId. Use when you need to batch multiple transactions into a single smart contract wallet transaction for atomic execution.
UNISWAP_API_ENCODE7702_TRANSACTIONSAcciónEncode a list of transactions into a single transaction for smart contract wallet execution (EIP-7702). All transactions must have the same chainId. Use when you need to batch multiple transactions into a single smart contract wallet transaction for atomic execution.
Parámetros de entrada
callsobject[]ObligatorioArray of transaction requests to be encoded. All transactions must have the same chainId.
walletAddressstringObligatorioThe smart contract wallet address.
smartContractDelegationAddressstringObligatorioThe smart contract delegation address.
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get Gasless OrdersUNISWAP_API_GET_GASLESS_ORDERSAcciónRetrieve one or more gasless orders from Uniswap, optionally filtered by query parameters. Must include at least one of: orderId, orderIds, orderStatus, swapper, or filler. Use when you need to check the status or details of Uniswap gasless orders (UniswapX orders).
UNISWAP_API_GET_GASLESS_ORDERSAcciónRetrieve one or more gasless orders from Uniswap, optionally filtered by query parameters. Must include at least one of: orderId, orderIds, orderStatus, swapper, or filler. Use when you need to check the status or details of Uniswap gasless orders (UniswapX orders).
Parámetros de entrada
sortstringSort query. For example: sort=gt(UNIX_TIMESTAMP), sort=between(1675872827, 1675872930), or lt(1675872930).
limitintegerMaximum number of orders to return.
cursorstringCursor for pagination.
fillerstringFilter by filler address (address of the filler who executed the order).
swapperstringFilter by swapper address (wallet address of the user who initiated the swap).
order_idstringA unique ID for the order. Used to track the order's status.
sort_keystringenumSort key for ordering results.
createdAtorder_idsstringA list of comma separated orderIds.
order_typestringenumOrder type for the request.
DutchDutch_V2Dutch_V1_V2Dutch_V3LimitPriorityorder_statusstringenumOrder status filter.
openexpirederrorcancelledfilledunverifiedinsufficient-funds
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get QuoteUNISWAP_API_GET_QUOTEAcciónRequests a quote according to the specified swap parameters. This endpoint may be used to get a quote for a swap, a bridge, or a wrap/unwrap. The resulting response includes a quote for the swap and the proposed route by which the quote was achieved, along with estimated gas fees. Use when you need to get a quote for a token swap before executing the transaction.
UNISWAP_API_GET_QUOTEAcciónRequests a quote according to the specified swap parameters. This endpoint may be used to get a quote for a swap, a bridge, or a wrap/unwrap. The resulting response includes a quote for the swap and the proposed route by which the quote was achieved, along with estimated gas fees. Use when you need to get a quote for a token swap before executing the transaction.
Parámetros de entrada
typestringenumThe handling of the amount field. EXACT_INPUT means the requester will send the specified amount of input tokens and get a quote with a variable quantity of output tokens. EXACT_OUTPUT means the requester will receive the specified amount of output tokens and get a quote with a variable quantity of input tokens.
EXACT_INPUTEXACT_OUTPUTamountstringObligatorioThe quantity of tokens denominated in the token's base units. For example, for an ERC20 token one token is 10^18 base units. For one USDC token one token is 10^6 base units. This value must be greater than 0.
swapperstringObligatorioThe wallet address which will be used to send the token.
urgencystringenumThe urgency impacts the estimated gas price.
normalfasturgenttoken_instringObligatorioThe token which will be sent, specified by its token address.
protocolsstring[]The protocols to use for the swap/order.
token_outstringObligatorioThe token which will be received, specified by its token address.
auto_slippagestringenumThe auto slippage strategy for V4 pool quotes.
DEFAULThooks_optionsstringenumHook options for V4 pool quotes.
V4_HOOKS_INCLUSIVEV4_HOOKS_ONLYV4_NO_HOOKSpermit_amountstringenumThe permit amount for Uniswap protocol swaps.
FULLEXACTintegrator_feesobject[]Optional integrator fee configuration.
token_in_chain_idintegerThe unique ID of the blockchain. For a list of supported chains see the FAQ.
routing_preferencestringenumThe routing preference for the quote.
BEST_PRICEFASTESTslippage_tolerancenumberThe slippage tolerance as a percentage up to a maximum of two decimal places.
token_out_chain_idintegerThe unique ID of the blockchain. For a list of supported chains see the FAQ.
spread_optimizationstringenumSpread optimization for UniswapX swaps.
EXECUTIONPRICEgenerate_permit_as_transactionbooleanIndicates whether you want to receive a permit2 transaction to sign and submit onchain, or a permit message to sign.
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get swappable tokensUNISWAP_API_GET_SWAPPABLE_TOKENSAcciónReturns the list of destination bridge chains for a given token on a given chain. Useful for discovering cross-chain swap/bridge options. Returns tokens that are available for swapping/bridging from the specified source token.
UNISWAP_API_GET_SWAPPABLE_TOKENSAcciónReturns the list of destination bridge chains for a given token on a given chain. Useful for discovering cross-chain swap/bridge options. Returns tokens that are available for swapping/bridging from the specified source token.
Parámetros de entrada
token_instringThe contract address of the token on the source chain (zero address for native ETH).
token_in_chain_idintegerThe unique ID of the blockchain. For a list of supported chains see the FAQ (https://api-docs.uniswap.org/guides/faqs). Default is 1 (Ethereum mainnet).
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not
Get Swap StatusUNISWAP_API_GET_SWAP_STATUSAcciónTool to retrieve the current status of swap or bridge transactions on the Uniswap trading platform. Use when you need to check if a swap transaction has been confirmed, is pending, or has failed. Provide the transaction hash(es) to get the status of one or more swap transactions.
UNISWAP_API_GET_SWAP_STATUSAcciónTool to retrieve the current status of swap or bridge transactions on the Uniswap trading platform. Use when you need to check if a swap transaction has been confirmed, is pending, or has failed. Provide the transaction hash(es) to get the status of one or more swap transactions.
Parámetros de entrada
chain_idintegerThe unique ID of the blockchain. For a list of supported chains see the [FAQ](https://api-docs.uniswap.org/guides/faqs). Defaults to 1 (Ethereum mainnet).
tx_hashesstring[]ObligatorioThe list of transaction hashes to check the swap status for.
Parámetros de salida
dataobjectObligatorioData from the action execution
errorstringError if any occurred during the execution of the action
successfulbooleanObligatorioWhether or not the action execution was successful or not