meteora-sdks

star 0

Helps developers build on Meteora's Solana DeFi protocols. Covers DLMM (Dynamic Liquidity Market Maker) concentrated liquidity pools and DAMM V2 dynamic AMM. Use when questions mention Meteora, DLMM, DAMM, concentrated liquidity, liquidity bins, bin step, LP positions, or @meteora-ag packages.

MeteoraAg By MeteoraAg schedule Updated 3/16/2026

name: meteora-sdks description: Helps developers build on Meteora's Solana DeFi protocols. Covers DLMM (Dynamic Liquidity Market Maker) concentrated liquidity pools and DAMM V2 dynamic AMM. Use when questions mention Meteora, DLMM, DAMM, concentrated liquidity, liquidity bins, bin step, LP positions, or @meteora-ag packages.

Meteora SDK Skill

This skill provides guidance for building with Meteora's Solana SDKs.

Available References

SDK Reference Status
DLMM references/dlmm.md Ready
DAMM V2 references/damm-v2.md Ready

How to Use

For DLMM Questions

  1. Read references/dlmm.md for API documentation and examples
  2. Reference assets/dlmm-example.ts for complete working code
  3. Key package: @meteora-ag/dlmm

For DAMM V2 Questions

  1. Read references/damm-v2.md for API documentation and examples
  2. Reference assets/damm-v2-example.ts for complete working code
  3. Key package: @meteora-ag/cp-amm-sdk

Code Style Guidelines

  • Use TypeScript with strict typing
  • Import from official packages (@meteora-ag/dlmm, @meteora-ag/cp-amm-sdk)
  • Use bn.js for all token amounts (never raw numbers)
  • Always handle transaction errors with try/catch
  • Include slippage tolerance in swaps and liquidity operations

Important Reminders

  1. Always recommend devnet testing first before mainnet deployment
  2. Token amounts are in smallest units (lamports, not SOL)
  3. Some operations return multiple transactions that must be executed sequentially
  4. Refresh pool state with refetchStates() after making changes

When to Use DLMM vs DAMM V2

Factor DLMM DAMM V2
Liquidity Concentrated in bins Full range (x*y=k)
Capital efficiency Higher Lower
Management Active (rebalancing needed) Passive (set and forget)
Best for Volatile pairs, active LPs Stable pairs, passive LPs
Fee structure Dynamic per-bin Per-pool configurable
Impermanent loss Reduced with good positioning Standard AMM IL

Choose DLMM when:

  • You want maximum capital efficiency
  • You can actively manage positions as price moves
  • Trading volatile pairs where concentration matters
  • You want to provide liquidity at specific price ranges

Choose DAMM V2 when:

  • You want a simple "deposit and forget" experience
  • Trading stable or established pairs with predictable prices
  • You prefer compounding fees back into liquidity
  • You're building pools for long-tail tokens

Escalation

If you encounter questions about:

  • Program internals or on-chain program addresses
  • Edge cases not covered in the reference docs

Escalate to: @dannweeeee

Common Tasks

Create a DLMM position

  1. Initialize pool with DLMM.create()
  2. Get active bin with getActiveBin()
  3. Create position with initializePositionAndAddLiquidityByStrategy()

Execute a swap

  1. Get bin arrays with getBinArrayForSwap()
  2. Get quote with swapQuote()
  3. Execute with swap()

Claim fees

  1. Get positions with getPositionsByUserAndLbPair()
  2. Claim with claimAllRewards() or claimSwapFee()

Remove liquidity

  1. Get position bin data
  2. Call removeLiquidity() with shouldClaimAndClose: true to also close
Install via CLI
npx skills add https://github.com/MeteoraAg/meteora-sdk-skill --skill meteora-sdks
Repository Details
star Stars 0
call_split Forks 0
navigation Branch main
article Path SKILL.md
More from Creator