Skip to main content

How do I submit Enso transaction data from my app?

Submit any required approvals first, then send the returned tx.to, tx.data, and tx.value unchanged. Rebuild the quote if it is stale.

J
Written by Javier Diaz

To submit Enso transaction data from your app, send any required approvals first, then submit the returned tx.to, tx.data, and tx.value unchanged. Rebuild the quote if it is stale. Do not edit the calldata.

Definition

A Route or Bundle response is a simulated, signer-ready transaction. Your app is responsible for collecting a signature and broadcasting it from the user’s wallet or your existing signer. Building the quote does not submit it.

How it works

  1. Show the quote and any approval requirement.

  2. Submit required approval or preTransactions and wait for confirmation.

  3. Submit tx as-is through the wallet or signer you already use.

  4. Wait for confirmation, then refresh balances. For cross-chain routes, start bridge-status polling after the source transaction is submitted.

  5. If signing is delayed, or execution fails, request a new quote. Do not resubmit old calldata.

How Enso does this

Get Started and the FAQ say to submit the returned transaction exactly as provided. Bundle API docs tell new integrations to use preTransactions for transactions that must run before tx; a legacy approvals list is deprecated there. Respect validUntil when that field is present. Public docs do not publish a single global quote time-to-live.

FAQ

Can I change tx.to to an address from the deployments page?

No. Use the tx.to and spender from the response.

Who pays gas?

The signing account, as with any transaction your app already submits. Enso returns estimated gas in the quote when quoting is enabled.

Related articles

  • What is signer-ready transaction data?

  • How do I handle token approvals in a routing flow?

  • What if my quote expired?

  • Should I hardcode Enso contract addresses?

  • How do I show a quote before the user signs?

Sources

Did this answer your question?