Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

harvestLockLp can not work for devnet, keypools do not set #85

Open
benhaben opened this issue Jan 29, 2025 · 1 comment
Open

harvestLockLp can not work for devnet, keypools do not set #85

benhaben opened this issue Jan 29, 2025 · 1 comment

Comments

@benhaben
Copy link

raydium.cpmm.harvestLockLp can not find keypools at devnet

@cruzshia
Copy link
Collaborator

cruzshia commented Jan 29, 2025

for devent you should fetch pool keys from rpc, here's the example

const data = await raydium.cpmm.getPoolInfoFromRpc(lockData.poolId.toBase58())
const { execute, transaction } = await const { execute, transaction } = await raydium.cpmm.harvestLockLp({
    poolInfo,
    nftMint: new PublicKey('lock nft mint'), // locked nft mint
    lpFeeAmount: new BN(99999999),
    poolKeys: data.poolKeys,
    txVersion,
    // optional: add transfer sol to tip account instruction. e.g sent tip to jito
    // txTipConfig: {
    //   address: new PublicKey('96gYZGLnJYVFmbjzopPSU6QiEV5fGqZNyN9nmNhvrZU5'),
    //   amount: new BN(10000000), // 0.01 sol
    // },
  })

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants