Agent guide 3 min read
Solana rent recovery for AI agents
Preview a wallet, explain the recoverable SOL, and help its owner choose the next step.
The short answer
Start with a public address. A read-only check finds recovery options without a private key or wallet signature. The owner reviews and approves recovery separately.
Start with a public address.
Reclaim's wallet-health check looks for two recovery options in supported Solana token accounts:
- Empty token accounts
- Close eligible empty accounts and recover the SOL they hold. The account is removed.
- Excess account deposits
- Recover eligible SOL above the required deposit. The account stays open and its tokens stay unchanged.
Send the public address to the read-only endpoint:
curl --get --fail-with-body \
--data-urlencode 'publicKey=YOUR_PUBLIC_WALLET_ADDRESS' \
https://reclaim.mwh.app/api/v1/wallet-healthReplace the placeholder with the address to check. The address is sent to Reclaim and its Solana RPC provider. This request cannot prepare, sign, or submit a recovery transaction.
Already using the CLI? Its public-address --json preview and /api/v1/preview cover empty-account closure. Use wallet health for both checks. Existing preview API and CLI reference.
Explain what the owner could receive.
A useful answer shows the recovery options, estimated costs, and anything that could block them.
- Recoverable SOL
- Use the combined gross total, which counts overlapping deposits once. An empty account's balance already includes any excess it holds.
- Costs
- Closure deducts 10% including service and referral portions; excess recovery deducts 10%. Network fees and any applicable closure subsidy charges also affect the amount received.
- Eligibility
- Include blocking reasons and warnings. Finding an account does not guarantee that its recovery transaction will succeed.
The combined total is before fees. Wallet health does not provide a combined net quote. A missing or null estimate means unknown, not zero.
Amounts are exact lamport strings; use integer arithmetic such as BigInt. Refresh expired results and recheck before signing. The recovery review provides a fresh batch and its fees. Full fees and eligibility.
Keep approval with the wallet owner.
Agent
Check
Read the wallet’s public accounts.
Agent
Explain
Show the options, costs, and limits.
Wallet owner
Approve
Review and sign the chosen recovery.
Offer the browser recovery flow when the owner wants to continue. They connect the same wallet, review the chosen accounts and fees, and approve each batch. Checking an address does not authorize signing.
For advanced local empty-account closure, link to the CLI signing guide. It signs batches locally rather than showing a browser approval for each one. Keep private keys out of chats and websites; the public preview needs none.
Report recovery as completed only after confirmation. If a submitted batch is pending, check its status before attempting another.