Skip to main content

Why This Matters

Save gas and reduce user friction by combining actions. The problem: Traditional DeFi requires separate transactions for each action. Swap ETH to USDC? One transaction. Deposit USDC into a vault? Another transaction. Each requires a signature, gas payment, and confirmation wait. Users drop off at every step. What Compass enables: Bundle multiple actions into a single atomic transaction. Users sign once, and all actions execute together. UX example: User wants to Earn on USDC venue, but only holds ETH. Without bundle: swap tokens and deposit into a vaul. With bundling: 1 transaction, 1 signature.

How It Works

Example: Swap and deposit in one transaction
  1. Call /earn/bundle with a list of actions
  2. API returns a single transaction that executes all actions in order
  3. User signs once
  4. All actions execute atomically.
Result: User swaps ETH to USDC and deposits USDC into a vault with one signature.

Supported Actions

The bundle endpoint supports these action types:
Action TypeWhat it does
V2_SWAPSwap tokens within the Earn Account
V2_MANAGEDeposit or withdraw from ERC-4626 vaults or Aave markets
Actions execute in the order provided. This matters when one action depends on another (e.g., swap first, then deposit the swapped tokens). Missing an action? We can add it!

Combining with Other Features

With Gas Sponsorship

Set gas_sponsorship=true to get EIP-712 typed data. The owner signs off-chain, and a sender broadcasts the transaction paying gas. Then submit the signature to /gas_sponsorship/prepare.

With Embedded Fees

Add fees to individual V2_MANAGE actions (coming soon - for now, use individual endpoints for fee collection).

Next Steps

Start building bundled transactions: