← ClaudeAtlas

scallop-market-limitslisted

Query Scallop per-asset borrow/supply caps and isolated-asset rules. Use when user says "borrow limit", "supply limit", "borrow cap", "supply cap", "supply ceiling", "isolated asset", "isolated collateral", "asset cap", "pool cap", "can I borrow more", or asks why a supply/borrow is rejected despite a healthy obligation.
scallop-io/scallop-skills · ★ 1 · AI & Automation · score 65
Install: claude install-skill scallop-io/scallop-skills
# Market Limits & Isolated Assets Read the protocol-level caps that gate every supply/borrow op, independent of obligation health. ## Overview Scallop enforces **two layers** of constraints before a state-changing op succeeds: 1. **Per-obligation health** — collateral factor × USD value of collateral must cover the new debt. Documented in [obligation-manager](../scallop-obligation-manager/SKILL.md). 2. **Per-asset market caps** — global ceilings the protocol places on each pool, plus the "isolated asset" flag on certain collaterals. This is the layer this skill covers. If a `supply_quick`/`borrow_quick` reverts even though the obligation looks healthy and there's plenty of liquidity, the cause is almost always one of these caps. ## Borrow & Supply Limits Each asset has independent `borrow_limit` and `supply_limit` values stored on-chain. The TS SDK (verified against `@scallop-io/sui-scallop-sdk` v4.3.0) exposes them two ways: 1. **Normalized, on `MarketPool`** (preferred): `getMarketPool(coinName)` returns `maxSupplyCoin` / `maxBorrowCoin` alongside the current `supplyCoin` / `borrowCoin` — all `number`s already shifted to human coin units, safe for plain arithmetic. See [src/repositories/market/utils.ts](../../../sui-scallop-sdk/src/repositories/market/utils.ts). 2. **Raw, as strings**: `getPoolSupplyLimit` / `getPoolBorrowLimit` return the cap as a decimal string in the asset's **base units**. These can exceed `Number.MAX_SAFE_INTEGER` — use `BigNumber` (or `BigInt`