πChainlink CCIP Integration
Overview
Our project utilizes Chainlink's Cross-Chain Interoperability Protocol (CCIP) to enable seamless transfer of USDC funds between different blockchain networks. The HyperHarvest contract serves as both a vault and a gateway for receiving CCIP messages and funds.
Key Features
Cross-Chain Fund Transfer: Ability to move USDC funds between different blockchain networks.
Integrated Vault Functionality: HyperHarvest contract acts as a vault for storing user funds.
CCIP Message Handling: Built-in capability to process incoming CCIP messages and funds.
Technical Implementation
CCIP Router Integration
The contract inherits from CCIPReceiver, which provides the necessary functionality to interact with the CCIP router:
contract HyperHarvest is ERC4626, CCIPReceiver, ReentrancyGuard {
// ...
}
Cross-Chain Asset Transfer
The bridgeAndSupplyAssetToAave function prepares and sends CCIP messages to transfer assets:
function bridgeAndSupplyAssetToAave(
address _receiver,
uint256 _gasFeeAmount,
uint64 _destinationChainSelector
) public onlyAllowed(msg.sender) returns (bytes32 messageId) {
// ... (Function implementation)
}
CCIP Message Reception
The _ccipReceive function handles incoming CCIP messages:
function _ccipReceive(
Client.Any2EVMMessage memory message
) internal override nonReentrant {
// ... (Function implementation)
}
Benefits
Interoperability: Enables seamless movement of funds across different blockchain networks.
Enhanced Yield Opportunities: Allows users to access yield opportunities on multiple chains.
Automated Cross-Chain Operations: Facilitates automated fund transfers and yield farming across chains.
Last updated