Skip to content

feat: add SDK liquidity pool integration - #1003

Merged
Kingsman-99 merged 1 commit into
Stellar-split:mainfrom
mercyJJ:feat/liquidity-pool-integration-970
Sep 30, 2026
Merged

Kingsman-99 merged 1 commit into
Stellar-split:mainfrom
mercyJJ:feat/liquidity-pool-integration-970

Conversation

@mercyJJ

@mercyJJ mercyJJ commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

Closes #970

Summary

Implements LiquidityPoolClient — a client for interacting with Stellar AMM liquidity pools.

Changes

  • src/liquidityPool.ts: Core implementation with constant-product AMM math, swap estimation, deposit/withdrawal simulation, price impact calculation
  • test/liquidityPool.test.ts: Comprehensive test suite

Features

  • calculateSwapOutput — constant-product AMM swap math
  • calculatePriceImpactBps — price impact in basis points
  • LiquidityPoolClient — register pools, estimate swaps, simulate deposits/withdrawals
  • Configurable minLiquidityThreshold and maxPriceImpactBps guards

Acceptance Criteria

  • Feature implemented
  • All tests pass
  • TypeScript compiles with zero errors
  • ESLint passes

@drips-wave

drips-wave Bot commented Sep 30, 2026

Copy link
Copy Markdown

@mercyJJ Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Kingsman-99
Kingsman-99 merged commit 5faebf9 into Stellar-split:main Sep 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add SDK liquidity pool integration

2 participants