@meteora-ag/dlmm 1.3.13 → 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.5";
8
+ "version": "0.8.6";
9
9
  "name": "lb_clmm";
10
10
  "constants": [
11
11
  {
@@ -118,6 +118,11 @@ type LbClmm = {
118
118
  "type": "u128";
119
119
  "value": "100_000";
120
120
  },
121
+ {
122
+ "name": "MINIMUM_LIQUIDITY";
123
+ "type": "u128";
124
+ "value": "1_000_000";
125
+ },
121
126
  {
122
127
  "name": "BIN_ARRAY";
123
128
  "type": "bytes";
@@ -2651,6 +2656,27 @@ type LbClmm = {
2651
2656
  "type": "publicKey";
2652
2657
  }
2653
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
+ ];
2654
2680
  }
2655
2681
  ];
2656
2682
  "accounts": [
@@ -2842,9 +2868,9 @@ type LbClmm = {
2842
2868
  "type": "u8";
2843
2869
  },
2844
2870
  {
2845
- "name": "padding0";
2871
+ "name": "creatorPoolOnOffControl";
2846
2872
  "docs": [
2847
- "padding 0"
2873
+ "Allow pool creator to enable/disable pool with restricted validation. Only applicable for customizable permissionless pair type."
2848
2874
  ];
2849
2875
  "type": "u8";
2850
2876
  },
@@ -3922,6 +3948,13 @@ type LbClmm = {
3922
3948
  "option": "u64";
3923
3949
  };
3924
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
+ },
3925
3958
  {
3926
3959
  "name": "padding";
3927
3960
  "docs": [
@@ -3930,7 +3963,7 @@ type LbClmm = {
3930
3963
  "type": {
3931
3964
  "array": [
3932
3965
  "u8",
3933
- 64
3966
+ 63
3934
3967
  ];
3935
3968
  };
3936
3969
  }
@@ -5381,6 +5414,16 @@ type LbClmm = {
5381
5414
  "code": 6066;
5382
5415
  "name": "InvalidStatus";
5383
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";
5384
5427
  }
5385
5428
  ];
5386
5429
  };
