keel-mcp
OfficialServer Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| KEEL_API_URL | No | Point at another deployment, or at the contract mock (http://localhost:4010). | https://api.keels.app/v1 |
| KEEL_TIMEOUT_MS | No | Per request timeout, for the Keel API and for each Soroban RPC step of audit_blend_pool. | 15000 |
| KEEL_CACHE_TTL_MS | No | Cache for the asset list and methodology. Scans run every 15 minutes. | 60000 |
| KEEL_SOROBAN_RPC_URL | No | Soroban RPC used by audit_blend_pool to read Blend pools. | https://mainnet.sorobanrpc.com |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
Keel measures the executable liquidity behind Stellar asset prices: how much volume the SDEX order book and AMM pools can absorb at +/-2%, 5% and 10%, and the largest collateral position that liquidity can safely support.
Use it to judge an asset as lending collateral (check_collateral_size), to audit a Blend lending pool's caps against Stellar liquidity (audit_blend_pool), to size a trade (estimate_trade_depth), to screen assets (list_assets, compare_assets), and to look back at a ledger (get_asset_risk with ledger, get_risk_history).
Rules for answers built on these tools:
An asset is CODE:ISSUER, never a bare ticker. Resolve codes with find_asset and ask when several issuers match.
Quote the provenance (ledger sequence and methodology version) with every number.
A flag listed as not evaluated is unchecked, not clear. A partial band is a floor.
A null figure is unknown, never zero and never safe; give the reason Keel supplies.
Thresholds are chosen, not calibrated. This is a liquidity reading, not a credit or investment decision.
Keel is read-only. It never signs or submits transactions and publishes no price feed.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
| prompts | {
"listChanged": true
} |
| resources | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| keel_statusA | Whether the Keel engine is healthy, the ledger of its latest scan, how many Stellar assets it monitors, and the methodology version its numbers follow. Call this first when freshness matters. |
| list_assetsA | Lists the Stellar assets Keel monitors with their risk band, band confidence, recommended maximum safe collateral size (USDC) and fired flags. Filter by band (e.g. CRITICAL) or by a single flag (e.g. MANIPULATION_CHEAP) to find risky collateral. |
| find_assetA | Resolves an asset code such as USDY or AQUA to the full CODE:ISSUER ids Keel monitors. When one code has several issuers, ALL of them are returned and none is chosen: ask the user which issuer they mean rather than picking one, because the same ticker from a different issuer is a different asset. |
| get_asset_riskA | The full Keel risk reading for one asset: risk band and its confidence, fired and unevaluated flags, executable depth at +/-2%, 5% and 10% (SDEX order book plus AMM pools), recommended maximum safe collateral size with its liquidation and manipulation terms, holder concentration, volume to supply, and the last genuine trade. Pass ledger to read a historical reconstruction instead of the latest scan. Always quote the provenance line with the numbers. |
| check_collateral_sizeA | Compares a proposed collateral amount with Keel's recommended maximum safe collateral size for the asset, and says which limit binds: liquidation (the book cannot absorb a forced sale) or manipulation (pushing the price up is cheaper than the loan it would unlock). Answers within, exceeds, or unknown. Unknown is not safe and not unsafe. This is a comparison with published figures, not a credit decision. |
| estimate_trade_depthA | For traders and market makers: places a buy or sell size (in the quote asset, USDC) between the measured rungs of Keel's depth ladder, answering 'this moves the price by at most 2% / 5% / 10%' or 'this exceeds the measured depth'. It is a bracket, never a point estimate, because the methodology defines no interpolation between rungs. Depth combines the SDEX order book and AMM pools. |
| get_risk_historyA | A time series of band, flags, depth and max safe collateral for one asset, from ONE data source. Give from and to (ledger sequences, at most 90 days apart) for a window, or omit both to list every stored reading of that source. Reconstructions such as the February 2026 USTRY series live under source offers-implied and are reachable only with both bounds omitted. Band changes are summarised. |
| compare_assetsA | Side-by-side comparison of 2 to 10 assets: band and confidence, max safe collateral, depth at 5% on both sides, and fired flags, each with its own ledger. Useful for choosing between collateral candidates. Figures are all in USDC. |
| get_methodologyA | The methodology version and every threshold Keel uses to fire flags and size collateral, with the link to the full documentation. The thresholds are chosen, not calibrated against a set of incidents; mention that when explaining why an asset got its band. |
| audit_blend_poolA | Reads a Blend V2 pool's collateral configuration from Stellar (collateral factor, supply cap, total supplied, oracle price) and sets each collateral reserve beside Keel's maximum safe collateral size for that asset. Says per reserve whether what the pool HOLDS and what it would ACCEPT exceed what Stellar liquidity can absorb. Omit pool to audit every known pool (YieldBlox, Fixed). Read-only; state the interpretation notes with any conclusion. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| assess_collateral | A guided assessment of whether an asset can back a loan of a given size, using Keel figures only. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| methodology | The active methodology version, its thresholds, and the calibration note, as JSON. |
| blend-backtest-report | The open, reproducible report asking whether Keel could have warned about the USTRY oracle manipulation that drained a Blend pool on 22 February 2026. Markdown, fetched from the public repository. |
TDQS
Scored across 10 tools
Most tools have clearly distinct purposes: discovery (find_asset, list_assets), single-asset detail (get_asset_risk), time series (get_risk_history), comparison (compare_assets), depth bracketing (estimate_trade_depth), and collateral sizing (check_collateral_size). The closest overlaps are find_asset vs list_assets (code resolution vs. risk-filtered listing) and estimate_trade_depth vs check_collateral_size, but the descriptions make the boundary clear.
Nine of ten tools follow a clean verb_noun pattern (find_asset, get_asset_risk, list_assets, check_collateral_size, estimate_trade_depth, get_risk_history, compare_assets, audit_blend_pool, get_methodology). keel_status breaks the pattern as a server-prefixed noun and is the only deviation.
Ten tools is well within the ideal 3-15 range and each earns its place: status, methodology, discovery, per-asset risk, history, comparison, two sizing/depth helpers, and a pool audit. No redundant filler.
Covers the full read lifecycle for Stellar asset risk: resolution, listing, detail, history, comparison, collateral sizing, depth estimation, plus blend pool auditing and methodology/status metadata. Minor gaps: no enumeration of available flags or bands, no watchlist/alerting, and no portfolio-level aggregate exposure, though agents can work around these via existing tools.