{"openapi":"3.1.0","info":{"title":"Ulcer Index API","version":"1.0.0","description":"Ranks a cross-asset universe by how painful each market's drawdowns have been, and how much return it paid for that pain, computed live from Yahoo Finance daily closes — no key, nothing stored. Volatility treats an up-move and a down-move as equally risky, but investors only lose sleep over the downside: the depth of the fall from the last high and how long it drags on before recovering. The Ulcer Index (Peter Martin) captures exactly that — the root-mean-square of every day's percentage drawdown from the running peak, so a deep, long drawdown is penalised far more than a brief dip and a market that keeps making new highs scores near zero. From it comes the Martin ratio (the Ulcer Performance Index) — annualised excess return divided by the Ulcer Index — the return earned per unit of drawdown pain, a downside-only cousin of the Sharpe ratio. The asset endpoint returns one instrument's full pain profile: Ulcer Index, maximum, average and current drawdown, longest time underwater, the Martin ratio and the pain ratio. The screener endpoint ranks the 21-instrument universe (equities, sectors, commodities, bonds, crypto; filterable by class) by Martin ratio (best pain-adjusted return) or by Ulcer Index (smoothest ride). This is the drawdown-pain / Ulcer-Index cut — distinct from a current-drawdown monitor (a point-in-time snapshot of how far below peak each market is), the Sharpe/Sortino/Calmar screener (Calmar uses only the single worst drawdown) and the price APIs. It scores the whole shape of the pain, not one point of it.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/ulcerindex-api","description":"oanor gateway"}],"tags":[{"name":"Screener"},{"name":"Asset"},{"name":"Universe"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/screener":{"get":{"operationId":"get_v1_screener","tags":["Screener"],"summary":"Rank the universe by Martin ratio or Ulcer Index","description":"","parameters":[{"name":"metric","in":"query","required":false,"description":"martin (best pain-adjusted return) or ulcer (smoothest)","schema":{"type":"string"},"example":"martin"},{"name":"window","in":"query","required":false,"description":"Lookback in trading days (60-756)","schema":{"type":"string"},"example":"252"},{"name":"class","in":"query","required":false,"description":"equity, sector, commodity, bond, crypto or all","schema":{"type":"string"},"example":"all"},{"name":"rf","in":"query","required":false,"description":"Annual risk-free percent (0-20)","schema":{"type":"string"},"example":"0"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/asset":{"get":{"operationId":"get_v1_asset","tags":["Asset"],"summary":"Full drawdown-pain profile of one instrument","description":"","parameters":[{"name":"symbol","in":"query","required":true,"description":"Universe symbol","schema":{"type":"string"},"example":"GLD"},{"name":"window","in":"query","required":false,"description":"Lookback in trading days (60-756)","schema":{"type":"string"},"example":"252"},{"name":"rf","in":"query","required":false,"description":"Annual risk-free percent (0-20)","schema":{"type":"string"},"example":"0"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/universe":{"get":{"operationId":"get_v1_universe","tags":["Universe"],"summary":"The cross-asset universe and its classes","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Service metadata","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK"},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":760,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":1090,"monthly_call_quota":16400,"rps_limit":6,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":3480,"monthly_call_quota":88000,"rps_limit":16,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":7860,"monthly_call_quota":488000,"rps_limit":40,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/ulcerindex-api"}