← all tools
Withdrawal risk
Measures every lending market for an asset by what is not lent out: the free liquidity in dollars and the utilisation behind it. Says which markets are open, which are tight, and which are effectively locked behind borrowers, and whether a withdrawal of a given size would clear today.
Arguments
asset
string · required
Asset symbol, e.g. USDC or WETH
chain
enum · required
Chain to search
amountUsd
number · optional
Withdrawal size in USD, to check whether it clears
What it answers
{"asset":"USDC","chain":"base","amountUsd":50000}compound-v3 holds the deepest USDC pool on base: $36.7M free of $378.7M deposited, 90% lent out. A $50k withdrawal clears on compound-v3 and would stall on moonwell. moonwell at 100% is effectively locked: almost everything is lent out, so a withdrawal of any size queues behind borrowers.
Call it from an agent
Over MCP the tool is called by name and the payment is handled underneath.
withdrawal_risk(asset: "USDC", chain: "base", amountUsd: 50000)
Call it over HTTP
The first request returns 402 with the accepted networks. Sign one and repeat the request with the receipt.
curl -X POST https://onchainrouter.io/api/tools/withdrawal-risk \ -H 'Content-Type: application/json' \ -d '{"asset":"USDC","chain":"base","amountUsd":50000}' ← 402 Payment Required PAYMENT-REQUIRED: hedera:testnet, eip155:5042002 curl -X POST https://onchainrouter.io/api/tools/withdrawal-risk \ -H 'Content-Type: application/json' \ -H "PAYMENT-SIGNATURE: $RECEIPT" \ -d '{"asset":"USDC","chain":"base","amountUsd":50000}' ← 200 OK