Cross-Chain USDC Supply to AAVE with Gasless Fusion Orchestration
This guide demonstrates how to use Across Protocol together with Biconomy’s Modular Execution Environment (MEE) to perform a cross-chain supply of USDC into AAVE, completely gasless using Fusion Orchestration. With Biconomy, you can leverage runtime value injection for Across as well. Bridge with no dust left!Overview
The integration showcases:- Cross-chain bridging from Optimism to Base using Across Protocol
- Automated AAVE supply on the destination chain
- Gasless execution through Fusion Orchestration
- Single signature UX for the entire flow
- Ultra-fast bridging with Across’s optimistic design
Architecture
Key Components
- Across Protocol: Ultra-fast optimistic bridge with capital-efficient design
- Biconomy MEE: Orchestrates the entire transaction flow
- Fusion Mode: Enables gasless execution with external wallets
- Companion Account: Temporary smart account for orchestration
Flow Diagram
Implementation Guide
1. Setup and Dependencies
First, make sure you are using the latestabstractjs
version. Update it via your favourite package manager.
2. Configure Token and Protocol Addresses
3. Initialize MEE Client and Orchestrator
4. Build Orchestration Instructions
Step 1: Define Trigger
The trigger initiates the orchestration by pulling tokens from the EOA. This given trigger will send inputAmount + required orchestration fees from EOA to the orchestrator account.Step 2: Build a composable Across instruction
It will bridge the full USDC balance of the orchestrator account.approximateExpectedInputAmount
this the amount that is going to be used as a benchmark to calculate the input/output bridge ratio. It is recommended that this amount is close to the runtime balance that is expected to be fetched using the params above.- For example, if you swap 1 eth to usdc prior to bridging usdc, and the eth/usdc rate at the timeof bridging is 5000, you may end up receiving from 4999 to 5001 usdc. Composable helper will allow you to bridge the exact amount, leaving no dust. In this case you should use $5000 as the
approximateExpectedInputAmount
.
- For example, if you swap 1 eth to usdc prior to bridging usdc, and the eth/usdc rate at the timeof bridging is 5000, you may end up receiving from 4999 to 5001 usdc. Composable helper will allow you to bridge the exact amount, leaving no dust. In this case you should use $5000 as the
inputAmountRuntimeParams
this is the replacement of theinputAmount
. Instead specifying the amount itself, one sets the params that define how to obtain the amount at the runtime. Those params include thetargetAddress
- the address of the account which erc20 balance is going to be used as the input amounttokenAddress
- the erc20 token. balance of this token is used as the input amountconstraints
- the array of arithmetical constraints to make sure the fetched amount will be satisfying certain conditions. More about constraints.
Step 3: Approve AAVE (with runtime balance)
Using runtime balance ensures we approve exactly what arrived:Step 4: Supply to AAVE
Step 5: Withdraw aUSDC to EOA
6. Execute Fusion Orchestration
Key Concepts
Across Optimistic Design
Across uses an optimistic architecture that:- Lightning fast: Relayers front capital for instant fills
- Capital efficient: Uses a single liquidity pool across all chains
- Secure: UMA’s optimistic oracle validates all transfers
Runtime Balance Constraints
TheruntimeERC20BalanceOf
function ensures instructions use the exact amount that arrives:
- Handles bridge fees automatically
- Ensures proper sequencing
- Avoids failed transactions
Constraints and Execution Order
Instructions execute only when their constraints are met:- AAVE approval waits for bridged funds
- AAVE supply waits for approval
- Withdrawal waits for aUSDC
Cleanup Mechanism
If any step fails, cleanup instructions ensure funds are returned:Gas Payment
The orchestration is gasless because:- Gas paid using bridged USDC
- MEE handles gas abstraction
- Users only sign once
Across Quote Service
Quote Parameters
Best Practices
- Always use runtime balances for cross-chain operations
- Include cleanup instructions for failure scenarios
- Set reasonable time bounds (60 seconds recommended)
- Test on testnets first before mainnet deployment
- Monitor transactions using MEE Scan
- Check deposit limits before bridging large amounts
- Secure your API keys in environment variables
- Validate fee amounts to ensure they’re reasonable
Advanced Features
Cross-Chain Messaging
Include messages with your bridge:Referral Tracking
Track referrals for analytics:Exclusive Relayers
Specify exclusive relayers for priority fills:Multi-Chain Cleanups
Fee Analysis
Monitoring & Analytics
Track your orchestrations:Supported Chains & Features
Across supports ultra-fast bridging across major chains:- Chains: Ethereum, Arbitrum, Optimism, Base, Polygon, and more
- Features: Optimistic filling, single liquidity pool, UMA oracle validation
- Speed: Usually completes in under 2 minutes
- Capital Efficiency: Best rates due to unified liquidity
Conclusion
This integration combines Across’s ultra-fast optimistic bridging with Biconomy MEE’s orchestration capabilities to deliver:- Lightning-fast cross-chain transfers (under 2 minutes)
- Completely gasless experience
- Single signature for complex flows
- Built-in failure protection
- Capital-efficient pricing