Files
smom-dbis-138/contracts/flash/interfaces/ICrossChainFlashBridge.sol

21 lines
915 B
Solidity
Raw Normal View History

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
/**
* @title ICrossChainFlashBridge
* @notice Minimal surface for pull `token` from msg.sender then initiate CCIP / bridge.
* @dev Wire to `UniversalCCIPFlashBridgeAdapter` ( `UniversalCCIPBridge.bridge`), a dedicated adapter, or a mock in tests.
* Implementations MUST pull from `msg.sender` (e.g. `transferFrom`) up to `amount` after allowance.
* For `UniversalCCIPFlashBridgeAdapter`, optional `extraData` encodes
* `(bytes32 assetType, bool usePMM, bool useVault, bytes complianceProof, bytes vaultInstructions)`; empty uses zeros/false.
*/
interface ICrossChainFlashBridge {
function bridgeTokensFrom(
address token,
uint256 amount,
uint64 destinationChainSelector,
address recipientOnDestination,
bytes calldata extraData
) external payable returns (bytes32 messageId);
}