@@ -5782,13 +5825,22 @@ declare class DLMM {
5782
5825
  getLbPairLockInfo(lockDurationOpt?: number): Promise<PairLockInfo>;
5783
5826
  /** Public methods */
5784
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>;
5785
- 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>;
5786
5829
  static createLbPair(connection: Connection, funder: PublicKey, tokenX: PublicKey, tokenY: PublicKey, binStep: BN, baseFactor: BN, presetParameter: PublicKey, activeId: BN, opt?: Opt): Promise<Transaction>;
5787
5830
  /**
5788
5831
  * The function `refetchStates` retrieves and updates various states and data related to bin arrays
5789
5832
  * and lb pairs.
5790
5833
  */
5791
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>;
5792
5844
  /**
5793
5845
  * The function `getBinArrays` returns an array of `BinArrayAccount` objects
5794
5846
  * @returns a Promise that resolves to an array of BinArrayAccount objects.
@@ -6031,6 +6083,7 @@ declare class DLMM {
6031
6083
  * - `outAmount`: Amount of lamport to swap out
6032
6084
  * - `swapForY`: Swap token X to Y when it is true, else reversed.
6033
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
6034
6087
  * @returns {SwapQuote}
6035
6088
  * - `inAmount`: Amount of lamport to swap in
6036
6089
  * - `outAmount`: Amount of lamport to swap out
@@ -6041,7 +6094,7 @@ declare class DLMM {
6041
6094
  * @throws {DlmmSdkError}
6042
6095
  *
6043
6096
  */
6044
- swapQuoteExactOut(outAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[]): SwapQuoteExactOut;
6097
+ swapQuoteExactOut(outAmount: BN, swapForY: boolean, allowedSlippage: BN, binArrays: BinArrayAccount[], maxExtraBinArrays?: number): SwapQuoteExactOut;
6045
6098
  /**
6046
6099
  * The `swapQuote` function returns a quote for a swap
6047
6100
  * @param
@@ -6050,6 +6103,7 @@ declare class DLMM {
6050
6103
  * - `allowedSlippage`: Allowed slippage for the swap. Expressed in BPS. To convert from slippage percentage to BPS unit: SLIPPAGE_PERCENTAGE * 100
6051
6104
  * - `binArrays`: binArrays for swapQuote.
6052
6105
  * - `isPartialFill`: Flag to check whether the the swapQuote is partial fill, default = false.
6106
+ * - `maxExtraBinArrays`: Maximum number of extra binArrays to return
6053
6107
  * @returns {SwapQuote}
6054
6108
  * - `consumedInAmount`: Amount of lamport to swap in
6055
6109
  * - `outAmount`: Amount of lamport to swap out
@@ -6060,7 +6114,7 @@ declare class DLMM {
6060
6114
  * - `binArraysPubkey`: Array of bin arrays involved in the swap
6061
6115
  * @throws {DlmmSdkError}
6062
6116
  */
6063
- 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;
6064
6118
  swapExactOut({ inToken, outToken, outAmount, maxInAmount, lbPair, user, binArraysPubkey, }: SwapExactOutParams): Promise<Transaction>;
6065
6119
  /**
6066
6120
  * Returns a transaction to be signed and sent by user performing swap.
@@ -6515,7 +6569,7 @@ declare function chunkedFetchMultiplePoolAccount(program: ClmmProgram, pks: Publ
6515
6569
  requireBaseFactorSeed: number;
6516
6570
  baseFactorSeed: number[];
6517
6571
  activationType: number;
6518
- padding0: number;
6572
+ creatorPoolOnOffControl: number;
6519
6573
  tokenXMint: PublicKey;
6520
6574
  tokenYMint: PublicKey;
6521
6575
  reserveX: PublicKey;
@@ -6588,7 +6642,7 @@ declare class DLMMError extends Error {
6588
6642
  errorMessage: string;
6589
6643
  constructor(error: object | Codes);
6590
6644
  }
6591
- type ErrorName = "SWAP_QUOTE_INSUFFICIENT_LIQUIDITY";
6645
+ type ErrorName = "SWAP_QUOTE_INSUFFICIENT_LIQUIDITY" | "INVALID_MAX_EXTRA_BIN_ARRAYS";
6592
6646
  declare class DlmmSdkError extends Error {
6593
6647
  name: ErrorName;
6594
6648
  message: string;
@@ -6628,5 +6682,6 @@ declare const MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX = 26;
6628
6682
  declare const MAX_BIN_PER_TX = 69;
6629
6683
  declare const MAX_ACTIVE_BIN_SLIPPAGE = 3;
6630
6684
  declare const ILM_BASE: PublicKey;
6685
+ declare const MAX_EXTRA_BIN_ARRAYS = 3;
6631
6686
 
6632
- 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, 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 };
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 };
package/dist/index.js CHANGED
@@ -25,7 +25,7 @@ var _decimaljs = require('decimal.js'); var _decimaljs2 = _interopRequireDefault
25
25
 
26
26
  // src/dlmm/idl.ts
27
27
  var IDL = {
28
- "version": "0.8.5",
28
+ "version": "0.8.6",
29
29
  "name": "lb_clmm",
30
30
  "constants": [
31
31
  {
@@ -138,6 +138,11 @@ var IDL = {
138
138
  "type": "u128",
139
139
  "value": "100_000"
140
140
  },
141
+ {
142
+ "name": "MINIMUM_LIQUIDITY",
143
+ "type": "u128",
144
+ "value": "1_000_000"
145
+ },
141
146
  {
142
147
  "name": "BIN_ARRAY",
143
148
  "type": "bytes",
@@ -2671,6 +2676,27 @@ var IDL = {
2671
2676
  "type": "publicKey"
2672
2677
  }
2673
2678
  ]
2679
+ },
2680
+ {
2681
+ "name": "setPairStatusPermissionless",
2682
+ "accounts": [
2683
+ {
2684
+ "name": "lbPair",
2685
+ "isMut": true,
2686
+ "isSigner": false
2687
+ },
2688
+ {
2689
+ "name": "creator",
2690
+ "isMut": false,
2691
+ "isSigner": true
2692
+ }
2693
+ ],
2694
+ "args": [
2695
+ {
2696
+ "name": "status",
2697
+ "type": "u8"
2698
+ }
2699
+ ]
2674
2700
  }
2675
2701
  ],
2676
2702
  "accounts": [
@@ -2862,9 +2888,9 @@ var IDL = {
2862
2888
  "type": "u8"
2863
2889
  },
2864
2890
  {
2865
- "name": "padding0",
2891
+ "name": "creatorPoolOnOffControl",
2866
2892
  "docs": [
2867
- "padding 0"
2893
+ "Allow pool creator to enable/disable pool with restricted validation. Only applicable for customizable permissionless pair type."
2868
2894
  ],
2869
2895
  "type": "u8"
2870
2896
  },
@@ -3942,6 +3968,13 @@ var IDL = {
3942
3968
  "option": "u64"
3943
3969
  }
3944
3970
  },
3971
+ {
3972
+ "name": "creatorPoolOnOffControl",
3973
+ "docs": [
3974
+ "Pool creator have permission to enable/disable pool with restricted program validation. Only applicable for customizable permissionless pool."
3975
+ ],
3976
+ "type": "bool"
3977
+ },
3945
3978
  {
3946
3979
  "name": "padding",
3947
3980
  "docs": [
@@ -3950,7 +3983,7 @@ var IDL = {
3950
3983
  "type": {
3951
3984
  "array": [
3952
3985
  "u8",
3953
- 64
3986
+ 63
3954
3987
  ]
3955
3988
  }
3956
3989
  }
@@ -5401,6 +5434,16 @@ var IDL = {
5401
5434
  "code": 6066,
5402
5435
  "name": "InvalidStatus",
5403
5436
  "msg": "Invalid status"
5437
+ },
5438
+ {
5439
+ "code": 6067,
5440
+ "name": "ExceededMaxOracleLength",
5441
+ "msg": "Exceed max oracle length"
5442
+ },
5443
+ {
5444
+ "code": 6068,
5445
+ "name": "InvalidMinimumLiquidity",
5446
+ "msg": "Invalid minimum liquidity"
5404
5447
  }
5405
5448
  ]
5406
5449
  };
@@ -5454,6 +5497,7 @@ var MAX_ACTIVE_BIN_SLIPPAGE = 3;
5454
5497
  var ILM_BASE = new (0, _web3js.PublicKey)(
5455
5498
  "MFGQxwAmB91SwuYX36okv2Qmdc9aMuHTwWGUrp4AtB1"
5456
5499
  );
5500
+ var MAX_EXTRA_BIN_ARRAYS = 3;
5457
5501
 
5458
5502
  // src/dlmm/error.ts
5459
5503
 
@@ -8506,7 +8550,7 @@ var DLMM = class {
8506
8550
  base: baseKey
8507
8551
  }).transaction();
8508
8552
  }
8509
- static async createCustomizablePermissionlessLbPair(connection, binStep, tokenX, tokenY, activeId, feeBps, activationType, hasAlphaVault, creatorKey, activationPoint, opt) {
8553
+ static async createCustomizablePermissionlessLbPair(connection, binStep, tokenX, tokenY, activeId, feeBps, activationType, hasAlphaVault, creatorKey, activationPoint, creatorPoolOnOffControl, opt) {
8510
8554
  const provider = new (0, _anchor.AnchorProvider)(
8511
8555
  connection,
8512
8556
  {},
@@ -8536,7 +8580,8 @@ var DLMM = class {
8536
8580
  activationType,
8537
8581
  activationPoint: activationPoint ? activationPoint : null,
8538
8582
  hasAlphaVault,
8539
- padding: Array(64).fill(0)
8583
+ creatorPoolOnOffControl: creatorPoolOnOffControl ? creatorPoolOnOffControl : false,
8584
+ padding: Array(63).fill(0)
8540
8585
  };
8541
8586
  const userTokenX = _spltoken.getAssociatedTokenAddressSync.call(void 0, tokenX, creatorKey);
8542
8587
  const userTokenY = _spltoken.getAssociatedTokenAddressSync.call(void 0, tokenY, creatorKey);
@@ -8667,6 +8712,26 @@ var DLMM = class {
8667
8712
  };
8668
8713
  this.lbPair = lbPairState;
8669
8714
  }
8715
+ /**
8716
+ * 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`.
8717
+ * 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.
8718
+ * Useful for token launches which do not have fixed activation time.
8719
+ * @param enable If true, the pair will be enabled. If false, the pair will be disabled.
8720
+ * @param creator The public key of the pool creator.
8721
+ * @returns a Promise that resolves to the transaction.
8722
+ */
8723
+ async setPairStatusPermissionless(enable, creator) {
8724
+ const tx = await this.program.methods.setPairStatusPermissionless(Number(enable)).accounts({
8725
+ lbPair: this.pubkey,
8726
+ creator
8727
+ }).transaction();
8728
+ const { blockhash, lastValidBlockHeight } = await this.program.provider.connection.getLatestBlockhash("confirmed");
8729
+ return new (0, _web3js.Transaction)({
8730
+ feePayer: this.lbPair.creator,
8731
+ blockhash,
8732
+ lastValidBlockHeight
8733
+ }).add(tx);
8734
+ }
8670
8735
  /**
8671
8736
  * The function `getBinArrays` returns an array of `BinArrayAccount` objects
8672
8737
  * @returns a Promise that resolves to an array of BinArrayAccount objects.
@@ -10153,6 +10218,7 @@ var DLMM = class {
10153
10218
  * - `outAmount`: Amount of lamport to swap out
10154
10219
  * - `swapForY`: Swap token X to Y when it is true, else reversed.
10155
10220
  * - `allowedSlippage`: Allowed slippage for the swap. Expressed in BPS. To convert from slippage percentage to BPS unit: SLIPPAGE_PERCENTAGE * 100
10221
+ * - `maxExtraBinArrays`: Maximum number of extra binArrays to return
10156
10222
  * @returns {SwapQuote}
10157
10223
  * - `inAmount`: Amount of lamport to swap in
10158
10224
  * - `outAmount`: Amount of lamport to swap out
@@ -10163,9 +10229,12 @@ var DLMM = class {
10163
10229
  * @throws {DlmmSdkError}
10164
10230
  *
10165
10231
  */
10166
- swapQuoteExactOut(outAmount, swapForY, allowedSlippage, binArrays) {
10232
+ swapQuoteExactOut(outAmount, swapForY, allowedSlippage, binArrays, maxExtraBinArrays = 0) {
10167
10233
  const currentTimestamp = Date.now() / 1e3;
10168
10234
  let outAmountLeft = outAmount;
10235
+ if (maxExtraBinArrays < 0 || maxExtraBinArrays > MAX_EXTRA_BIN_ARRAYS) {
10236
+ throw new DlmmSdkError("INVALID_MAX_EXTRA_BIN_ARRAYS", `maxExtraBinArrays must be a value between 0 and ${MAX_EXTRA_BIN_ARRAYS}`);
10237
+ }
10169
10238
  let vParameterClone = Object.assign({}, this.lbPair.vParameters);
10170
10239
  let activeId = new (0, _anchor.BN)(this.lbPair.activeId);
10171
10240
  const binStep = this.lbPair.binStep;
@@ -10239,6 +10308,41 @@ var DLMM = class {
10239
10308
  );
10240
10309
  const priceImpact = startPrice.sub(endPrice).abs().div(startPrice).mul(new (0, _decimaljs2.default)(100));
10241
10310
  const maxInAmount = actualInAmount.mul(new (0, _anchor.BN)(BASIS_POINT_MAX).add(allowedSlippage)).div(new (0, _anchor.BN)(BASIS_POINT_MAX));
10311
+ if (maxExtraBinArrays > 0 && maxExtraBinArrays <= MAX_EXTRA_BIN_ARRAYS) {
10312
+ const extraBinArrays = new Array();
10313
+ while (extraBinArrays.length < maxExtraBinArrays) {
10314
+ let binArrayAccountToSwap = findNextBinArrayWithLiquidity(
10315
+ swapForY,
10316
+ activeId,
10317
+ this.lbPair,
10318
+ _nullishCoalesce(_optionalChain([this, 'access', _71 => _71.binArrayBitmapExtension, 'optionalAccess', _72 => _72.account]), () => ( null)),
10319
+ binArrays
10320
+ );
10321
+ if (binArrayAccountToSwap == null) {
10322
+ break;
10323
+ }
10324
+ const binArrayAccountToSwapExisted = binArraysForSwap.has(binArrayAccountToSwap.publicKey);
10325
+ if (binArrayAccountToSwapExisted) {
10326
+ if (swapForY) {
10327
+ activeId = activeId.sub(new (0, _anchor.BN)(1));
10328
+ } else {
10329
+ activeId = activeId.add(new (0, _anchor.BN)(1));
10330
+ }
10331
+ } else {
10332
+ extraBinArrays.push(binArrayAccountToSwap.publicKey);
10333
+ const [lowerBinId, upperBinId] = getBinArrayLowerUpperBinId(binArrayAccountToSwap.account.index);
10334
+ if (swapForY) {
10335
+ activeId = lowerBinId.sub(new (0, _anchor.BN)(1));
10336
+ } else {
10337
+ activeId = upperBinId.add(new (0, _anchor.BN)(1));
10338
+ }
10339
+ }
10340
+ }
10341
+ extraBinArrays.forEach((binArrayPubkey) => {
10342
+ binArraysForSwap.set(binArrayPubkey, true);
10343
+ });
10344
+ }
10345
+ const binArraysPubkey = Array.from(binArraysForSwap.keys());
10242
10346
  return {
10243
10347
  inAmount: actualInAmount,
10244
10348
  maxInAmount,
@@ -10246,7 +10350,7 @@ var DLMM = class {
10246
10350
  priceImpact,
10247
10351
  fee: feeAmount,
10248
10352
  protocolFee: protocolFeeAmount,
10249
- binArraysPubkey: [...binArraysForSwap.keys()]
10353
+ binArraysPubkey
10250
10354
  };
10251
10355
  }
10252
10356
  /**
@@ -10257,6 +10361,7 @@ var DLMM = class {
10257
10361
  * - `allowedSlippage`: Allowed slippage for the swap. Expressed in BPS. To convert from slippage percentage to BPS unit: SLIPPAGE_PERCENTAGE * 100
10258
10362
  * - `binArrays`: binArrays for swapQuote.
10259
10363
  * - `isPartialFill`: Flag to check whether the the swapQuote is partial fill, default = false.
10364
+ * - `maxExtraBinArrays`: Maximum number of extra binArrays to return
10260
10365
  * @returns {SwapQuote}
10261
10366
  * - `consumedInAmount`: Amount of lamport to swap in
10262
10367
  * - `outAmount`: Amount of lamport to swap out
@@ -10267,9 +10372,12 @@ var DLMM = class {
10267
10372
  * - `binArraysPubkey`: Array of bin arrays involved in the swap
10268
10373
  * @throws {DlmmSdkError}
10269
10374
  */
10270
- swapQuote(inAmount, swapForY, allowedSlippage, binArrays, isPartialFill) {
10375
+ swapQuote(inAmount, swapForY, allowedSlippage, binArrays, isPartialFill, maxExtraBinArrays = 0) {
10271
10376
  const currentTimestamp = Date.now() / 1e3;
10272
10377
  let inAmountLeft = inAmount;
10378
+ if (maxExtraBinArrays < 0 || maxExtraBinArrays > MAX_EXTRA_BIN_ARRAYS) {
10379
+ throw new DlmmSdkError("INVALID_MAX_EXTRA_BIN_ARRAYS", `maxExtraBinArrays must be a value between 0 and ${MAX_EXTRA_BIN_ARRAYS}`);
10380
+ }
10273
10381
  let vParameterClone = Object.assign({}, this.lbPair.vParameters);
10274
10382
  let activeId = new (0, _anchor.BN)(this.lbPair.activeId);
10275
10383
  const binStep = this.lbPair.binStep;
@@ -10291,7 +10399,7 @@ var DLMM = class {
10291
10399
  swapForY,
10292
10400
  activeId,
10293
10401
  this.lbPair,
10294
- _nullishCoalesce(_optionalChain([this, 'access', _71 => _71.binArrayBitmapExtension, 'optionalAccess', _72 => _72.account]), () => ( null)),
10402
+ _nullishCoalesce(_optionalChain([this, 'access', _73 => _73.binArrayBitmapExtension, 'optionalAccess', _74 => _74.account]), () => ( null)),
10295
10403
  binArrays
10296
10404
  );
10297
10405
  if (binArrayAccountToSwap == null) {
@@ -10362,6 +10470,41 @@ var DLMM = class {
10362
10470
  lastFilledActiveBinId.toNumber(),
10363
10471
  this.lbPair.binStep
10364
10472
  );
10473
+ if (maxExtraBinArrays > 0 && maxExtraBinArrays <= MAX_EXTRA_BIN_ARRAYS) {
10474
+ const extraBinArrays = new Array();
10475
+ while (extraBinArrays.length < maxExtraBinArrays) {
10476
+ let binArrayAccountToSwap = findNextBinArrayWithLiquidity(
10477
+ swapForY,
10478
+ activeId,
10479
+ this.lbPair,
10480
+ _nullishCoalesce(_optionalChain([this, 'access', _75 => _75.binArrayBitmapExtension, 'optionalAccess', _76 => _76.account]), () => ( null)),
10481
+ binArrays
10482
+ );
10483
+ if (binArrayAccountToSwap == null) {
10484
+ break;
10485
+ }
10486
+ const binArrayAccountToSwapExisted = binArraysForSwap.has(binArrayAccountToSwap.publicKey);
10487
+ if (binArrayAccountToSwapExisted) {
10488
+ if (swapForY) {
10489
+ activeId = activeId.sub(new (0, _anchor.BN)(1));
10490
+ } else {
10491
+ activeId = activeId.add(new (0, _anchor.BN)(1));
10492
+ }
10493
+ } else {
10494
+ extraBinArrays.push(binArrayAccountToSwap.publicKey);
10495
+ const [lowerBinId, upperBinId] = getBinArrayLowerUpperBinId(binArrayAccountToSwap.account.index);
10496
+ if (swapForY) {
10497
+ activeId = lowerBinId.sub(new (0, _anchor.BN)(1));
10498
+ } else {
10499
+ activeId = upperBinId.add(new (0, _anchor.BN)(1));
10500
+ }
10501
+ }
10502
+ }
10503
+ extraBinArrays.forEach((binArrayPubkey) => {
10504
+ binArraysForSwap.set(binArrayPubkey, true);
10505
+ });
10506
+ }
10507
+ const binArraysPubkey = Array.from(binArraysForSwap.keys());
10365
10508
  return {
10366
10509
  consumedInAmount: inAmount,
10367
10510
  outAmount: actualOutAmount,
@@ -10369,7 +10512,7 @@ var DLMM = class {
10369
10512
  protocolFee: protocolFeeAmount,
10370
10513
  minOutAmount,
10371
10514
  priceImpact,
10372
- binArraysPubkey: [...binArraysForSwap.keys()],
10515
+ binArraysPubkey,
10373
10516
  endPrice
10374
10517
  };
10375
10518
  }
@@ -11485,7 +11628,7 @@ var DLMM = class {
11485
11628
  swapForY,
11486
11629
  new (0, _anchor.BN)(activeBinId),
11487
11630
  this.lbPair,
11488
- _nullishCoalesce(_optionalChain([this, 'access', _73 => _73.binArrayBitmapExtension, 'optionalAccess', _74 => _74.account]), () => ( null))
11631
+ _nullishCoalesce(_optionalChain([this, 'access', _77 => _77.binArrayBitmapExtension, 'optionalAccess', _78 => _78.account]), () => ( null))
11489
11632
  );
11490
11633
  if (toBinArrayIndex === null)
11491
11634
  return true;
@@ -11522,7 +11665,7 @@ var DLMM = class {
11522
11665
  swapForY,
11523
11666
  new (0, _anchor.BN)(activeBinId),
11524
11667
  this.lbPair,
11525
- _nullishCoalesce(_optionalChain([this, 'access', _75 => _75.binArrayBitmapExtension, 'optionalAccess', _76 => _76.account]), () => ( null))
11668
+ _nullishCoalesce(_optionalChain([this, 'access', _79 => _79.binArrayBitmapExtension, 'optionalAccess', _80 => _80.account]), () => ( null))
11526
11669
  );
11527
11670
  const accountsToFetch = [];
11528
11671
  const [binArrayBitMapExtensionPubkey] = deriveBinArrayBitmapExtension(
@@ -11553,13 +11696,13 @@ var DLMM = class {
11553
11696
  let fromBinArray = null;
11554
11697
  let toBinArray = null;
11555
11698
  let binArrayBitmapExtension = null;
11556
- if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _77 => _77[0]])) {
11699
+ if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _81 => _81[0]])) {
11557
11700
  binArrayBitmapExtension = binArrayBitMapExtensionPubkey;
11558
11701
  }
11559
- if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _78 => _78[1]])) {
11702
+ if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _82 => _82[1]])) {
11560
11703
  fromBinArray = fromBinArrayPubkey;
11561
11704
  }
