I'm trying to fetch the pool keys that are necessary to make swap a transaction using the Raydium SDK. These keys are available in the https://api.raydium.io/v2/sdk/liquidity/mainnet.json file, but this is not updated in real time and its download is heavily rate-limited. So what happens is that when I detect a new liquidity pool using dextools.io APIs I would need to wait several minutes for this information to be available.

How do websites like dextools.io get the information about the pool when it's not in the mainnet.json file yet? Based on a similar question (Faster method to retrieve pool keys [Raydium]) asked previously, I assume this can be done with the getProgramAccounts RPC call, but:

  1. This call is not available on the RPC providers I've tried, as it appears to be very expensive
  2. Discarding point 1. it seems that the call requires a marketProgramId which is itself available only through the mainnet.json file (as far as I understand things).

EDIT I might've understood that the marketProgramId refers to the Serum program (srmqPvymJeFKQ4zGQed1GFppgkRHL9kaELCbyksJtPX) but even if this is correct the call is still blocked for the performance reasons mentioned earlier.

How to sort this out?

3 Answers 3


You can either use Geyser to monitor pool creation in real time https://github.com/raydium-io/raydium-sdk-V1-demo/blob/master/src/subNewAmmPool.ts

These can be used to get pool keys for previously created pools, etc CPMM https://github.com/raydium-io/raydium-sdk-V1-demo/blob/master/src/formatAmmKeys.ts CLMM https://github.com/raydium-io/raydium-sdk-V1-demo/blob/master/src/formatClmmKeys.ts


If you want to retrieve information about a new pool, you'll need to use Raydium WebSocket to get the pool info.


I'm in the same situation, Raydium doesn't make the task easier for us, it's complicated.

But I just found an interesting doc with a telegram group. The api is free.

Here is the link to the doc: https://docs.valguibs.com

And the telegram group link: https://t.me/+JVm2omY299Q1NjI0

  • This is not an answer to the question. It instead looks like a promotion of a tool without any information provided. Without any further details, you've just provided a Telegram link. Please provide better examples, codes, and reason to why/how someone should use a different tool when there are already official tools. Feb 17 at 16:20
  • This is an answer, you have some code examples in the documentation… You just need to read it.
    – Zak Koli
    Mar 4 at 8:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.