CCIP v2.0.0 ILegacyFeeQuoter API Reference

Summary

ILegacyFeeQuoter defines a legacy-compatible interface used for:

  • ExtraArgs normalization across chain families
  • Message fee validation and quoting
  • Token-to-token conversion via USD price feeds
  • Pool return-data validation and execution payload derivation

It exists to support compatibility paths for older EVM2Any flows and pre-1.7 lanes.


Contract

chains/evm/contracts/interfaces/ILegacyFeeQuoter.sol


Import

import {ILegacyFeeQuoter} from "chainlink-ccip/chains/evm/contracts/interfaces/ILegacyFeeQuoter.sol";

Interface surface

interface ILegacyFeeQuoter {

processMessageArgs

function processMessageArgs(
  uint64 destChainSelector,
  address feeToken,
  uint256 feeTokenAmount,
  bytes calldata extraArgs,
  bytes calldata messageReceiver
)
  external
  view
  returns (
    uint256 msgFeeJuels,
    bool isOutOfOrderExecution,
    bytes memory convertedExtraArgs,
    bytes memory tokenReceiver
  );

getValidatedFee

function getValidatedFee(
  uint64 destChainSelector,
  Client.EVM2AnyMessage calldata message
)
  external
  view
  returns (uint256 feeTokenAmount);

convertTokenAmount

function convertTokenAmount(
  address fromToken,
  uint256 fromTokenAmount,
  address toToken
)
  external
  view
  returns (uint256 toTokenAmount);

getTokenAndGasPrices

function getTokenAndGasPrices(
  address token,
  uint64 destChainSelector
)
  external
  view
  returns (uint224 tokenPrice, uint224 gasPrice);

processPoolReturnData

function processPoolReturnData(
  uint64 destChainSelector,
  Internal.EVM2AnyTokenTransfer[] calldata onRampTokenTransfers,
  Client.EVMTokenAmount[] calldata sourceTokenAmounts
)
  external
  view
  returns (bytes[] memory destExecDataPerToken);

}

Integration notes / expectations

  • processMessageArgs is the primary legacy normalization entrypoint.
  • getValidatedFee performs deterministic message validation and fee calculation.
  • convertTokenAmount converts via USD-denominated pricing.
  • getTokenAndGasPrices exposes raw pricing inputs.
  • processPoolReturnData validates pool-returned data before execution planning.
  • Implementations must revert on unsupported chains, tokens, or malformed inputs.

Get the latest Chainlink content straight to your inbox.