{"uid":"cap_q0Tl5B-97gZ_CGwR-UUmg","slug":"avasis-erc-20-allowance-checker-ethereum-c574f4ad","name":"Avasis ERC-20 Allowance Checker (Ethereum)","description":"ERC-20 allowance check on Ethereum (chain 1, $0.02): owner + token + spender -> allowance (raw + units, unlimited flag), balance, spendable now = min(allowance, balance), USD exposure, spender code check (EOA = drainer pattern), Permit2 note. Add amount for a needs-approval check (shortfall) + approve calldata; revoke calldata always. Phrases: erc20 allowance, token approval check, needs approval, approve calldata, revoke approval. GET or POST JSON. Not an ERC-20 -> 404, never charged.","url":"https://agents.avasis.ai/v1/eth/erc20-allowance?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["owner","token","spender"],"properties":{"chain":{"type":"string","description":"optional; must be ethereum / 1 on this route"},"owner":{"type":"string","description":"the token holder whose approval you are checking (0x + 40 hex)"},"token":{"type":"string","description":"ERC-20 token contract on Ethereum (0x + 40 hex)"},"amount":{"type":"string","description":"optional amount in token units (e.g. 100.5): adds the needs-approval check (sufficient allowance / balance, shortfall) and exact approve calldata"},"spender":{"type":"string","description":"the contract or account that would call transferFrom (router, Permit2, bridge, ...) (0x + 40 hex)"}},"additionalProperties":false}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object","required":["chain","token","owner","spender","allowance","spendable_now","calldata","headline"],"properties":{"usd":{"type":"object"},"kind":{"type":"string"},"rail":{"type":"string"},"chain":{"type":"string"},"check":{"type":["object","null"]},"owner":{"type":"string"},"token":{"type":"object"},"spender":{"type":"object"},"calldata":{"type":"object"},"chain_id":{"type":"integer"},"headline":{"type":"string"},"allowance":{"type":"object"},"block_number":{"type":"integer"},"owner_balance":{"type":"object"},"spendable_now":{"type":"object"},"also_available":{"type":"object"},"covers_full_balance":{"type":["boolean","null"]}}}}}}},"responseSchema":{"type":"json","example":{"usd":{"note":"exposure = spendable_now at the current price","price":1,"exposure":11285.04,"allowance":null,"price_source":"stablecoin peg (known issuer)","owner_balance":11285.04},"kind":"erc20-allowance","rail":"evm-rails-1","chain":"ethereum","check":{"amount":"250","verdict":"READY: the spender can move this amount now","amount_raw":"250000000","needs_approval":false,"shortfall_balance":"0","sufficient_balance":true,"shortfall_allowance":"0","sufficient_allowance":true,"approve_exact_calldata":null},"owner":"0x8fae03e3e0cb922297495bc22ee2a7c997f89b8d","reads":{"rpc":"fixture","calls":8,"elapsed_ms":0},"token":{"known":"USDC (Circle)","symbol":"USDC","address":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","decimals":6,"decimals_source":"decimals()"},"spender":{"note":"Permit2 keeps its own per-spender allowances on top of this ERC-20 approval","known":"Uniswap Permit2","address":"0x000000000022d473030f116ddee9f6b43ac78ba3","permit2":true,"is_contract":true},"calldata":{"to":"0x833589fcd6edb6e08f4c7c32d4f71b54bda02913","from":"the owner","note":"approve(spender, amount) as 0x calldata, ready to sign from the owner; prefer an exact amount over unlimited; revoke = approve(spender, 0). Simulate first: /v1/<chain>/tx-precheck","revoke":"0x095ea7b3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba30000000000000000000000000000000000000000000000000000000000000000","approve_exact":null,"approve_unlimited":"0x095ea7b3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba3ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"},"chain_id":1,"headline":"USDC on Base: 0x8fae…9b8d allows Uniswap Permit2 UNLIMITED; balance 11,285.039971 (exposure $11,285.04); READY for 250","allowance":{"raw":"115792089237316195423570985008687907853269984665640564039457584007913129639935","zero":false,"amount":"115792089237316195423570985008687907853269984665640564039457584007913129.639935","unlimited":true,"pct_of_balance":100},"block_number":53354727,"owner_balance":{"raw":"11285039971","error":null,"amount":"11285.039971"},"spendable_now":{"raw":"11285039971","note":"what the spender could move right now = min(allowance, owner balance)","amount":"11285.039971","limited_by":"balance"},"covers_full_balance":true}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_1fbqbp7pR0yjgSK8H9Fs1","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns the current ERC-20 token allowance a spender has over an owner's tokens on Ethereum, with optional approval sufficiency check and ready-to-sign calldata.","exampleAgentPrompt":"Check how much USDC allowance my wallet 0x8fae03e3e0cb922297495bc22ee2a7c997f89b8d has granted to Uniswap Permit2 (0x000000000022d473030f116ddee9f6b43ac78ba3) on Ethereum, and tell me if it's enough to cover a 250 USDC transfer — also give me the calldata to revoke if it's unlimited.","exampleUseCases":[{"title":"Pre-swap approval check for DeFi","prompt":"Before I swap on Uniswap, check if my wallet 0x8fae03e3e0cb922297495bc22ee2a7c997f89b8d has enough USDC (token 0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48) allowance for Permit2 (0x000000000022d473030f116ddee9f6b43ac78ba3) to cover 500 USDC, and give me the approve calldata if I need to top it up."},{"title":"Audit unlimited token approvals","prompt":"Check what allowance my address 0x8fae03e3e0cb922297495bc22ee2a7c997f89b8d has given to the Aave lending pool (0x7d2768de32b0b80b7a3454c06bdac94a69ddc7a9) for DAI (0x6b175474e89094c44da98b954eedeac495271d0f) on Ethereum — is it unlimited? If so, give me the revoke calldata."},{"title":"Risk check before bridge transaction","prompt":"I'm about to bridge WETH using the Stargate router (0x8731d54e9d02c286767d56ac03e8037c07e01e98) from my wallet 0xabc1230000000000000000000000000000000001 — can you check my current WETH (0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2) allowance and USD exposure, and tell me if I need to approve more?"}],"resultDescription":"A JSON object containing the current allowance (raw and human-readable), whether it is unlimited, the owner's token balance and USD exposure, the spendable_now amount, a verdict on whether the allowance is sufficient for the requested amount, any shortfall, ready-to-sign approve and revoke calldata, recognized names for the token and spender (e.g. USDC Circle, Uniswap Permit2), and a plain-English headline summarizing the situation.","failureModes":["Invalid or malformed owner/token/spender address returns a 400 error","Token contract does not exist or is not ERC-20 compliant causes RPC call failure","Network congestion or RPC timeout may delay response","Unsupported chain identifier returns an error (only ethereum/1 on this route)","Amount field with non-numeric value causes parsing error"],"whenToPreferThis":"Use this endpoint when you need a single, structured, pay-per-call lookup of ERC-20 allowances on Ethereum without requiring an API key or account — especially useful for agents performing pre-trade safety checks, approval audits, or generating revoke/approve calldata before signing a transaction. Prefer it over raw RPC calls when you also want enriched metadata (known spender names, USD exposure, Permit2 flags, and ready-to-sign calldata) in one response.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-02T18:32:39.283Z","isFirstParty":false,"canonicalSlug":"avasis-erc-20-allowance-checker-ethereum-c574f4ad"}