@meteora-ag/dlmm 1.3.14-sam.0 → 1.3.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -5,7 +5,7 @@ import { PublicKey, TransactionInstruction, Connection, Transaction, Cluster } f
5
5
  import Decimal from 'decimal.js';
6
6
 
7
7
  type LbClmm = {
8
- "version": "0.8.2";
8
+ "version": "0.8.6";
9
9
  "name": "lb_clmm";
10
10
  "constants": [
11
11
  {
@@ -93,6 +93,16 @@ type LbClmm = {
93
93
  };
94
94
  "value": "15";
95
95
  },
96
+ {
97
+ "name": "ILM_PROTOCOL_SHARE";
98
+ "type": "u16";
99
+ "value": "2000";
100
+ },
101
+ {
102
+ "name": "PROTOCOL_SHARE";
103
+ "type": "u16";
104
+ "value": "500";
105
+ },
96
106
  {
97
107
  "name": "MAX_BIN_STEP";
98
108
  "type": "u16";
@@ -108,6 +118,11 @@ type LbClmm = {
108
118
  "type": "u128";
109
119
  "value": "100_000";
110
120
  },
121
+ {
122
+ "name": "MINIMUM_LIQUIDITY";
123
+ "type": "u128";
124
+ "value": "1_000_000";
125
+ },
111
126
  {
112
127
  "name": "BIN_ARRAY";
113
128
  "type": "bytes";
@@ -365,7 +380,7 @@ type LbClmm = {
365
380
  "isSigner": false;
366
381
  },
367
382
  {
368
- "name": "rent";
383
+ "name": "userTokenY";
369
384
  "isMut": false;
370
385
  "isSigner": false;
371
386
  },
@@ -1944,7 +1959,7 @@ type LbClmm = {
1944
1959
  "args": [];
1945
1960
  },
1946
1961
  {
1947
- "name": "updateFeeParameters";
1962
+ "name": "updateBaseFeeParameters";
1948
1963
  "accounts": [
1949
1964
  {
1950
1965
  "name": "lbPair";
@@ -1971,7 +1986,40 @@ type LbClmm = {
1971
1986
  {
1972
1987
  "name": "feeParameter";
1973
1988
  "type": {
1974
- "defined": "FeeParameter";
1989
+ "defined": "BaseFeeParameter";
1990
+ };
1991
+ }
1992
+ ];
1993
+ },
1994
+ {
1995
+ "name": "updateDynamicFeeParameters";
1996
+ "accounts": [
1997
+ {
1998
+ "name": "lbPair";
1999
+ "isMut": true;
2000
+ "isSigner": false;
2001
+ },
2002
+ {
2003
+ "name": "admin";
2004
+ "isMut": false;
2005
+ "isSigner": true;
2006
+ },
2007
+ {
2008
+ "name": "eventAuthority";
2009
+ "isMut": false;
2010
+ "isSigner": false;
2011
+ },
2012
+ {
2013
+ "name": "program";
2014
+ "isMut": false;
2015
+ "isSigner": false;
2016
+ }
2017
+ ];
2018
+ "args": [
2019
+ {
2020
+ "name": "feeParameter";
2021
+ "type": {
2022
+ "defined": "DynamicFeeParameter";
1975
2023
  };
1976
2024
  }
1977
2025
  ];
@@ -2154,7 +2202,7 @@ type LbClmm = {
2154
2202
  "args": [];
2155
2203
  },
2156
2204
  {
2157
- "name": "togglePairStatus";
2205
+ "name": "setPairStatus";
2158
2206
  "accounts": [
2159
2207
  {
2160
2208
  "name": "lbPair";
@@ -2167,7 +2215,12 @@ type LbClmm = {
2167
2215
  "isSigner": true;
2168
2216
  }
2169
2217
  ];
2170
- "args": [];
2218
+ "args": [
2219
+ {
2220
+ "name": "status";
2221
+ "type": "u8";
2222
+ }
2223
+ ];
2171
2224
  },
2172
2225
  {
2173
2226
  "name": "migratePosition";
@@ -2603,6 +2656,27 @@ type LbClmm = {
2603
2656
  "type": "publicKey";
2604
2657
  }
2605
2658
  ];
2659
+ },
2660
+ {
2661
+ "name": "setPairStatusPermissionless";
2662
+ "accounts": [
2663
+ {
2664
+ "name": "lbPair";
2665
+ "isMut": true;
2666
+ "isSigner": false;
2667
+ },
2668
+ {
2669
+ "name": "creator";
2670
+ "isMut": false;
2671
+ "isSigner": true;
2672
+ }
2673
+ ];
2674
+ "args": [
2675
+ {
2676
+ "name": "status";
2677
+ "type": "u8";
2678
+ }
2679
+ ];
2606
2680
  }
2607
2681
  ];
2608
2682
  "accounts": [
@@ -2794,9 +2868,9 @@ type LbClmm = {
2794
2868
  "type": "u8";
2795
2869
  },
2796
2870
  {
2797
- "name": "padding0";
2871
+ "name": "creatorPoolOnOffControl";
2798
2872
  "docs": [
2799
- "padding 0"
2873
+ "Allow pool creator to enable/disable pool with restricted validation. Only applicable for customizable permissionless pair type."
2800
2874
  ];
2801
2875
  "type": "u8";
2802
2876
  },
@@ -3428,7 +3502,7 @@ type LbClmm = {
3428
3502
  };
3429
3503
  },
3430
3504
  {
3431
- "name": "FeeParameter";
3505
+ "name": "BaseFeeParameter";
3432
3506
  "type": {
3433
3507
  "kind": "struct";
3434
3508
  "fields": [
@@ -3449,6 +3523,49 @@ type LbClmm = {
3449
3523
  ];
3450
3524
  };
3451
3525
  },
3526
+ {
3527
+ "name": "DynamicFeeParameter";
3528
+ "type": {
3529
+ "kind": "struct";
3530
+ "fields": [
3531
+ {
3532
+ "name": "filterPeriod";
3533
+ "docs": [
3534
+ "Filter period determine high frequency trading time window."
3535
+ ];
3536
+ "type": "u16";
3537
+ },
3538
+ {
3539
+ "name": "decayPeriod";
3540
+ "docs": [
3541
+ "Decay period determine when the volatile fee start decay / decrease."
3542
+ ];
3543
+ "type": "u16";
3544
+ },
3545
+ {
3546
+ "name": "reductionFactor";
3547
+ "docs": [
3548
+ "Reduction factor controls the volatile fee rate decrement rate."
3549
+ ];
3550
+ "type": "u16";
3551
+ },
3552
+ {
3553
+ "name": "variableFeeControl";
3554
+ "docs": [
3555
+ "Used to scale the variable fee component depending on the dynamic of the market"
3556
+ ];
3557
+ "type": "u32";
3558
+ },
3559
+ {
3560
+ "name": "maxVolatilityAccumulator";
3561
+ "docs": [
3562
+ "Maximum number of bin crossed can be accumulated. Used to cap volatile fee rate."
3563
+ ];
3564
+ "type": "u32";
3565
+ }
3566
+ ];
3567
+ };
3568
+ },
3452
3569
  {
3453
3570
  "name": "LiquidityParameterByStrategyOneSide";
3454
3571
  "type": {
@@ -3831,6 +3948,13 @@ type LbClmm = {
3831
3948
  "option": "u64";
3832
3949
  };
3833
3950
  },
3951
+ {
3952
+ "name": "creatorPoolOnOffControl";
3953
+ "docs": [
3954
+ "Pool creator have permission to enable/disable pool with restricted program validation. Only applicable for customizable permissionless pool."
3955
+ ];
3956
+ "type": "bool";
3957
+ },
3834
3958
  {
3835
3959
  "name": "padding";
3836
3960
  "docs": [
@@ -3839,7 +3963,7 @@ type LbClmm = {
3839
3963
  "type": {
3840
3964
  "array": [
3841
3965
  "u8",
3842
- 64
3966
+ 63
3843
3967
  ];
3844
3968
  };
3845
3969
  }
@@ -4814,6 +4938,41 @@ type LbClmm = {
4814
4938
  }
4815
4939
  ];
4816
4940
  },
4941
+ {
4942
+ "name": "DynamicFeeParameterUpdate";
4943
+ "fields": [
4944
+ {
4945
+ "name": "lbPair";
4946
+ "type": "publicKey";
4947
+ "index": false;
4948
+ },
4949
+ {
4950
+ "name": "filterPeriod";
4951
+ "type": "u16";
4952
+ "index": false;
4953
+ },
4954
+ {
4955
+ "name": "decayPeriod";
4956
+ "type": "u16";
4957
+ "index": false;
4958
+ },
4959
+ {
4960
+ "name": "reductionFactor";
4961
+ "type": "u16";
4962
+ "index": false;
4963
+ },
4964
+ {
4965
+ "name": "variableFeeControl";
4966
+ "type": "u32";
4967
+ "index": false;
4968
+ },
4969
+ {
4970
+ "name": "maxVolatilityAccumulator";
4971
+ "type": "u32";
4972
+ "index": false;
4973
+ }
4974
+ ];
4975
+ },
4817
4976
  {
4818
4977
  "name": "IncreaseObservation";
4819
4978
  "fields": [
@@ -5250,6 +5409,21 @@ type LbClmm = {
5250
5409
  "code": 6065;
5251
5410
  "name": "AlreadyPassPreActivationSwapPoint";
5252
5411
  "msg": "Already pass pre-activation swap point";
5412
+ },
5413
+ {
5414
+ "code": 6066;
5415
+ "name": "InvalidStatus";
5416
+ "msg": "Invalid status";
5417
+ },
5418
+ {
5419
+ "code": 6067;
5420
+ "name": "ExceededMaxOracleLength";
5421
+ "msg": "Exceed max oracle length";
5422
+ },
5423
+ {
5424
+ "code": 6068;
5425
+ "name": "InvalidMinimumLiquidity";
5426
+ "msg": "Invalid minimum liquidity";
5253
5427
  }
5254
5428
  ];
5255
5429
  };
@@ -5334,15 +5508,6 @@ declare enum PairType {
5334
5508
  Permissioned = 1
5335
5509
  }
5336
5510
  declare const Strategy: {
5337
- SpotOneSide: {
5338
- spotOneSide: {};
5339
- };
5340
- CurveOneSide: {
5341
- curveOneSide: {};
5342
- };
5343
- BidAskOneSide: {
5344
- bidAskOneSide: {};
5345
- };
5346
5511
  SpotBalanced: {
5347
5512
  spotBalanced: {};
5348
5513
  };
@@ -5363,15 +5528,12 @@ declare const Strategy: {
5363
5528
  };
5364
5529
  };
5365
5530
  declare enum StrategyType {
5366
- SpotOneSide = 0,
5367
- CurveOneSide = 1,
5368
- BidAskOneSide = 2,
5369
- SpotImBalanced = 3,
5370
- CurveImBalanced = 4,
5371
- BidAskImBalanced = 5,
5372
- SpotBalanced = 6,
5373
- CurveBalanced = 7,
5374
- BidAskBalanced = 8
5531
+ SpotImBalanced = 0,
5532
+ CurveImBalanced = 1,
5533
+ BidAskImBalanced = 2,
5534
+ SpotBalanced = 3,
5535
+ CurveBalanced = 4,
5536
+ BidAskBalanced = 5
5375
5537
  }
5376
5538
  declare enum ActivationType {
5377
5539
  Slot = 0,
@@ -5569,6 +5731,16 @@ declare enum PairStatus {
5569
5731
  Enabled = 0,
5570
5732
  Disabled = 1
5571
5733
  }
5734
+ interface PairLockInfo {
5735
+ positions: Array<PositionLockInfo>;
5736
+ }
5737
+ interface PositionLockInfo {
5738
+ positionAddress: PublicKey;
5739
+ owner: PublicKey;
5740
+ tokenXAmount: string;
5741
+ tokenYAmount: string;
5742
+ lockReleasePoint: number;
5743
+ }
5572
5744
 
5573
5745
  type Opt = {
5574
5746
  cluster?: Cluster | "localhost";
@@ -5641,18 +5813,34 @@ declare class DLMM {
5641
5813
  * Pair account, and the value is an object of PositionInfo
5642
5814
  */
5643
5815
  static getAllLbPairPositionsByUser(connection: Connection, userPubKey: PublicKey, opt?: Opt): Promise<Map<string, PositionInfo>>;
5644
- static migratePosition(connection: Connection, positions: PublicKey[], newPositions: PublicKey[], walletPubkey: PublicKey, opt?: Opt): Promise<Transaction[]>;
5645
5816
  static getPricePerLamport(tokenXDecimal: number, tokenYDecimal: number, price: number): string;
5646
5817
  static getBinIdFromPrice(price: string | number | Decimal, binStep: number, min: boolean): number;
5818
+ /**
5819
+ * The function `getLbPairLockInfo` retrieves all pair positions that has locked liquidity.
5820
+ * @param {number} [lockDurationOpt] - An optional value indicating the minimum position lock duration that the function should return.
5821
+ * Depending on the lbPair activationType, the param should be a number of seconds or a number of slots.
5822
+ * @returns The function `getLbPairLockInfo` returns a `Promise` that resolves to a `PairLockInfo`
5823
+ * object. The `PairLockInfo` object contains an array of `PositionLockInfo` objects.
5824
+ */
5825
+ getLbPairLockInfo(lockDurationOpt?: number): Promise<PairLockInfo>;
5647
5826
  /** Public methods */
5648
5827
  static createPermissionLbPair(connection: Connection, binStep: BN, tokenX: PublicKey, tokenY: PublicKey, activeId: BN, baseKey: PublicKey, creatorKey: PublicKey, feeBps: BN, activationType: ActivationType, opt?: Opt): Promise<Transaction>;
5649
- static createCustomizablePermissionlessLbPair(connection: Connection, binStep: BN, tokenX: PublicKey, tokenY: PublicKey, activeId: BN, feeBps: BN, activationType: ActivationType, hasAlphaVault: boolean, creatorKey: PublicKey, activationPoint?: BN, opt?: Opt): Promise<Transaction>;
5828
+ static createCustomizablePermissionlessLbPair(connection: Connection, binStep: BN, tokenX: PublicKey, tokenY: PublicKey, activeId: BN, feeBps: BN, activationType: ActivationType, hasAlphaVault: boolean, creatorKey: PublicKey, activationPoint?: BN, creatorPoolOnOffControl?: boolean, opt?: Opt): Promise<Transaction>;
5650
5829
  static createLbPair(connection: Connection, funder: PublicKey, tokenX: PublicKey, tokenY: PublicKey, binStep: BN, baseFactor: BN, presetParameter: PublicKey, activeId: BN, opt?: Opt): Promise<Transaction>;
5651
5830
  /**
5652
5831
  * The function `refetchStates` retrieves and updates various states and data related to bin arrays
5653
5832
  * and lb pairs.
5654
5833
  */
5655
5834
  refetchStates(): Promise<void>;
5835
+ /**
5836
+ * Set the status of a permissionless LB pair to either enabled or disabled. This require pool field `creator_pool_on_off_control` to be true and type `CustomizablePermissionless`.
5837
+ * Pool creator can enable/disable the pair anytime before the pool is opened / activated. Once the pool activation time is passed, the pool creator can only enable the pair.
5838
+ * Useful for token launches which do not have fixed activation time.
5839
+ * @param enable If true, the pair will be enabled. If false, the pair will be disabled.
5840
+ * @param creator The public key of the pool creator.
5841
+ * @returns a Promise that resolves to the transaction.
5842
+ */
5843
+ setPairStatusPermissionless(enable: boolean, creator: PublicKey): Promise<Transaction>;
5656
5844
  /**
5657
5845
  * The function `getBinArrays` returns an array of `BinArrayAccount` objects
5658
5846
  * @returns a Promise that resolves to an array of BinArrayAccount objects.
@@ -5795,6 +5983,19 @@ declare class DLMM {
5795
5983
  maxBinId: number;
5796
5984
  user: PublicKey;
5797
5985
  }): Promise<Transaction>;
5986
+ /**
5987
+ * The function `getPosition` retrieves position information for a given public key and processes it
5988
+ * using various data to return a `LbPosition` object.
5989
+ * @param {PublicKey} positionPubKey - The `getPosition` function you provided is an asynchronous
5990
+ * function that fetches position information based on a given public key. Here's a breakdown of the
5991
+ * parameters used in the function:
5992
+ * @returns The `getPosition` function returns a Promise that resolves to an object of type
5993
+ * `LbPosition`. The object contains the following properties:
5994
+ * - `publicKey`: The public key of the position account
5995
+ * - `positionData`: Position Object
5996
+ * - `version`: The version of the position (in this case, `Position.V2`)
5997
+ */
5998
+ getPosition(positionPubKey: PublicKey): Promise<LbPosition>;
5798
5999
  /**
5799
6000
  * The function `initializePositionAndAddLiquidityByStrategy` function is used to initializes a position and adds liquidity
5800
6001
  * @param {TInitializePositionAndAddLiquidityParamsByStrategy}
@@ -5882,6 +6083,7 @@ declare class DLMM {
5882
6083
  * - `outAmount`: Amount of lamport to swap out
5883
6084
  * - `swapForY`: Swap token X to Y when it is true, else reversed.
5884
6085
  * - `allowedSlippage`: Allowed slippage for the swap. Expressed in BPS. To convert from slippage percentage to BPS unit: SLIPPAGE_PERCENTAGE * 100
6086
+ * - `maxExtraBinArrays`: Maximum number of extra binArrays to return
5885
6087
  * @returns {SwapQuote}
5886
6088
  * - `inAmount`: Amount of lamport to swap in
5887
6089
  * - `outAmount`: Amount of lamport to swap out
@@ -5892,7 +6094,7 @@ declare class DLMM {
5892
6094
  * @throws {DlmmSdkError}
5893
6095
  *
5894
6096
  */
5895
- swapQuoteExactOut(outAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[]): SwapQuoteExactOut;
6097
+ swapQuoteExactOut(outAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[], maxExtraBinArrays?: number): SwapQuoteExactOut;
5896
6098
  /**
5897
6099
  * The `swapQuote` function returns a quote for a swap
5898
6100
  * @param
@@ -5901,6 +6103,7 @@ declare class DLMM {
5901
6103
  * - `allowedSlippage`: Allowed slippage for the swap. Expressed in BPS. To convert from slippage percentage to BPS unit: SLIPPAGE_PERCENTAGE * 100
5902
6104
  * - `binArrays`: binArrays for swapQuote.
5903
6105
  * - `isPartialFill`: Flag to check whether the the swapQuote is partial fill, default = false.
6106
+ * - `maxExtraBinArrays`: Maximum number of extra binArrays to return
5904
6107
  * @returns {SwapQuote}
5905
6108
  * - `consumedInAmount`: Amount of lamport to swap in
5906
6109
  * - `outAmount`: Amount of lamport to swap out
@@ -5911,7 +6114,7 @@ declare class DLMM {
5911
6114
  * - `binArraysPubkey`: Array of bin arrays involved in the swap
5912
6115
  * @throws {DlmmSdkError}
5913
6116
  */
5914
- swapQuote(inAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[], isPartialFill?: boolean): SwapQuote;
6117
+ swapQuote(inAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[], isPartialFill?: boolean, maxExtraBinArrays?: number): SwapQuote;
5915
6118
  swapExactOut({ inToken, outToken, outAmount, maxInAmount, lbPair, user, binArraysPubkey, }: SwapExactOutParams): Promise<Transaction>;
5916
6119
  /**
5917
6120
  * Returns a transaction to be signed and sent by user performing swap.
@@ -5963,6 +6166,7 @@ declare class DLMM {
5963
6166
  positions: LbPosition[];
5964
6167
  }): Promise<Transaction[]>;
5965
6168
  setActivationPoint(activationPoint: BN): Promise<Transaction>;
6169
+ setPairStatus(enabled: boolean): Promise<Transaction>;
5966
6170
  /**
5967
6171
  * The function `claimSwapFee` is used to claim swap fees for a specific position owned by a specific owner.
5968
6172
  * @param
@@ -6239,10 +6443,6 @@ declare function autoFillXByWeight(activeId: number, binStep: number, amountY: B
6239
6443
  weight: number;
6240
6444
  }[]): BN;
6241
6445
 
6242
- declare function toAmountsOneSideByStrategy(activeId: number, binStep: number, minBinId: number, maxBinId: number, amount: BN, strategyType: StrategyType, depositForY: boolean): {
6243
- binId: number;
6244
- amount: BN;
6245
- }[];
6246
6446
  declare function toAmountsBothSideByStrategy(activeId: number, binStep: number, minBinId: number, maxBinId: number, amountX: BN, amountY: BN, amountXInActiveBin: BN, amountYInActiveBin: BN, strategyType: StrategyType): {
6247
6447
  binId: number;
6248
6448
  amountX: BN;
@@ -6251,58 +6451,10 @@ declare function toAmountsBothSideByStrategy(activeId: number, binStep: number,
6251
6451
  declare function autoFillYByStrategy(activeId: number, binStep: number, amountX: BN, amountXInActiveBin: BN, amountYInActiveBin: BN, minBinId: number, maxBinId: number, strategyType: StrategyType): BN;
6252
6452
  declare function autoFillXByStrategy(activeId: number, binStep: number, amountY: BN, amountXInActiveBin: BN, amountYInActiveBin: BN, minBinId: number, maxBinId: number, strategyType: StrategyType): BN;
6253
6453
  declare function toStrategyParameters({ maxBinId, minBinId, strategyType, singleSidedX, }: StrategyParameters): {
6254
- minBinId: number;
6255
- maxBinId: number;
6256
- strategyType: {
6257
- spotOneSide: {};
6258
- curveOneSide?: undefined;
6259
- bidAskOneSide?: undefined;
6260
- spotBalanced?: undefined;
6261
- curveBalanced?: undefined;
6262
- bidAskBalanced?: undefined;
6263
- spotImBalanced?: undefined;
6264
- curveImBalanced?: undefined;
6265
- bidAskImBalanced?: undefined;
6266
- };
6267
- parameteres: number[];
6268
- } | {
6269
- minBinId: number;
6270
- maxBinId: number;
6271
- strategyType: {
6272
- curveOneSide: {};
6273
- spotOneSide?: undefined;
6274
- bidAskOneSide?: undefined;
6275
- spotBalanced?: undefined;
6276
- curveBalanced?: undefined;
6277
- bidAskBalanced?: undefined;
6278
- spotImBalanced?: undefined;
6279
- curveImBalanced?: undefined;
6280
- bidAskImBalanced?: undefined;
6281
- };
6282
- parameteres: number[];
6283
- } | {
6284
- minBinId: number;
6285
- maxBinId: number;
6286
- strategyType: {
6287
- bidAskOneSide: {};
6288
- spotOneSide?: undefined;
6289
- curveOneSide?: undefined;
6290
- spotBalanced?: undefined;
6291
- curveBalanced?: undefined;
6292
- bidAskBalanced?: undefined;
6293
- spotImBalanced?: undefined;
6294
- curveImBalanced?: undefined;
6295
- bidAskImBalanced?: undefined;
6296
- };
6297
- parameteres: number[];
6298
- } | {
6299
6454
  minBinId: number;
6300
6455
  maxBinId: number;
6301
6456
  strategyType: {
6302
6457
  spotBalanced: {};
6303
- spotOneSide?: undefined;
6304
- curveOneSide?: undefined;
6305
- bidAskOneSide?: undefined;
6306
6458
  curveBalanced?: undefined;
6307
6459
  bidAskBalanced?: undefined;
6308
6460
  spotImBalanced?: undefined;
@@ -6315,9 +6467,6 @@ declare function toStrategyParameters({ maxBinId, minBinId, strategyType, single
6315
6467
  maxBinId: number;
6316
6468
  strategyType: {
6317
6469
  curveBalanced: {};
6318
- spotOneSide?: undefined;
6319
- curveOneSide?: undefined;
6320
- bidAskOneSide?: undefined;
6321
6470
  spotBalanced?: undefined;
6322
6471
  bidAskBalanced?: undefined;
6323
6472
  spotImBalanced?: undefined;
@@ -6330,9 +6479,6 @@ declare function toStrategyParameters({ maxBinId, minBinId, strategyType, single
6330
6479
  maxBinId: number;
6331
6480
  strategyType: {
6332
6481
  bidAskBalanced: {};
6333
- spotOneSide?: undefined;
6334
- curveOneSide?: undefined;
6335
- bidAskOneSide?: undefined;
6336
6482
  spotBalanced?: undefined;
6337
6483
  curveBalanced?: undefined;
6338
6484
  spotImBalanced?: undefined;
@@ -6345,9 +6491,6 @@ declare function toStrategyParameters({ maxBinId, minBinId, strategyType, single
6345
6491
  maxBinId: number;
6346
6492
  strategyType: {
6347
6493
  spotImBalanced: {};
6348
- spotOneSide?: undefined;
6349
- curveOneSide?: undefined;
6350
- bidAskOneSide?: undefined;
6351
6494
  spotBalanced?: undefined;
6352
6495
  curveBalanced?: undefined;
6353
6496
  bidAskBalanced?: undefined;
@@ -6360,9 +6503,6 @@ declare function toStrategyParameters({ maxBinId, minBinId, strategyType, single
6360
6503
  maxBinId: number;
6361
6504
  strategyType: {
6362
6505
  curveImBalanced: {};
6363
- spotOneSide?: undefined;
6364
- curveOneSide?: undefined;
6365
- bidAskOneSide?: undefined;
6366
6506
  spotBalanced?: undefined;
6367
6507
  curveBalanced?: undefined;
6368
6508
  bidAskBalanced?: undefined;
@@ -6375,9 +6515,6 @@ declare function toStrategyParameters({ maxBinId, minBinId, strategyType, single
6375
6515
  maxBinId: number;
6376
6516
  strategyType: {
6377
6517
  bidAskImBalanced: {};
6378
- spotOneSide?: undefined;
6379
- curveOneSide?: undefined;
6380
- bidAskOneSide?: undefined;
6381
6518
  spotBalanced?: undefined;
6382
6519
  curveBalanced?: undefined;
6383
6520
  bidAskBalanced?: undefined;
@@ -6432,7 +6569,7 @@ declare function chunkedFetchMultiplePoolAccount(program: ClmmProgram, pks: Publ
6432
6569
  requireBaseFactorSeed: number;
6433
6570
  baseFactorSeed: number[];
6434
6571
  activationType: number;
6435
- padding0: number;
6572
+ creatorPoolOnOffControl: number;
6436
6573
  tokenXMint: PublicKey;
6437
6574
  tokenYMint: PublicKey;
6438
6575
  reserveX: PublicKey;
@@ -6505,7 +6642,7 @@ declare class DLMMError extends Error {
6505
6642
  errorMessage: string;
6506
6643
  constructor(error: object | Codes);
6507
6644
  }
6508
- type ErrorName = "SWAP_QUOTE_INSUFFICIENT_LIQUIDITY";
6645
+ type ErrorName = "SWAP_QUOTE_INSUFFICIENT_LIQUIDITY" | "INVALID_MAX_EXTRA_BIN_ARRAYS";
6509
6646
  declare class DlmmSdkError extends Error {
6510
6647
  name: ErrorName;
6511
6648
  message: string;
@@ -6545,5 +6682,6 @@ declare const MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX = 26;
6545
6682
  declare const MAX_BIN_PER_TX = 69;
6546
6683
  declare const MAX_ACTIVE_BIN_SLIPPAGE = 3;
6547
6684
  declare const ILM_BASE: PublicKey;
6685
+ declare const MAX_EXTRA_BIN_ARRAYS = 3;
6548
6686
 
6549
- export { ADMIN, ActivationType, BASIS_POINT_MAX, BIN_ARRAY_BITMAP_SIZE, BIN_ARRAY_FEE, Bin, BinAndAmount, BinArray, BinArrayAccount, BinArrayBitmapExtension, BinArrayBitmapExtensionAccount, BinLiquidity, BinLiquidityDistribution, BinLiquidityReduction, BitmapType, ClmmProgram, Clock, ClockLayout, CompressedBinDepositAmount, CompressedBinDepositAmounts, DLMMError, DlmmSdkError, EXTENSION_BINARRAY_BITMAP_SIZE, EmissionRate, FEE_PRECISION, FeeInfo, GetOrCreateATAResponse, IAccountsCache, IDL, ILM_BASE, InitCustomizablePermissionlessPairIx, InitPermissionPairIx, LBCLMM_PROGRAM_IDS, LMRewards, LbClmm, LbPair, LbPairAccount, LbPosition, LiquidityOneSideParameter, LiquidityParameter, LiquidityParameterByStrategy, LiquidityParameterByStrategyOneSide, LiquidityParameterByWeight, MAX_ACTIVE_BIN_SLIPPAGE, MAX_BIN_ARRAY_SIZE, MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX, MAX_BIN_PER_POSITION, MAX_BIN_PER_TX, MAX_CLAIM_ALL_ALLOWED, MAX_FEE_RATE, Network, POSITION_FEE, PRECISION, PairStatus, PairType, Position, PositionBinData, PositionData, PositionInfo, PositionV2, PositionVersion, ProgramStrategyParameter, ProgramStrategyType, SCALE, SCALE_OFFSET, SIMULATION_USER, SeedLiquidityResponse, Strategy, StrategyParameters, StrategyType, SwapExactOutParams, SwapFee, SwapParams, SwapQuote, SwapQuoteExactOut, SwapWithPriceImpactParams, TInitializePositionAndAddLiquidityParams, TInitializePositionAndAddLiquidityParamsByStrategy, TQuoteCreatePositionParams, TokenReserve, autoFillXByStrategy, autoFillXByWeight, autoFillYByStrategy, autoFillYByWeight, binIdToBinArrayIndex, calculateBidAskDistribution, calculateNormalDistribution, calculateSpotDistribution, chunkedFetchMultipleBinArrayBitmapExtensionAccount, chunkedFetchMultiplePoolAccount, chunkedGetMultipleAccountInfos, chunks, computeFee, computeFeeFromAmount, computeProtocolFee, DLMM as default, deriveBinArray, deriveBinArrayBitmapExtension, deriveCustomizablePermissionlessLbPair, deriveLbPair, deriveLbPair2, deriveOracle, derivePermissionLbPair, derivePosition, derivePresetParameter, derivePresetParameter2, deriveReserve, enumerateBins, findNextBinArrayIndexWithLiquidity, findNextBinArrayWithLiquidity, fromWeightDistributionToAmount, fromWeightDistributionToAmountOneSide, getBaseFee, getBinArrayLowerUpperBinId, getBinArraysRequiredByPositionRange, getBinFromBinArray, getEstimatedComputeUnitIxWithBuffer, getEstimatedComputeUnitUsageWithBuffer, getOrCreateATAInstruction, getOutAmount, getPriceOfBinByBinId, getTokenBalance, getTokenDecimals, getTokensMintFromPoolAddress, getTotalFee, getVariableFee, isBinIdWithinBinArray, isOverflowDefaultBinArrayBitmap, parseLogs, range, sParameters, swapExactInQuoteAtBin, swapExactOutQuoteAtBin, toAmountAskSide, toAmountBidSide, toAmountBothSide, toAmountsBothSideByStrategy, toAmountsOneSideByStrategy, toStrategyParameters, toWeightDistribution, unwrapSOLInstruction, vParameters, wrapSOLInstruction };
6687
+ export { ADMIN, ActivationType, BASIS_POINT_MAX, BIN_ARRAY_BITMAP_SIZE, BIN_ARRAY_FEE, Bin, BinAndAmount, BinArray, BinArrayAccount, BinArrayBitmapExtension, BinArrayBitmapExtensionAccount, BinLiquidity, BinLiquidityDistribution, BinLiquidityReduction, BitmapType, ClmmProgram, Clock, ClockLayout, CompressedBinDepositAmount, CompressedBinDepositAmounts, DLMMError, DlmmSdkError, EXTENSION_BINARRAY_BITMAP_SIZE, EmissionRate, FEE_PRECISION, FeeInfo, GetOrCreateATAResponse, IAccountsCache, IDL, ILM_BASE, InitCustomizablePermissionlessPairIx, InitPermissionPairIx, LBCLMM_PROGRAM_IDS, LMRewards, LbClmm, LbPair, LbPairAccount, LbPosition, LiquidityOneSideParameter, LiquidityParameter, LiquidityParameterByStrategy, LiquidityParameterByStrategyOneSide, LiquidityParameterByWeight, MAX_ACTIVE_BIN_SLIPPAGE, MAX_BIN_ARRAY_SIZE, MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX, MAX_BIN_PER_POSITION, MAX_BIN_PER_TX, MAX_CLAIM_ALL_ALLOWED, MAX_EXTRA_BIN_ARRAYS, MAX_FEE_RATE, Network, POSITION_FEE, PRECISION, PairLockInfo, PairStatus, PairType, Position, PositionBinData, PositionData, PositionInfo, PositionLockInfo, PositionV2, PositionVersion, ProgramStrategyParameter, ProgramStrategyType, SCALE, SCALE_OFFSET, SIMULATION_USER, SeedLiquidityResponse, Strategy, StrategyParameters, StrategyType, SwapExactOutParams, SwapFee, SwapParams, SwapQuote, SwapQuoteExactOut, SwapWithPriceImpactParams, TInitializePositionAndAddLiquidityParams, TInitializePositionAndAddLiquidityParamsByStrategy, TQuoteCreatePositionParams, TokenReserve, autoFillXByStrategy, autoFillXByWeight, autoFillYByStrategy, autoFillYByWeight, binIdToBinArrayIndex, calculateBidAskDistribution, calculateNormalDistribution, calculateSpotDistribution, chunkedFetchMultipleBinArrayBitmapExtensionAccount, chunkedFetchMultiplePoolAccount, chunkedGetMultipleAccountInfos, chunks, computeFee, computeFeeFromAmount, computeProtocolFee, DLMM as default, deriveBinArray, deriveBinArrayBitmapExtension, deriveCustomizablePermissionlessLbPair, deriveLbPair, deriveLbPair2, deriveOracle, derivePermissionLbPair, derivePosition, derivePresetParameter, derivePresetParameter2, deriveReserve, enumerateBins, findNextBinArrayIndexWithLiquidity, findNextBinArrayWithLiquidity, fromWeightDistributionToAmount, fromWeightDistributionToAmountOneSide, getBaseFee, getBinArrayLowerUpperBinId, getBinArraysRequiredByPositionRange, getBinFromBinArray, getEstimatedComputeUnitIxWithBuffer, getEstimatedComputeUnitUsageWithBuffer, getOrCreateATAInstruction, getOutAmount, getPriceOfBinByBinId, getTokenBalance, getTokenDecimals, getTokensMintFromPoolAddress, getTotalFee, getVariableFee, isBinIdWithinBinArray, isOverflowDefaultBinArrayBitmap, parseLogs, range, sParameters, swapExactInQuoteAtBin, swapExactOutQuoteAtBin, toAmountAskSide, toAmountBidSide, toAmountBothSide, toAmountsBothSideByStrategy, toStrategyParameters, toWeightDistribution, unwrapSOLInstruction, vParameters, wrapSOLInstruction };