Skip to content

Commit

Permalink
chore: update ts-sdk comments and changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
codewithgun committed Jan 14, 2025
1 parent facad74 commit b79a74a
Show file tree
Hide file tree
Showing 3 changed files with 157 additions and 33 deletions.
37 changes: 36 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,42 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Security

## @meteora-ag/dlmm [1.3.8] - PR #144
## @meteora-ag/dlmm [1.3.9] - PR #140

### Changed

#### Breaking

- `getPairPubkeyIfExists` added new `baseFeePowerFactor` parameter
- `getAllPresetParameters` now return `presetParameter` and `presetParameter2` accounts instead of only `presetParameter`
- Rename `LBCLMM_PROGRAM_IDS` to `DLMM_PROGRAM_IDS`
- `createPermissionLbPair` added new `protocolFeeBps` parameter
- `removeLiquidity`, `binIds` parameter has been replaced by `fromBinId` and `toBinId` which represent the bin range to be removed
- `calculateFeeInfo` added new optional `baseFeePowerFactor` parameter
- `claimLMReward` added new optional `binRange` parameter
- `claimLMReward` now return `Transaction[]` instead of `Transaction`
- `claimSwapFee` added new optional `binRange` parameter
- `claimSwapFee` now return `Transaction[]` instead of `Transaction`

### Added

- `createCustomizablePermissionlessLbPair2`, similar as `createCustomizablePermissionlessLbPair` but support token 2022. Currently disabled on program side until next phase.
- `createLbPair2`, similar as `createLbPair` but support token 2022. Currently disabled on program side until next phase.
- `decreasePositionLength`. Use to shrink dynamic position.
- `increasePositionLength`. Use to expand dynamic position.
- `closePositionIfEmpty`. Will close the position only if it's empty, else do nothing.
- `migratePositionV3`. Use to migrate position from v2 to v3 a.k.a dynamic position.

### Deprecated

- `initializePositionAndAddLiquidityByWeight`. Use `initializePositionAndAddLiquidityByStrategy` instead which support both token and token 2022 program.
- `addLiquidityByWeight`. Use `addLiquidityByStrategy` instead which support both token and token2022.

### Removed

- `seedLiquiditySingleBin`. Checkout [meteora-pool-setup](https://github.com/MeteoraAg/meteora-pool-setup/blob/main/src/seed_liquidity_single_bin.ts) repository
- `seedLiquidity`. Checkout [meteora-pool-setup](https://github.com/MeteoraAg/meteora-pool-setup/blob/main/src/seed_liquidity_lfg.ts) repository
- `getWithdrawSingleSideAmount`. Unused.

## cli [0.5.0]

Expand Down
3 changes: 1 addition & 2 deletions ts-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@meteora-ag/dlmm",
"version": "1.3.8",
"version": "1.3.9",
"description": "",
"main": "./dist/index.js",
"module": "./dist/index.mjs",
Expand All @@ -13,7 +13,6 @@
"build": "tsup",
"start": "npm run build -- --watch",
"test": "jest 'src/test/(sdk|token_2022|sdk_token2022).test.ts'",
"debug": "jest src/test/sdk_token2022.test.ts",
"unit-test": "jest src/test/calculate_distribution.test.ts",
"dynamic-position-migration-test": "jest src/test/migrate_to_dynamic_position.test.ts",
"example": "dotenv -e .env npx ts-node src/example.ts",
Expand Down
Loading

0 comments on commit b79a74a

Please sign in to comment.