@haven-fi/solauto-sdk 1.0.55 → 1.0.57

Sign up to get free protection for your applications and to get access to all the features.
@@ -34,7 +34,7 @@ async function getJupSwapTransaction(signer, swapDetails, attemptNum) {
34
34
  slippageBps: 10,
35
35
  maxAccounts: 60,
36
36
  }), 3);
37
- const finalPriceSlippageBps = Math.round(Math.max(100, quoteResponse.slippageBps, Math.round((0, numberUtils_1.toBps)(parseFloat(quoteResponse.priceImpactPct))) + 1) *
37
+ const finalPriceSlippageBps = Math.round(Math.max(50, quoteResponse.slippageBps, Math.round((0, numberUtils_1.toBps)(parseFloat(quoteResponse.priceImpactPct))) + 1) *
38
38
  (1 + (swapDetails.slippageBpsIncFactor ?? 0)));
39
39
  quoteResponse.slippageBps = finalPriceSlippageBps;
40
40
  console.log(quoteResponse);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haven-fi/solauto-sdk",
3
- "version": "1.0.55",
3
+ "version": "1.0.57",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "description": "Typescript SDK for the Solauto program on the Solana blockchain",
@@ -73,7 +73,7 @@ export async function getJupSwapTransaction(
73
73
 
74
74
  const finalPriceSlippageBps = Math.round(
75
75
  Math.max(
76
- 100,
76
+ 50,
77
77
  quoteResponse.slippageBps,
78
78
  Math.round(toBps(parseFloat(quoteResponse.priceImpactPct))) + 1
79
79
  ) *