Portals Logo

Documentation
Guides
Troubleshooting

Troubleshooting

The Portal endpoints test the validity of the transaction (when validate = true) and return any relevant errors back to you. If you would like to skip validation, such as when you don't intend to execute the transaction immediately, or are consuming the transaction bundle in a smart contract, set validate to false.

NOTE When validate is false, you must also provide a value for slippageTolerancePercentage. See the Portal endpoint for more details.

Some of the error types are:


execution reverted - The transaction reverted during execution. This could be due to a number of reasons, including:

  • The calculated slippage is higher than the threshold set by the slippageTolerancePercentage which would cause the transaction to revert.
    • Try increasing the slippageTolerancePercentage which is the cumulative maximum acceptable slippage for the entire transaction bundle.
  • There isn't enough liquidity to complete the swap
    • Portals is unable to find a route with sufficient liquidity to complete the swap. Try the request later or reach out to the Portals team and let us know about the issue.

execution reverted: TRANSFER_FROM_FAILED - The transaction reverted during execution due to a failed transferFrom call. This could be due to a number of reasons, including:

  • The sender has not granted approval for the portal contract (or the permit signature is invalid)
    • The sender needs to grant approval to the target to spend inputToken. Use the Approval endpoint to generate an approval transaction and check allowances.
  • The sender has an insufficient balance of inputToken (i.e. an ERC20 token).
    • The sender does not have enough tokens for the transaction. Reduce the inputAmount or double check the sender's balance with the Account endpoint.

insufficient funds for intrinsic transaction cost - The transaction reverted during execution due to insufficient funds to pay for the gas used by the transaction. This could be due to a number of reasons, including:

  • The sender does not have enough of the native token to pay for gas
    • The sender needs native tokens to pay for the gas used by the transaction. If you have used the maximum native token balance of sender (e.g. by using a MAX button on an input), ensure some is reserved to cover the gas.
  • The sender has an insufficient balance of inputToken (i.e. the native token)
    • The sender does not have enough tokens for the transaction. Reduce the inputAmount or double check the sender's balance with the Account endpoint.

Auto slippage exceeds 2.5%. Expected slippage is x%. Set slippage manually to override - Portals Auto Slippage is unable to find a route with less than 2.5% slippage.

  • Portals Auto Slippage and price impact tolerance is exceeded for this swap or zap. Set slippageTolerancePercentage manually to proceed with the transaction. Portals will still validate that the swap falls within your specified slippage tolerance, but proceed with caution!

No valid path found - Portals is unable to find a route with sufficient liquidity to complete the swap.

  • Try the request later or reach out to the Portals team and let us know about the issue.