Quantcast
Channel: Recent Questions - Solana Stack Exchange
Viewing all articles
Browse latest Browse all 8063

`Error: destinationAmountSwapped is zero` Raydium CurveCalculator

$
0
0

I am trying to get the swap results before making a swap using from Raydium V2 SDK

  const swapResult = CurveCalculator.swap(    inputAmount,    baseIn ? baseReserve : quoteReserve,    baseIn ? quoteReserve : baseReserve,    new BN(feeConfigs[0].tradeFeeRate)  );

But it keeps failing with

Error: destinationAmountSwapped is zero

Viewing all articles
Browse latest Browse all 8063

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>