{"uid":"cap_fj17Oo9oT3TDBZmMS_yYb","slug":"defi-oracle-liquidation-risk-calculator-e1a7c6fd","name":"DeFi Oracle — Liquidation Risk Calculator","description":"DeFi data for AI agents — yield rates, swap routes, IL calculator, liquidation risk, MEV scanner, TVL tracking. Powered by DeFiLlama + on-chain RPC data. Pay with USDC on Base via x402.","url":"https://aracil.vercel.app/api/liquidation-risk","method":"POST","headers":{},"bodySchema":{"type":"object","required":["borrow_token","collateral_token"],"properties":{"borrow_token":{"type":"string"},"collateral_token":{"type":"string"},"borrow_amount_usd":{"type":"number"},"collateral_value_usd":{"type":"number"},"liquidation_threshold":{"type":"number"}}},"responseSchema":{"type":"object","properties":{"chain":{"type":"string"},"borrow":{"type":"string"},"position":{"type":"object"},"collateral":{"type":"string"},"risk_level":{"type":"string"},"liquidation":{"type":"object"},"recommendations":{"type":"array","items":{"type":"string"}}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.15","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.15/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.15","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.15","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_8hWEn4p9lKN8apDfECvjg","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.15","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Calculates liquidation risk for a DeFi borrowing position given collateral and borrow token details, returning risk level, liquidation thresholds, and actionable recommendations.","exampleAgentPrompt":"Check my liquidation risk for a DeFi position where I've borrowed $5,000 USDC against $8,000 worth of ETH collateral with a liquidation threshold of 0.8 — tell me my risk level and any recommendations.","exampleUseCases":[{"title":"Pre-trade liquidation safety check","prompt":"I'm about to borrow $3,000 DAI using $5,000 of WBTC as collateral with a liquidation threshold of 0.75 — can you check if this position is safe or dangerously close to liquidation?"},{"title":"Monitoring an existing leveraged loan","prompt":"I already have a loan where I borrowed $10,000 USDC against $12,500 ETH collateral at a 0.85 liquidation threshold — what's my current risk level and should I add more collateral?"},{"title":"Stress-testing a stablecoin borrow position","prompt":"If I borrow $2,000 USDC and use $4,000 of MATIC as collateral with a 0.7 liquidation threshold, how risky is that position and what does the DeFi Oracle say I should do to stay safe?"}],"resultDescription":"Returns an object containing the chain, borrow and collateral token labels, a position summary object, a risk_level string (e.g. low/medium/high/critical), a liquidation object with threshold and price details, and an array of human-readable recommendations to reduce risk or maintain the position.","failureModes":["Missing required fields (borrow_token or collateral_token) returns a validation error","Unknown or unsupported token symbols may return null pricing data or an error","If on-chain RPC data is unavailable, the endpoint may return stale or incomplete liquidation details","Payment failure (insufficient USDC on Base) blocks the request before processing"],"whenToPreferThis":"Use this endpoint when an AI agent needs to evaluate liquidation risk for an open or hypothetical DeFi lending/borrowing position and wants structured risk assessment with recommendations. It is specifically suited for agents managing DeFi portfolios, alerting users to dangerous health factors, or running pre-trade risk checks before opening leveraged positions. Prefer this over generic price feeds when you need a holistic risk score with actionable advice rather than raw price data alone.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T18:33:48.450Z","isFirstParty":false}