@meteora-ag/zap-sdk 1.3.1 → 1.3.2

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.mts CHANGED
@@ -2231,7 +2231,7 @@ declare class Zap {
2231
2231
  zapOutThroughDlmm(params: ZapOutThroughDlmmParams): Promise<Transaction>;
2232
2232
  }
2233
2233
 
2234
- declare function getJupiterQuote(inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, dynamicSlippage: boolean | undefined, onlyDirectRoutes: boolean, restrictIntermediateTokens: boolean, config?: ZapConfig): Promise<JupiterQuoteResponse | null>;
2234
+ declare function getJupiterQuote(inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, dynamicSlippage: boolean | undefined, onlyDirectRoutes: boolean, restrictIntermediateTokens: boolean, forJitoBundle?: boolean, config?: ZapConfig): Promise<JupiterQuoteResponse | null>;
2235
2235
  declare function getJupiterSwapInstruction(userPublicKey: PublicKey, quoteResponse: any, config?: ZapConfig): Promise<JupiterSwapInstructionResponse>;
2236
2236
  declare function buildJupiterSwapTransaction(user: PublicKey, inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, jupiterQuoteResponse?: JupiterQuoteResponse, config?: ZapConfig): Promise<{
2237
2237
  transaction: Transaction;
package/dist/index.d.ts CHANGED
@@ -2231,7 +2231,7 @@ declare class Zap {
2231
2231
  zapOutThroughDlmm(params: ZapOutThroughDlmmParams): Promise<Transaction>;
2232
2232
  }
2233
2233
 
2234
- declare function getJupiterQuote(inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, dynamicSlippage: boolean | undefined, onlyDirectRoutes: boolean, restrictIntermediateTokens: boolean, config?: ZapConfig): Promise<JupiterQuoteResponse | null>;
2234
+ declare function getJupiterQuote(inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, dynamicSlippage: boolean | undefined, onlyDirectRoutes: boolean, restrictIntermediateTokens: boolean, forJitoBundle?: boolean, config?: ZapConfig): Promise<JupiterQuoteResponse | null>;
2235
2235
  declare function getJupiterSwapInstruction(userPublicKey: PublicKey, quoteResponse: any, config?: ZapConfig): Promise<JupiterSwapInstructionResponse>;
2236
2236
  declare function buildJupiterSwapTransaction(user: PublicKey, inputMint: PublicKey, outputMint: PublicKey, amount: BN, maxAccounts: number, slippageBps: number, jupiterQuoteResponse?: JupiterQuoteResponse, config?: ZapConfig): Promise<{
2237
2237
  transaction: Transaction;
package/dist/index.js CHANGED
@@ -1785,7 +1785,7 @@ var DEFAULT_JUPITER_API_URL = "https://api.jup.ag";
1785
1785
 
1786
1786
  // src/helpers/jupiter.ts
1787
1787
  function getJupiterQuote(_0, _1, _2, _3, _4) {
1788
- return __async(this, arguments, function* (inputMint, outputMint, amount, maxAccounts, slippageBps, dynamicSlippage = false, onlyDirectRoutes, restrictIntermediateTokens, config = {}) {
1788
+ return __async(this, arguments, function* (inputMint, outputMint, amount, maxAccounts, slippageBps, dynamicSlippage = false, onlyDirectRoutes, restrictIntermediateTokens, forJitoBundle = true, config = {}) {
1789
1789
  const params = new URLSearchParams({
1790
1790
  inputMint: inputMint.toString(),
1791
1791
  outputMint: outputMint.toString(),
@@ -1794,7 +1794,8 @@ function getJupiterQuote(_0, _1, _2, _3, _4) {
1794
1794
  maxAccounts: maxAccounts.toString(),
1795
1795
  onlyDirectRoutes: onlyDirectRoutes.toString(),
1796
1796
  restrictIntermediateTokens: restrictIntermediateTokens.toString(),
1797
- dynamicSlippage: dynamicSlippage.toString()
1797
+ dynamicSlippage: dynamicSlippage.toString(),
1798
+ forJitoBundle: forJitoBundle.toString()
1798
1799
  });
1799
1800
  const url = `${config.jupiterApiUrl || DEFAULT_JUPITER_API_URL}/swap/v1/quote?${params.toString()}`;
1800
1801
  try {
@@ -1855,6 +1856,7 @@ function buildJupiterSwapTransaction(_0, _1, _2, _3, _4, _5, _6) {
1855
1856
  false,
1856
1857
  true,
1857
1858
  true,
1859
+ true,
1858
1860
  config
1859
1861
  );
1860
1862
  if (!quoteResponse) {
@@ -2509,6 +2511,7 @@ function getBestSwapQuoteJupiterDlmm(_0, _1, _2, _3, _4, _5, _6) {
2509
2511
  false,
2510
2512
  true,
2511
2513
  true,
2514
+ true,
2512
2515
  config
2513
2516
  );
2514
2517
  const jupiterQuote = jupiterQuoteResult ? {
@@ -2665,6 +2668,7 @@ function estimateDlmmIndirectSwap(_0) {
2665
2668
  false,
2666
2669
  true,
2667
2670
  true,
2671
+ true,
2668
2672
  config
2669
2673
  );
2670
2674
  if (!quote) {
@@ -2695,6 +2699,7 @@ function estimateDlmmIndirectSwap(_0) {
2695
2699
  false,
2696
2700
  true,
2697
2701
  true,
2702
+ true,
2698
2703
  config
2699
2704
  ),
2700
2705
  getJupiterQuote(
@@ -2706,6 +2711,7 @@ function estimateDlmmIndirectSwap(_0) {
2706
2711
  false,
2707
2712
  true,
2708
2713
  true,
2714
+ true,
2709
2715
  config
2710
2716
  )
2711
2717
  ]);
@@ -2809,6 +2815,7 @@ function estimateDlmmIndirectSwap(_0) {
2809
2815
  false,
2810
2816
  true,
2811
2817
  true,
2818
+ true,
2812
2819
  config
2813
2820
  ),
2814
2821
  getJupiterQuote(
@@ -2820,6 +2827,7 @@ function estimateDlmmIndirectSwap(_0) {
2820
2827
  false,
2821
2828
  true,
2822
2829
  true,
2830
+ true,
2823
2831
  config
2824
2832
  )
2825
2833
  ]);
package/dist/index.mjs CHANGED
@@ -1713,7 +1713,7 @@ var DEFAULT_JUPITER_API_URL = "https://api.jup.ag";
1713
1713
 
1714
1714
  // src/helpers/jupiter.ts
1715
1715
  function getJupiterQuote(_0, _1, _2, _3, _4) {
1716
- return __async(this, arguments, function* (inputMint, outputMint, amount, maxAccounts, slippageBps, dynamicSlippage = false, onlyDirectRoutes, restrictIntermediateTokens, config = {}) {
1716
+ return __async(this, arguments, function* (inputMint, outputMint, amount, maxAccounts, slippageBps, dynamicSlippage = false, onlyDirectRoutes, restrictIntermediateTokens, forJitoBundle = true, config = {}) {
1717
1717
  const params = new URLSearchParams({
1718
1718
  inputMint: inputMint.toString(),
1719
1719
  outputMint: outputMint.toString(),
@@ -1722,7 +1722,8 @@ function getJupiterQuote(_0, _1, _2, _3, _4) {
1722
1722
  maxAccounts: maxAccounts.toString(),
1723
1723
  onlyDirectRoutes: onlyDirectRoutes.toString(),
1724
1724
  restrictIntermediateTokens: restrictIntermediateTokens.toString(),
1725
- dynamicSlippage: dynamicSlippage.toString()
1725
+ dynamicSlippage: dynamicSlippage.toString(),
1726
+ forJitoBundle: forJitoBundle.toString()
1726
1727
  });
1727
1728
  const url = `${config.jupiterApiUrl || DEFAULT_JUPITER_API_URL}/swap/v1/quote?${params.toString()}`;
1728
1729
  try {
@@ -1783,6 +1784,7 @@ function buildJupiterSwapTransaction(_0, _1, _2, _3, _4, _5, _6) {
1783
1784
  false,
1784
1785
  true,
1785
1786
  true,
1787
+ true,
1786
1788
  config
1787
1789
  );
1788
1790
  if (!quoteResponse) {
@@ -2469,6 +2471,7 @@ function getBestSwapQuoteJupiterDlmm(_0, _1, _2, _3, _4, _5, _6) {
2469
2471
  false,
2470
2472
  true,
2471
2473
  true,
2474
+ true,
2472
2475
  config
2473
2476
  );
2474
2477
  const jupiterQuote = jupiterQuoteResult ? {
@@ -2625,6 +2628,7 @@ function estimateDlmmIndirectSwap(_0) {
2625
2628
  false,
2626
2629
  true,
2627
2630
  true,
2631
+ true,
2628
2632
  config
2629
2633
  );
2630
2634
  if (!quote) {
@@ -2655,6 +2659,7 @@ function estimateDlmmIndirectSwap(_0) {
2655
2659
  false,
2656
2660
  true,
2657
2661
  true,
2662
+ true,
2658
2663
  config
2659
2664
  ),
2660
2665
  getJupiterQuote(
@@ -2666,6 +2671,7 @@ function estimateDlmmIndirectSwap(_0) {
2666
2671
  false,
2667
2672
  true,
2668
2673
  true,
2674
+ true,
2669
2675
  config
2670
2676
  )
2671
2677
  ]);
@@ -2769,6 +2775,7 @@ function estimateDlmmIndirectSwap(_0) {
2769
2775
  false,
2770
2776
  true,
2771
2777
  true,
2778
+ true,
2772
2779
  config
2773
2780
  ),
2774
2781
  getJupiterQuote(
@@ -2780,6 +2787,7 @@ function estimateDlmmIndirectSwap(_0) {
2780
2787
  false,
2781
2788
  true,
2782
2789
  true,
2790
+ true,
2783
2791
  config
2784
2792
  )
2785
2793
  ]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@meteora-ag/zap-sdk",
3
- "version": "1.3.1",
3
+ "version": "1.3.2",
4
4
  "description": "A Typescript SDK for interacting with the Zap program on Meteora.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.js",