Welcome to Compass API
The Compass DeFi API is a unified interface for building DeFi products across multiple protocols and blockchains. Access lending markets, yield aggregation, borrowing, and trading through a single integration. Compass connects fintechs, payment platforms, wallets, and institutions to DeFi. We provide transaction payloads and historical and real-time data, you control the user experience and maintain custody. Our mission: make DeFi products as easy to build as any Web2 product. The Compass API and SDKs let you ship DeFi features in days while we handle the blockchain plumbing.Read our latest product report here to get a clear view of what is supported and how Compass can be used to monitor markets, automate transactions, and manage exposure across venues.
What We Do
Protocol Integration Layer: One API to access thousands of DeFi venues (Aave, Morpho, Pendle, Uniswap, Mellow Finance, and more). We handle upgrades and keep your integrations stable. You make one API call. Transaction Construction: Generate unsigned transaction payloads for any DeFi action. Bundle multiple operations (e.g. (allowance + deposit into vault + embed fee + gas sponsorship) atomically. Sponsor gas. Embed fees. Your users sign, we handle execution. Data & Position Tracking: Real-time position tracking, APY monitoring, health factors, balances, and historical performance, all through a unified SDK. Same interface across all protocols. Account Orchestration: Automatically create and manage Product Accounts: isolated on-chain accounts per feature (Earn, Borrow, Trade). Enables bundling without approvals, prevents fund intermingling, simplifies compliance.How It Works
- You call our API/SDK with an intent (deposit, borrow, swap)
- We generate the transaction payload. This includes:
- Creating/managing Product Accounts if needed
- Bundling multiple operations if requested
- Embedding your fees if configured
- Gas sponsorship if enabled
- Your user signs with their wallet (EOA, Dynamic, Privy, MetaMask, Fireblocks, etc.)
- Transaction executes directly into the protocol (Aave, Morpho, etc)
- We provide ongoing data: position tracking, balances, yields, analytics.
Key features
- Transaction Bundling: Execute multi-step workflows in one atomic transaction. Swap + deposit, rebalance across vaults, and more. Save 50-70% on gas.
- Embedded Fees: Monetize immediately by adding fees to any transaction. Collected automatically when users deposit, withdraw, or borrow.
- Product Accounts: Isolated on-chain accounts per product. Prevent fund intermingling, provide independent accounting per product, and simplify compliance. Launch one product today, add others later without refactoring.
- Gas Abstraction: Sponsor gas for your users so they never need ETH.
- Non-custodial: Compass never holds assets and does not deploy asset vaults. The end user is the owner and only valid signer.
- SDKs for Python & TypeScript: Fast and easy-to-use Python and TypeScript SDKs so you can focus on building incredible products.
Use cases
- Wallets - Add yield products without protocol integration overhead.
- Fintechs - Launch stablecoin savings or crypto-backed credit lines.
- Payment platforms - Manage and optimize treasury, earn on idle stablecoins, access instant credit, all within your application.
- Institutions - Earn on treasury balances or access liquidity via DeFi protocols.
Getting started
- Sign up for a free API key (1,000 calls/month).
- Run the Quickstart to execute your first on‑chain action in minutes.
- Explore examples for common flows and bundles.
Need help?
Exploring an integration or shipping a new DeFi feature? Tell us what you’re building and we’ll help you go live fast.- Email: contact@compasslabs.ai
Chat With Us
Schedule a 1:1 with our team to get you set up quickly.
Join our Discord
Stay up-to-date and join our builder community.