Loading...
Loading...
Compare original and translation side by side
/collect-feesCheck my LP fees on BSC for 0xYourWalletHow much ETH/USDC fees have I earned on Arbitrum?Collect my CAKE/BNB fees — wallet 0xYourWalletCheck my uncollected fees on PancakeSwap Solana farms — wallet <base58-pubkey>/collect-fees查询我在BSC链上0xYourWallet钱包的LP手续费我在Arbitrum链上的ETH/USDC交易对赚了多少手续费?收取我CAKE/BNB交易对的手续费 — 钱包地址0xYourWallet查询我在PancakeSwap Solana农场的未收取手续费 — 钱包地址<base58-pubkey>viem@pancakeswap/infinity-sdk@pancakeswap/solana-core-sdkviem@pancakeswap/infinity-sdk@pancakeswap/solana-core-sdkWALLET='0xAbc...'"$WALLET""$RPC"^0x[0-9a-fA-F]{40}$^[1-9A-HJ-NP-Za-km-z]{32,44}$^0x[0-9a-fA-F]{40}$"`$\;|&openxdg-openhttps://pancakeswap.finance/curlapi.dexscreener.comtokens.pancakeswap.financeexplorer.pancakeswap.compancakeswap.aicollect()decreaseLiquidity()WALLET='0xAbc...'"$WALLET""$RPC"^0x[0-9a-fA-F]{40}$^[1-9A-HJ-NP-Za-km-z]{32,44}$^0x[0-9a-fA-F]{40}$"`$\;|&https://pancakeswap.finance/openxdg-opencurlapi.dexscreener.comtokens.pancakeswap.financeexplorer.pancakeswap.compancakeswap.aicollect()decreaseLiquidity()AGENT_NAMEclaude-codecursorcopilotopenaicurl -s -o /dev/null --max-time 3 \
"https://pancakeswap.ai/api/ping?skill=pcs-collect-fees&version=1.0.0&agent=AGENT_NAME&ts=$(date -u +%Y-%m-%dT%H:%M:%SZ)&os=$(uname -s)&arch=$(uname -m)" \
2>/dev/null &AGENT_NAMEclaude-codecursorcopilotopenaicurl -s -o /dev/null --max-time 3 \
"https://pancakeswap.ai/api/ping?skill=pcs-collect-fees&version=1.0.0&agent=AGENT_NAME&ts=$(date -u +%Y-%m-%dT%H:%M:%SZ)&os=$(uname -s)&arch=$(uname -m)" \
2>/dev/null &| Pool Type | Discovery Method | Chains | Position Model | Fee Query Method |
|---|---|---|---|---|
| V3 | On-chain: NonfungiblePositionManager NFT | BSC, ETH, ARB, Base, zkSync, Linea, opBNB, Monad | ERC-721 NFT (tokenId) | TypeScript/node via |
| Infinity (v4) | Explorer API only (no NFT, no | BSC, Base only | Singleton PoolManager (no NFT) | TypeScript/node via |
| Solana | | Solana mainnet | CLMM positions + Farm accounts | |
| V2 | Out of scope | BSC only | ERC-20 LP token | Out of scope — fees embedded in LP value |
| 仓位类型 | 发现方式 | 支持链 | 仓位模型 | 手续费查询方式 |
|---|---|---|---|---|
| V3 | 链上:NonfungiblePositionManager NFT合约 | BSC、ETH、ARB、Base、zkSync、Linea、opBNB、Monad | ERC-721 NFT(基于tokenId) | 通过TypeScript/node调用 |
| Infinity (v4) | 仅通过Explorer API(无NFT,无 | BSC、Base仅支持 | 单例PoolManager(无NFT) | 通过TypeScript/node调用 |
| Solana | | Solana主网 | CLMM仓位 + 农场账户 | |
| V2 | 超出范围 | 仅BSC | ERC-20 LP代币 | 超出范围 — 手续费已嵌入LP代币价值中 |
| Chain | Chain ID | Deep Link Key | RPC Endpoint | Contract Address |
|---|---|---|---|---|
| BNB Smart Chain | 56 | | | |
| Ethereum | 1 | | | |
| Arbitrum One | 42161 | | | |
| Base | 8453 | | | |
| zkSync Era | 324 | | | |
| Linea | 59144 | | | |
| opBNB | 204 | | | |
| Monad | 143 | | | |
| 链名称 | 链ID | 深度链接标识 | RPC端点 | 合约地址 |
|---|---|---|---|---|
| BNB智能链 | 56 | | | |
| 以太坊 | 1 | | | |
| Arbitrum One | 42161 | | | |
| Base | 8453 | | | |
| zkSync Era | 324 | | | |
| Linea | 59144 | | | |
| opBNB | 204 | | | |
| Monad | 143 | | | |
| Chain | Chain ID | Deep Link Key |
|---|---|---|
| BNB Smart Chain | 56 | |
| Base | 8453 | |
| Contract | Address |
|---|---|
| CLPositionManager | |
| CLPoolManager | |
| BinPositionManager | |
| BinPoolManager | |
| 链名称 | 链ID | 深度链接标识 |
|---|---|---|
| BNB智能链 | 56 | |
| Base | 8453 | |
| 合约名称 | 地址 |
|---|---|
| CLPositionManager | |
| CLPoolManager | |
| BinPositionManager | |
| BinPoolManager | |
AskUserQuestion0x...AskUserQuestion0x...WALLET='0xYourWalletHere'
[[ "$WALLET" =~ ^0x[0-9a-fA-F]{40}$ ]] || { echo "Invalid wallet address"; exit 1; }
CHAIN_ID='56' # Chain ID (e.g. 56=BSC, 1=ETH, 42161=ARB, 8453=Base, 324=zkSync, 59144=Linea, 204=opBNB, 143=Monad)
RPC='https://bsc-dataseed1.binance.org'
TMP_DIR=$(mktemp -d)
cd "$TMP_DIR"
cat > package.json << 'PKGJSON'
{ "type": "module" }
PKGJSON
npm install --silent viem @pancakeswap/v3-sdkreferences/fetch-v3-positions.mjsWALLET="$WALLET" POSITION_MANAGER="$POSITION_MANAGER" RPC="$RPC" CHAIN_ID="$CHAIN_ID" node fetch-v3-positions.mjstokenIdtoken0token1feetokensOwed0tokensOwed1tickLowertickUpperliquidityfarmingliquidity = 0tokensOwed0tokensOwed1Infinity (v4) only: Skip this step entirely. Go directly to Step 2B.
Solana only: Skip this step entirely. Go directly to Step 2C.
WALLET='0xYourWalletHere'
[[ "$WALLET" =~ ^0x[0-9a-fA-F]{40}$ ]] || { echo "Invalid wallet address"; exit 1; }
CHAIN_ID='56' # 链ID(例如56=BSC、1=ETH、42161=ARB、8453=Base、324=zkSync、59144=Linea、204=opBNB、143=Monad)
RPC='https://bsc-dataseed1.binance.org'
TMP_DIR=$(mktemp -d)
cd "$TMP_DIR"
cat > package.json << 'PKGJSON'
{ "type": "module" }
PKGJSON
npm install --silent viem @pancakeswap/v3-sdkreferences/fetch-v3-positions.mjsWALLET="$WALLET" POSITION_MANAGER="$POSITION_MANAGER" RPC="$RPC" CHAIN_ID="$CHAIN_ID" node fetch-v3-positions.mjstokenIdtoken0token1feetokensOwed0tokensOwed1tickLowertickUpperliquidityfarmingliquidity = 0tokensOwed0tokensOwed1仅Infinity(v4)注意:完全跳过此步骤,直接进入步骤2B。
仅Solana注意:完全跳过此步骤,直接进入步骤2C。
balanceOf()tokenOfOwnerByIndex()WALLET='0xYourWalletHere'
[[ "$WALLET" =~ ^0x[0-9a-fA-F]{40}$ ]] || { echo "Invalid wallet address"; exit 1; }
CHAIN_ID='56' # or 'base'
RPC='https://bsc-dataseed1.binance.org'
TMP_DIR=$(mktemp -d)
cd "$TMP_DIR"
cat > package.json << 'PKGJSON'
{ "type": "module" }
PKGJSON
npm install --silent viem @pancakeswap/infinity-sdkreferences/fetch-infinity-positions.mjsWALLET="$WALLET" CHAIN_ID="$CHAIN_ID" RPC="$RPC" node fetch-infinity-positions.mjsclPositions[].pending0pending1binPositions[].amountXamountYliquidity"0"balanceOf()tokenOfOwnerByIndex()WALLET='0xYourWalletHere'
[[ "$WALLET" =~ ^0x[0-9a-fA-F]{40}$ ]] || { echo "Invalid wallet address"; exit 1; }
CHAIN_ID='56' # 或'base'
RPC='https://bsc-dataseed1.binance.org'
TMP_DIR=$(mktemp -d)
cd "$TMP_DIR"
cat > package.json << 'PKGJSON'
{ "type": "module" }
PKGJSON
npm install --silent viem @pancakeswap/infinity-sdkreferences/fetch-infinity-positions.mjsWALLET="$WALLET" CHAIN_ID="$CHAIN_ID" RPC="$RPC" node fetch-infinity-positions.mjsclPositions[].pending0pending1binPositions[].amountXamountYliquidity"0"EVM chains only: Skip this step. Use Step 2A for V3 or Step 2B for Infinity.
SOL_WALLET='YourBase58PubkeyHere'
[[ "$SOL_WALLET" =~ ^[1-9A-HJ-NP-Za-km-z]{32,44}$ ]] || { echo "Invalid Solana wallet address"; exit 1; }npm install --silent @pancakeswap/solana-core-sdk @solana/web3.js @solana/spl-token@0.4.0references/fetch-solana.cjsSOL_WALLET="$SOL_WALLET" node fetch-solana.cjsclmmPositions[]positionIdpoolIdtickLowertickUpperliquidityfarmPositions[]poolIddepositedpendingRewards[]仅EVM链注意:跳过此步骤。V3用步骤2A,Infinity用步骤2B。
SOL_WALLET='YourBase58PubkeyHere'
[[ "$SOL_WALLET" =~ ^[1-9A-HJ-NP-Za-km-z]{32,44}$ ]] || { echo "Invalid Solana wallet address"; exit 1; }npm install --silent @pancakeswap/solana-core-sdk @solana/web3.js @solana/spl-token@0.4.0references/fetch-solana.cjsSOL_WALLET="$SOL_WALLET" node fetch-solana.cjsclmmPositions[]positionIdpoolIdtickLowertickUpperliquidityfarmPositions[]poolIddepositedpendingRewards[]token0token1../common/token-lists.mdtoken0token1../common/token-lists.md| Chain | Chain ID |
|---|---|
| BNB Smart Chain | 56 |
| Ethereum | 1 |
| Arbitrum One | 42161 |
| Base | 8453 |
| zkSync Era | 324 |
| Linea | 59144 |
| opBNB | 204 |
undefined| 链名称 | 链ID |
|---|---|
| BNB智能链 | 56 |
| 以太坊 | 1 |
| Arbitrum One | 42161 |
| Base | 8453 |
| zkSync Era | 324 |
| Linea | 59144 |
| opBNB | 204 |
undefinedundefinedundefinednode -e "
const tokensOwed0 = 142500000000000000000n;
const decimals0 = 18;
const priceUsd0 = 0.25;
const amount = Number(tokensOwed0) / (10 ** decimals0);
const usd = amount * priceUsd0;
console.log(\`Amount: \${amount.toFixed(4)}, USD: \$\${usd.toFixed(2)}\`);
"node -e "
const tokensOwed0 = 142500000000000000000n;
const decimals0 = 18;
const priceUsd0 = 0.25;
const amount = Number(tokensOwed0) / (10 ** decimals0);
const usd = amount * priceUsd0;
console.log(\`Amount: \${amount.toFixed(4)}, USD: \$\${usd.toFixed(2)}\`);
"Fee Summary — BNB Smart Chain (V3 Positions)
| tokenId | Pair | Pending token0 | Pending token1 | Est. USD |
|---------|------------|----------------|----------------|----------|
| 12345 | CAKE / BNB | 142.5 CAKE | 0.32 BNB | $112.40 |
| 67890 | ETH / USDC | 0.005 ETH | 12.40 USDC | $24.80 |
Total estimated pending fees: ~$137.20
Note: tokensOwed values are the crystallised floor. Actual collectable amounts may
be higher — the PancakeSwap UI includes in-range accrued fees at collection time.手续费汇总 — BNB智能链(V3仓位)
| tokenId | 交易对 | 待领取token0 | 待领取token1 | 美元估值 |
|---------|------------|----------------|----------------|----------|
| 12345 | CAKE / BNB | 142.5 CAKE | 0.32 BNB | $112.40 |
| 67890 | ETH / USDC | 0.005 ETH | 12.40 USDC | $24.80 |
待领取手续费总估值:~$137.20
注意:tokensOwed值为已固化的基数。实际可收取金额可能更高 — PancakeSwap界面会在收取时加入范围内累积的手续费。Infinity (v4) Positions — BNB Smart Chain
─── CL Positions ────────────────────────────────────────
| Position ID | Lower Tick | Upper Tick | Pending token0 | Pending token1 | Est. USD |
|-------------|------------|------------|----------------|----------------|----------|
| 745477 | 61450 | 61500 | 12.5 CAKE | 0.08 BNB | $18.40 |
─── Bin Positions ───────────────────────────────────────
| Position ID | Bin ID | Amount token0 | Amount token1 | Est. USD |
|-------------|---------|-------------------------|-------------------------|----------|
| (none found) |
Note: Bin amountX / amountY include both principal and accrued fees (fees are embedded in bin reserves).
CAKE Farming Rewards: Auto-distributed every 8 hours via Merkle proofs.
No manual harvest is needed for CAKE rewards.
→ All positions overview:
https://pancakeswap.finance/liquidity/positionsInfinity(v4)仓位 — BNB智能链
─── CL仓位 ────────────────────────────────────────
| 仓位ID | 下限Tick | 上限Tick | 待领取token0 | 待领取token1 | 美元估值 |
|-------------|------------|------------|----------------|----------------|----------|
| 745477 | 61450 | 61500 | 12.5 CAKE | 0.08 BNB | $18.40 |
─── Bin仓位 ───────────────────────────────────────
| 仓位ID | Bin ID | token0金额 | token1金额 | 美元估值 |
|-------------|---------|-------------------------|-------------------------|----------|
| 未找到任何仓位 |
注意:Bin仓位的amountX/amountY包含本金和累积的手续费(手续费已嵌入Bin储备金中)。
CAKE挖矿奖励:每8小时通过默克尔证明自动分发。无需手动领取CAKE奖励。
→ 所有仓位概览:
https://pancakeswap.finance/liquidity/positionsSolana Positions
Wallet: <base58-pubkey>
─── CLMM Positions ─────────────────────
| Position | Pool | Lower Tick | Upper Tick | Liquidity |
|----------|------|------------|------------|-----------|
| abc... | xyz | -100 | 100 | 1000000 |
Note: Exact pending fees are shown in the PancakeSwap UI.
─── Farm Positions ──────────────────────
| Pool | Deposited LP | Pending Rewards |
|------|-------------|-----------------|
| xyz | 5000000 | 123 RAY, 45 USDC|
─── Deep Links ──────────────────────────
All Solana farms:
https://pancakeswap.finance/liquidity/positions?network=8000001001
Solana liquidity positions:
https://pancakeswap.finance/liquidity/positions?network=8000001001Solana仓位
钱包地址:<base58-pubkey>
─── CLMM仓位 ─────────────────────
| 仓位 | 池 | 下限Tick | 上限Tick | 流动性 |
|----------|------|------------|------------|-----------|
| abc... | xyz | -100 | 100 | 1000000 |
注意:待领取手续费的精确金额请查看PancakeSwap界面。
─── 农场仓位 ──────────────────────
| 池 | 存入的LP代币 | 待领取奖励 |
|------|-------------|-----------------|
| xyz | 5000000 | 123 RAY, 45 USDC|
─── 深度链接 ──────────────────────────
所有Solana农场:
https://pancakeswap.finance/liquidity/positions?network=8000001001
Solana流动性仓位:
https://pancakeswap.finance/liquidity/positions?network=8000001001V2 Fee Collection
V2 pool fees are continuously embedded into the LP token's value — they cannot
be "collected" separately. To realise your fee earnings, you would remove liquidity,
which burns your LP tokens and returns both tokens (including accumulated fees).
→ Remove V2 liquidity: https://pancakeswap.finance/v2/remove/{tokenA}/{tokenB}?chain=bscV2手续费收取说明
V2池的手续费会持续嵌入LP代币的价值中 — 无法“单独收取”。要兑现手续费收益,您需要移除流动性,这会销毁您的LP代币并返回两种代币(包含累积的手续费)。
→ 移除V2流动性:https://pancakeswap.finance/v2/remove/{tokenA}/{tokenB}?chain=bschttps://pancakeswap.finance/liquidity/{tokenId}?chain={chainKey}https://pancakeswap.finance/liquidity/12345?chain=bschttps://pancakeswap.finance/liquidity/{tokenId}?chain={chainKey}https://pancakeswap.finance/liquidity/12345?chain=bschttps://pancakeswap.finance/liquidity/positions?network={chainId}https://pancakeswap.finance/liquidity/positions?network={chainId}https://pancakeswap.finance/liquidity/positions?network=8000001001https://pancakeswap.finance/liquidity/positions?network=8000001001DEEP_LINK="https://pancakeswap.finance/liquidity/12345?chain=bsc"DEEP_LINK="https://pancakeswap.finance/liquidity/12345?chain=bsc"
If the open command fails or the environment has no browser, display the URL prominently for the user to copy.
---
如果打开命令失败或环境中无浏览器,请突出显示URL供用户复制。
---Fee Collection Summary
Chain: BNB Smart Chain (BSC)
Wallet: 0xYour...Wallet
Pool Types: V3, Infinity
─── V3 Positions ───────────────────────────────────────────
| tokenId | Pair | Pending token0 | Pending token1 | Est. USD |
|---------|------------|----------------|----------------|----------|
| 12345 | CAKE / BNB | 142.5 CAKE | 0.32 BNB | $112.40 |
| 67890 | ETH / USDC | 0.005 ETH | 12.40 USDC | $24.80 |
Total V3 pending fees: ~$137.20
Note: tokensOwed is the crystallised floor — actual amounts in the UI may be
slightly higher due to in-range accrued fees added at collection time.
─── Infinity (v4) Positions ────────────────────────────────
CL Positions:
| Position ID | Lower Tick | Upper Tick | Pending token0 | Pending token1 | Est. USD |
|-------------|------------|------------|----------------|----------------|----------|
| 745477 | 61450 | 61500 | 12.5 CAKE | 0.08 BNB | $18.40 |
Bin Positions: none found
CAKE rewards: auto-distributed every 8 hours — no harvest needed
─── Deep Links ─────────────────────────────────────────────
Collect V3 position 12345:
https://pancakeswap.finance/liquidity/12345?chain=bsc
Collect V3 position 67890:
https://pancakeswap.finance/liquidity/67890?chain=bsc
All positions overview (V3 + Infinity):
https://pancakeswap.finance/liquidity/positions?network=56Fee Collection Summary
Chain: Solana
Wallet: <base58-pubkey>
Pool Types: Solana CLMM + Farms
─── CLMM Positions ─────────────────────────────────────────
| Position | Pool | Lower Tick | Upper Tick | Liquidity |
|----------|------|------------|------------|-----------|
| abc... | xyz | -100 | 100 | 1000000 |
Note: Exact pending fees are shown in the PancakeSwap UI.
─── Farm Positions ──────────────────────────────────────────
| Pool | Deposited LP | Pending Rewards |
|------|-------------|-----------------|
| xyz | 5000000 | 123 RAY, 45 USDC|
─── Deep Links ─────────────────────────────────────────────
All Solana farms:
https://pancakeswap.finance/liquidity/positions?network=8000001001
Solana liquidity positions:
https://pancakeswap.finance/liquidity/positions?network=8000001001手续费收取汇总
链: BNB智能链(BSC)
钱包地址: 0xYour...Wallet
仓位类型: V3, Infinity
─── V3仓位 ───────────────────────────────────────────
| tokenId | 交易对 | 待领取token0 | 待领取token1 | 美元估值 |
|---------|------------|----------------|----------------|----------|
| 12345 | CAKE / BNB | 142.5 CAKE | 0.32 BNB | $112.40 |
| 67890 | ETH / USDC | 0.005 ETH | 12.40 USDC | $24.80 |
V3待领取手续费总估值:~$137.20
注意:tokensOwed为已固化的基数 — 界面中的实际金额可能略高,因为收取时会加入范围内累积的手续费。
─── Infinity(v4)仓位 ────────────────────────────────
CL仓位:
| 仓位ID | 下限Tick | 上限Tick | 待领取token0 | 待领取token1 | 美元估值 |
|-------------|------------|------------|----------------|----------------|----------|
| 745477 | 61450 | 61500 | 12.5 CAKE | 0.08 BNB | $18.40 |
Bin仓位:未找到
CAKE奖励:每8小时自动分发 — 无需领取
─── 深度链接 ─────────────────────────────────────────────
收取V3仓位12345:
https://pancakeswap.finance/liquidity/12345?chain=bsc
收取V3仓位67890:
https://pancakeswap.finance/liquidity/67890?chain=bsc
所有仓位概览(V3 + Infinity):
https://pancakeswap.finance/liquidity/positions?network=56手续费收取汇总
链: Solana
钱包地址: <base58-pubkey>
仓位类型: Solana CLMM + 农场
─── CLMM仓位 ─────────────────────────────────────────
| 仓位 | 池 | 下限Tick | 上限Tick | 流动性 |
|----------|------|------------|------------|-----------|
| abc... | xyz | -100 | 100 | 1000000 |
注意:待领取手续费的精确金额请查看PancakeSwap界面。
─── 农场仓位 ──────────────────────────────────────────
| 池 | 存入的LP代币 | 待领取奖励 |
|------|-------------|-----------------|
| xyz | 5000000 | 123 RAY, 45 USDC|
─── 深度链接 ─────────────────────────────────────────────
所有Solana农场:
https://pancakeswap.finance/liquidity/positions?network=8000001001
Solana流动性仓位:
https://pancakeswap.finance/liquidity/positions?network=8000001001positions(uint256)(nonce, operator, token0, token1, fee, tickLower, tickUpper, liquidity, feeGrowthInside0LastX128, feeGrowthInside1LastX128, tokensOwed0, tokensOwed1)encodeClaimCalldata()Raydium.load()raydium.clmm.getOwnerPositionInfo()fetchMultipleFarmInfoAndUpdate()positions(uint256)(nonce, operator, token0, token1, fee, tickLower, tickUpper, liquidity, feeGrowthInside0LastX128, feeGrowthInside1LastX128, tokensOwed0, tokensOwed1)encodeClaimCalldata()Raydium.load()raydium.clmm.getOwnerPositionInfo()fetchMultipleFarmInfoAndUpdate()