API Reference
/drawdown Endpoint
Maximum peak-to-trough decline of a currency vs a base, with peak/trough/recovery dates.
Endpoint
GET https://api.currency-core.com/v1/drawdown
Finds the worst peak-to-trough decline (“maximum drawdown”) of a currency
against a base over a window: the deepest fall from a high to a subsequent low,
plus the peak, trough, and recovery dates. Useful for “what was EUR’s worst
decline against USD?” or “biggest GBP crash in the last decade”.
Plan requirement
/v1/drawdown is available on the Growth plan and higher. Free / Starter keys
receive HTTP 403 forbidden.
Query parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
currency | string | No | Currency to measure (3-letter ISO 4217), or a comma-separated list. Omit to RANK the liquid set by drawdown. |
base | string | No | Base currency to measure against. Default USD. |
from | string | No | Window start YYYY-MM-DD (UTC). Default: 365 days before to. |
to | string | No | Window end YYYY-MM-DD (UTC). Default: today. |
sort | string | No | Ranking direction: deepest (largest decline first, default) or recovery (fastest recovery first). |
universe | string | No | Ranking universe: liquid (default) or majors. |
limit | number | No | Ranking: how many to return (default 10, max 50). |
The drawdown is measured in the quoted rate (units of currency per 1 base).
maxDrawdownPct is signed; recoveryDate is null (and recoveryDays too) if the
rate hadn’t returned to its prior peak by to. Omit currency to get a ranking,
e.g. “which currencies had the largest drawdowns” or “fastest recovery”.
Example
EUR’s worst decline vs USD over the last 10 years:
curl "https://api.currency-core.com/v1/drawdown?currency=EUR&base=USD&from=2016-06-17" \
-H "Authorization: Bearer cc_live_your_key"const res = await fetch(
"https://api.currency-core.com/v1/drawdown?currency=EUR&base=USD&from=2016-06-17",
{ headers: { Authorization: "Bearer cc_live_your_key" } },
);
console.log((await res.json()).results[0]);import requests
res = requests.get(
"https://api.currency-core.com/v1/drawdown",
params={"currency": "EUR", "base": "USD", "from": "2016-06-17"},
headers={"Authorization": "Bearer cc_live_your_key"},
)
print(res.json()["results"][0]){
"base": "USD", "from": "2016-06-17", "to": "2026-06-17", "mode": "compare",
"results": [
{
"currency": "EUR",
"maxDrawdownPct": -18.4,
"peakDate": "2018-02-15",
"troughDate": "2022-09-27",
"recoveryDate": null,
"recoveryDays": null
}
]
}
Which currencies had the largest drawdowns (ranking):
curl "https://api.currency-core.com/v1/drawdown?base=USD&period=10y&sort=deepest&limit=10" \
-H "Authorization: Bearer cc_live_your_key"
(Use sort=recovery for the fastest to bounce back.)
Errors
| Status | Code | When |
|---|---|---|
400 | invalid_input | currency missing, a bad code, or from after to. |
403 | forbidden | Your plan is below Growth (Free / Starter). |