11562
- if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _79 => _79[2]]) && !!toBinArrayIndex) {
11705
+ if (!!_optionalChain([binArrayAccounts, 'optionalAccess', _83 => _83[2]]) && !!toBinArrayIndex) {
11563
11706
  toBinArray = toBinArrayPubkey;
11564
11707
  }
11565
11708
  const { blockhash, lastValidBlockHeight } = await this.program.provider.connection.getLatestBlockhash("confirmed");
@@ -12035,7 +12178,7 @@ var DLMM = class {
12035
12178
  const [lowerBinId2] = getBinArrayLowerUpperBinId(index);
12036
12179
  return bins.map((b, i) => [lowerBinId2.toNumber() + i, b]);
12037
12180
  }));
12038
- const version = _nullishCoalesce(_optionalChain([binArrays, 'access', _80 => _80.find, 'call', _81 => _81((binArray) => binArray != null), 'optionalAccess', _82 => _82.version]), () => ( 1));
12181
+ const version = _nullishCoalesce(_optionalChain([binArrays, 'access', _84 => _84.find, 'call', _85 => _85((binArray) => binArray != null), 'optionalAccess', _86 => _86.version]), () => ( 1));
12039
12182
  return Array.from(enumerateBins(
12040
12183
  binsById,
12041
12184
  lowerBinId,
@@ -12328,5 +12471,6 @@ var src_default = DLMM;
12328
12471
 
12329
12472
 
12330
12473
 
12331
- exports.ADMIN = ADMIN; exports.ActivationType = ActivationType; exports.BASIS_POINT_MAX = BASIS_POINT_MAX; exports.BIN_ARRAY_BITMAP_SIZE = BIN_ARRAY_BITMAP_SIZE; exports.BIN_ARRAY_FEE = BIN_ARRAY_FEE; exports.BinLiquidity = BinLiquidity; exports.BitmapType = BitmapType; exports.ClockLayout = ClockLayout; exports.DLMMError = DLMMError; exports.DlmmSdkError = DlmmSdkError; exports.EXTENSION_BINARRAY_BITMAP_SIZE = EXTENSION_BINARRAY_BITMAP_SIZE; exports.FEE_PRECISION = FEE_PRECISION; exports.IDL = IDL; exports.ILM_BASE = ILM_BASE; exports.LBCLMM_PROGRAM_IDS = LBCLMM_PROGRAM_IDS; exports.MAX_ACTIVE_BIN_SLIPPAGE = MAX_ACTIVE_BIN_SLIPPAGE; exports.MAX_BIN_ARRAY_SIZE = MAX_BIN_ARRAY_SIZE; exports.MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX = MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX; exports.MAX_BIN_PER_POSITION = MAX_BIN_PER_POSITION; exports.MAX_BIN_PER_TX = MAX_BIN_PER_TX; exports.MAX_CLAIM_ALL_ALLOWED = MAX_CLAIM_ALL_ALLOWED; exports.MAX_FEE_RATE = MAX_FEE_RATE; exports.Network = Network; exports.POSITION_FEE = POSITION_FEE; exports.PRECISION = PRECISION; exports.PairStatus = PairStatus; exports.PairType = PairType; exports.PositionVersion = PositionVersion; exports.SCALE = SCALE; exports.SCALE_OFFSET = SCALE_OFFSET; exports.SIMULATION_USER = SIMULATION_USER; exports.Strategy = Strategy; exports.StrategyType = StrategyType; exports.autoFillXByStrategy = autoFillXByStrategy; exports.autoFillXByWeight = autoFillXByWeight; exports.autoFillYByStrategy = autoFillYByStrategy; exports.autoFillYByWeight = autoFillYByWeight; exports.binIdToBinArrayIndex = binIdToBinArrayIndex; exports.calculateBidAskDistribution = calculateBidAskDistribution; exports.calculateNormalDistribution = calculateNormalDistribution; exports.calculateSpotDistribution = calculateSpotDistribution; exports.chunkedFetchMultipleBinArrayBitmapExtensionAccount = chunkedFetchMultipleBinArrayBitmapExtensionAccount; exports.chunkedFetchMultiplePoolAccount = chunkedFetchMultiplePoolAccount; exports.chunkedGetMultipleAccountInfos = chunkedGetMultipleAccountInfos; exports.chunks = chunks; exports.computeFee = computeFee; exports.computeFeeFromAmount = computeFeeFromAmount; exports.computeProtocolFee = computeProtocolFee; exports.default = src_default; exports.deriveBinArray = deriveBinArray; exports.deriveBinArrayBitmapExtension = deriveBinArrayBitmapExtension; exports.deriveCustomizablePermissionlessLbPair = deriveCustomizablePermissionlessLbPair; exports.deriveLbPair = deriveLbPair; exports.deriveLbPair2 = deriveLbPair2; exports.deriveOracle = deriveOracle; exports.derivePermissionLbPair = derivePermissionLbPair; exports.derivePosition = derivePosition; exports.derivePresetParameter = derivePresetParameter; exports.derivePresetParameter2 = derivePresetParameter2; exports.deriveReserve = deriveReserve; exports.enumerateBins = enumerateBins; exports.findNextBinArrayIndexWithLiquidity = findNextBinArrayIndexWithLiquidity; exports.findNextBinArrayWithLiquidity = findNextBinArrayWithLiquidity; exports.fromWeightDistributionToAmount = fromWeightDistributionToAmount; exports.fromWeightDistributionToAmountOneSide = fromWeightDistributionToAmountOneSide; exports.getBaseFee = getBaseFee; exports.getBinArrayLowerUpperBinId = getBinArrayLowerUpperBinId; exports.getBinArraysRequiredByPositionRange = getBinArraysRequiredByPositionRange; exports.getBinFromBinArray = getBinFromBinArray; exports.getEstimatedComputeUnitIxWithBuffer = getEstimatedComputeUnitIxWithBuffer; exports.getEstimatedComputeUnitUsageWithBuffer = getEstimatedComputeUnitUsageWithBuffer; exports.getOrCreateATAInstruction = getOrCreateATAInstruction; exports.getOutAmount = getOutAmount; exports.getPriceOfBinByBinId = getPriceOfBinByBinId; exports.getTokenBalance = getTokenBalance; exports.getTokenDecimals = getTokenDecimals; exports.getTokensMintFromPoolAddress = getTokensMintFromPoolAddress; exports.getTotalFee = getTotalFee; exports.getVariableFee = getVariableFee; exports.isBinIdWithinBinArray = isBinIdWithinBinArray; exports.isOverflowDefaultBinArrayBitmap = isOverflowDefaultBinArrayBitmap; exports.parseLogs = parseLogs; exports.range = range; exports.swapExactInQuoteAtBin = swapExactInQuoteAtBin; exports.swapExactOutQuoteAtBin = swapExactOutQuoteAtBin; exports.toAmountAskSide = toAmountAskSide; exports.toAmountBidSide = toAmountBidSide; exports.toAmountBothSide = toAmountBothSide; exports.toAmountsBothSideByStrategy = toAmountsBothSideByStrategy; exports.toStrategyParameters = toStrategyParameters; exports.toWeightDistribution = toWeightDistribution; exports.unwrapSOLInstruction = unwrapSOLInstruction; exports.wrapSOLInstruction = wrapSOLInstruction;
12474
+
12475
+ exports.ADMIN = ADMIN; exports.ActivationType = ActivationType; exports.BASIS_POINT_MAX = BASIS_POINT_MAX; exports.BIN_ARRAY_BITMAP_SIZE = BIN_ARRAY_BITMAP_SIZE; exports.BIN_ARRAY_FEE = BIN_ARRAY_FEE; exports.BinLiquidity = BinLiquidity; exports.BitmapType = BitmapType; exports.ClockLayout = ClockLayout; exports.DLMMError = DLMMError; exports.DlmmSdkError = DlmmSdkError; exports.EXTENSION_BINARRAY_BITMAP_SIZE = EXTENSION_BINARRAY_BITMAP_SIZE; exports.FEE_PRECISION = FEE_PRECISION; exports.IDL = IDL; exports.ILM_BASE = ILM_BASE; exports.LBCLMM_PROGRAM_IDS = LBCLMM_PROGRAM_IDS; exports.MAX_ACTIVE_BIN_SLIPPAGE = MAX_ACTIVE_BIN_SLIPPAGE; exports.MAX_BIN_ARRAY_SIZE = MAX_BIN_ARRAY_SIZE; exports.MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX = MAX_BIN_LENGTH_ALLOWED_IN_ONE_TX; exports.MAX_BIN_PER_POSITION = MAX_BIN_PER_POSITION; exports.MAX_BIN_PER_TX = MAX_BIN_PER_TX; exports.MAX_CLAIM_ALL_ALLOWED = MAX_CLAIM_ALL_ALLOWED; exports.MAX_EXTRA_BIN_ARRAYS = MAX_EXTRA_BIN_ARRAYS; exports.MAX_FEE_RATE = MAX_FEE_RATE; exports.Network = Network; exports.POSITION_FEE = POSITION_FEE; exports.PRECISION = PRECISION; exports.PairStatus = PairStatus; exports.PairType = PairType; exports.PositionVersion = PositionVersion; exports.SCALE = SCALE; exports.SCALE_OFFSET = SCALE_OFFSET; exports.SIMULATION_USER = SIMULATION_USER; exports.Strategy = Strategy; exports.StrategyType = StrategyType; exports.autoFillXByStrategy = autoFillXByStrategy; exports.autoFillXByWeight = autoFillXByWeight; exports.autoFillYByStrategy = autoFillYByStrategy; exports.autoFillYByWeight = autoFillYByWeight; exports.binIdToBinArrayIndex = binIdToBinArrayIndex; exports.calculateBidAskDistribution = calculateBidAskDistribution; exports.calculateNormalDistribution = calculateNormalDistribution; exports.calculateSpotDistribution = calculateSpotDistribution; exports.chunkedFetchMultipleBinArrayBitmapExtensionAccount = chunkedFetchMultipleBinArrayBitmapExtensionAccount; exports.chunkedFetchMultiplePoolAccount = chunkedFetchMultiplePoolAccount; exports.chunkedGetMultipleAccountInfos = chunkedGetMultipleAccountInfos; exports.chunks = chunks; exports.computeFee = computeFee; exports.computeFeeFromAmount = computeFeeFromAmount; exports.computeProtocolFee = computeProtocolFee; exports.default = src_default; exports.deriveBinArray = deriveBinArray; exports.deriveBinArrayBitmapExtension = deriveBinArrayBitmapExtension; exports.deriveCustomizablePermissionlessLbPair = deriveCustomizablePermissionlessLbPair; exports.deriveLbPair = deriveLbPair; exports.deriveLbPair2 = deriveLbPair2; exports.deriveOracle = deriveOracle; exports.derivePermissionLbPair = derivePermissionLbPair; exports.derivePosition = derivePosition; exports.derivePresetParameter = derivePresetParameter; exports.derivePresetParameter2 = derivePresetParameter2; exports.deriveReserve = deriveReserve; exports.enumerateBins = enumerateBins; exports.findNextBinArrayIndexWithLiquidity = findNextBinArrayIndexWithLiquidity; exports.findNextBinArrayWithLiquidity = findNextBinArrayWithLiquidity; exports.fromWeightDistributionToAmount = fromWeightDistributionToAmount; exports.fromWeightDistributionToAmountOneSide = fromWeightDistributionToAmountOneSide; exports.getBaseFee = getBaseFee; exports.getBinArrayLowerUpperBinId = getBinArrayLowerUpperBinId; exports.getBinArraysRequiredByPositionRange = getBinArraysRequiredByPositionRange; exports.getBinFromBinArray = getBinFromBinArray; exports.getEstimatedComputeUnitIxWithBuffer = getEstimatedComputeUnitIxWithBuffer; exports.getEstimatedComputeUnitUsageWithBuffer = getEstimatedComputeUnitUsageWithBuffer; exports.getOrCreateATAInstruction = getOrCreateATAInstruction; exports.getOutAmount = getOutAmount; exports.getPriceOfBinByBinId = getPriceOfBinByBinId; exports.getTokenBalance = getTokenBalance; exports.getTokenDecimals = getTokenDecimals; exports.getTokensMintFromPoolAddress = getTokensMintFromPoolAddress; exports.getTotalFee = getTotalFee; exports.getVariableFee = getVariableFee; exports.isBinIdWithinBinArray = isBinIdWithinBinArray; exports.isOverflowDefaultBinArrayBitmap = isOverflowDefaultBinArrayBitmap; exports.parseLogs = parseLogs; exports.range = range; exports.swapExactInQuoteAtBin = swapExactInQuoteAtBin; exports.swapExactOutQuoteAtBin = swapExactOutQuoteAtBin; exports.toAmountAskSide = toAmountAskSide; exports.toAmountBidSide = toAmountBidSide; exports.toAmountBothSide = toAmountBothSide; exports.toAmountsBothSideByStrategy = toAmountsBothSideByStrategy; exports.toStrategyParameters = toStrategyParameters; exports.toWeightDistribution = toWeightDistribution; exports.unwrapSOLInstruction = unwrapSOLInstruction; exports.wrapSOLInstruction = wrapSOLInstruction;
12332
12476
  //# sourceMappingURL=index.js.map