{"openapi":"3.1.0","info":{"title":"StableLens API","version":"1.0.0","description":"Read-only stablecoin market data: supply, peg status and issuer facts. No key is needed: anonymous calls are rate-limited per IP. A key, when you have one, is metered against its tier. Agents can also use the MCP server described at /.well-known/mcp.json.","contact":{"name":"StableLens","url":"https://stablelens.com/api-docs"},"license":{"name":"See Terms","url":"https://stablelens.com/terms"}},"servers":[{"url":"https://stablelens.com/api","description":"Production"}],"security":[{},{"ApiKeyAuth":[]},{"BearerAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"x-api-key","description":"Optional API key. Equivalent to the Bearer form."},"BearerAuth":{"type":"http","scheme":"bearer","description":"Optional API key sent as Authorization: Bearer <key>."}},"schemas":{"Stablecoin":{"type":"object","properties":{"symbol":{"type":"string","examples":["USDC"]},"name":{"type":["string","null"]},"issuer":{"type":["string","null"]},"issuer_type":{"type":["string","null"],"examples":["Centralized"]},"governance":{"type":["string","null"]},"treasury":{"type":["string","null"]},"market_cap":{"type":["number","null"],"description":"USD."},"peg_status":{"type":["string","null"],"enum":["STABLE","MINOR_DEPEG","MAJOR_DEPEG","UNKNOWN",null]},"peg_deviation":{"type":["number","null"],"description":"Fractional deviation from the peg (0.001 = 0.1%)."},"image":{"type":["string","null"],"format":"uri"},"last_updated":{"type":["string","null"],"format":"date-time"}}},"MarketSummary":{"type":"object","properties":{"total_stablecoins":{"type":"integer"},"total_market_cap":{"type":"number"},"stable_count":{"type":"integer"},"depeg_count":{"type":"integer"},"avg_peg_deviation":{"type":"number"},"market_cap_by_type":{"type":"object","properties":{"centralized":{"type":"number"},"dao":{"type":"number"},"algorithmic":{"type":"number"}}},"health_score":{"type":"integer","description":"Share of tracked coins at peg, 0 to 100."}}}}},"paths":{"/v1/stablecoins":{"get":{"operationId":"list_stablecoins","summary":"List tracked stablecoins, largest first","parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":200,"default":50}},{"name":"status","in":"query","description":"Peg status filter. DEPEG matches both minor and major.","schema":{"type":"string","enum":["STABLE","DEPEG","MINOR_DEPEG","MAJOR_DEPEG","UNKNOWN"]}},{"name":"type","in":"query","description":"Issuer type, e.g. Centralized.","schema":{"type":"string"}},{"name":"symbol","in":"query","description":"Comma-separated symbols, e.g. USDC,USDT.","schema":{"type":"string"}},{"name":"min_mcap","in":"query","description":"Minimum market cap in USD.","schema":{"type":"number","minimum":0}}],"responses":{"200":{"description":"Stablecoins","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Stablecoin"}},"meta":{"type":"object","properties":{"count":{"type":"integer"},"timestamp":{"type":"string","format":"date-time"},"source":{"type":"string"}}}}}}}},"401":{"description":"An API key was sent but is invalid, revoked or expired.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"429":{"description":"Rate limit reached. Anonymous callers get 60 requests per minute per IP; keyed callers get their tier's daily limit. See the Retry-After header.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"500":{"description":"Server or database error.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/v1/market":{"get":{"operationId":"get_market_summary","summary":"Aggregate stablecoin market summary","responses":{"200":{"description":"Market summary","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/MarketSummary"},"meta":{"type":"object","properties":{"count":{"type":"integer"},"timestamp":{"type":"string","format":"date-time"},"source":{"type":"string"}}}}}}}},"401":{"description":"An API key was sent but is invalid, revoked or expired.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"429":{"description":"Rate limit reached. Anonymous callers get 60 requests per minute per IP; keyed callers get their tier's daily limit. See the Retry-After header.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}},"500":{"description":"Server or database error.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}}}}}}}}},"/health":{"get":{"operationId":"health","summary":"Service health check","security":[{}],"responses":{"200":{"description":"Service is up"}}}}}}