composer-sdk-examples repo. Each page shows the full SDK code and the resulting Flow shape.
Dust Sweep
Intentionally leave part of an input unused;
sweepTo recovers the dust back to the sender. Wallet-cleanup pattern.Swap and Deposit
Swap an input token to a vault asset, then zap the result into the vault. The canonical chained-deposit shape; powers LI.FI Earn.
Split Deposits
Split a single input across multiple vaults in one signed transaction. Multi-strategy yield without per-step capital lockup.
Debt Migration
Move a borrow position between protocols (Aave ā Morpho) atomically using two concurrent flash loans. Advanced flash-loan pattern.
More patterns in the SDK
The SDK ships 30+ worked examples covering everything from a minimallifi.swap to advanced multi-step flows: cross-token consolidation, recipient-side delivery, split verification with arithmetic and assertion ops (core.add, core.subtract, core.assertEqual, ā¦), allow-revert simulation, balance-precondition checks, raw core.call into arbitrary contracts, full Aave and Morpho Blue lending lifecycles (supply, borrow, repay, claim rewards), and flash-loan debt migrations. Browse them in the composer-sdk-examples repo.

