oneapi
Sign in
Financiar v1 / CursIstoric

Exchange-rate series across the denomination

The quotations of one to five currencies between two dates, over an interval that can cross the 2005 denomination. Until now, a 1998 → today chart was impossible to draw correctly: it required two routes and the splicing of two series with a factor of 10,000 between their units.

Every point declares its own unit (denominare) and carries two figures: valoare, exactly as the NBR published it at the time, and valoare_unitara_ron, the same quantity brought to new lei. The second is the column you draw a continuous chart with; the first is the one you cite.

The multiplier sits on every point, not once per series as at /curs/interval: the forint and the yen were published per unit before 2005 and are published per 100 after. multiplicator_variabil on the series flags the case, so that nobody hoists the multiplier out of the loop.

The interval is capped at 10 years. A currency that stops before the requested end — the Deutsche Mark in 2002 — returns the partial series and appears in meta.serii_oprite, not a 404: the data requested does exist, it simply ends.

GET
https://oneapi.ro/api/financiar/v1/curs-istoric/interval

Query parameters

NameTypeDescriptionAccepted values
de_larequired string Required, YYYY-MM-DD. May be arbitrarily old — it aligns to coverage. e.g. 2024-06-15
pana_laoptional string | null Optional, defaults to the last covered day. e.g. 2024-06-15e.g. 2024-06-30
valutalistoptional text Required, 1–5 codes: ?valuta=DEM or ?valuta=EUR,USD. e.g. EUR

How it behaves

  • Quotes for one to five currencies between two dates, over an interval that may cross the 2005 denomination.
  • Until this route, a 1998 → today chart could not be drawn correctly. It took two routes and the manual splicing of two series whose units differ by a factor of 10,000 — hence the chart with a vertical jump in January 2005 and no explanation. Here the series comes from a single request, with the unit declared on every point.
  • Every point carries two figures. valoare is what NBR published at the time, in the unit of the time — the figure you quote. valoare_unitara_ron is the same quantity brought into new lei, comparable across the whole series — the column you chart. You do not pick one: both are needed, for different things.
  • The multiplier sits on EVERY point, not once per series — unlike /curs/interval, where it is constant. Across the boundary it is not: the forint and the yen were published per unit in the ROL era and are published per 100 in the RON era. Declared once, it would be wrong across half the series by a factor of 100 which, multiplied by the 10,000 of the denomination, gives a million. multiplicator_variabil flags the series where it changes.
  • denominare_schimbata and denominare_schimbata_la say whether and where the unit breaks. The boundary is 2005-01-03, the first day NBR expresses its archive in new lei — not 1 July 2005, when the legal denomination took place. The same ambiguous window /calcul/denominare declares.
  • A currency that stops before the requested end returns a partial series, not a 404. The Deutsche Mark stops in February 2002 because it ceased to exist, not because data is missing; it appears in meta.serii_oprite with the last day and the reason. A 404 would suggest the request was wrong.
  • The interval is capped at 10 years, far above the 366 days of /curs/interval, because the purpose is the opposite: there "the last 12 months", here the long series. The cap is checked AFTER the bounds are aligned to coverage, so a request "from 1990" is not refused over days that have no data anyway.
  • The right-hand bound aligns to the last covered day, not to the current day: if ingestion lags, a bound set on "today" would produce an empty tail that looks like a publication gap. Whatever was adjusted appears in meta.ajustat.

What it is for

  • Charting the exchange rate across decades, without the artificial jump in 2005.
  • The average rate over a period that crosses the denomination.
  • Following a currency up to its disappearance (Deutsche Mark, Italian lira).

Response structure

FieldTypeDescription
data.de_la string Start of the interval the response covers.
data.pana_la string End of the interval the response covers, inclusive.
data.denominare_schimbata boolean true if the interval crosses 2005-01-03.
data.denominare_schimbata_la null The day the unit breaks; null if the interval sits within one era.
data.serii array The series in the response.
meta.sursa string The official source the data comes from, with its licence where one is required.
meta.acoperire.de_la string The first period we have data for.
meta.acoperire.pana_la string The last period we have data for.
meta.zile_interval integer How many calendar days the requested interval spans.
meta.fara_valori array Requested currencies with no quote at all in the interval.
meta.nota_multiplicator string A note on how to read the response: a caveat, a convention or a limit of the source.
meta.temei_denominare string
data.serii[].multiplicator_variabil boolean true when the multiplier changes within the interval (HUF, JPY). Anyone aggregating the series cannot hoist the multiplier out of the loop.
data.serii[].valori[].denominare string ROL or RON — the unit of that point.
data.serii[].valori[].valoare string The figure published by NBR, in the unit of the time.
data.serii[].valori[].valoare_unitara string Per ONE unit of currency, in the unit of the time.
data.serii[].valori[].valoare_unitara_ron string Per ONE unit of currency, in NEW lei. Comparable across the whole series.
meta.serii_oprite Currencies whose series ends before the requested end, with the last day and the reason.
meta.ajustat Bounds aligned to coverage. Absent when nothing was adjusted.
meta.fara_date data is null and this says why. The interval lies entirely outside the archive.
meta.fara_date_cod The short, STABLE word for the reason, for clients that branch on it in code: fara_date is prose and may be rephrased, this is not.

Response examples

GEThttps://oneapi.ro/api/financiar/v1/curs-istoric/interval?de_la=2024-06-15&valuta=EUR&pana_la=2024-06-15
{
    "data": {
        "de_la": "2024-06-15",
        "pana_la": "2024-06-15",
        "denominare_schimbata": false,
        "denominare_schimbata_la": null,
        "serii": []
    },
    "meta": {
        "sursa": "BNR — arhiva cursului de schimb, ambele epoci (lei vechi şi lei noi).",
        "acoperire": {
            "de_la": "1998-01-05",
            "pana_la": "2026-09-21"
        },
        "zile_interval": 1,
        "fara_valori": [
            "EUR"
        ],
        "nota_multiplicator": "Multiplicatorul e pe fiecare punct, nu pe serie: la HUF şi JPY se schimbă odată cu denominarea (1 → 100).",
        "temei_denominare": "Legea 348/2004 — 1 RON = 10.000 ROL, în vigoare de la 1 iulie 2005."
    }
}

Error codes

CodeSlugWhen it occurs
401neautentificatToken missing, invalid, expired or revoked.
403feature_indisponibilThe current plan does not include the feature the route depends on.
422validareinterval_prea_lung (over 3,653 days), more than 5 currencies, invalid currency code, pana_la before de_la.
429cota_depasitaThe plan's monthly quota has been exceeded (see Retry-After).

All errors share the same shape. eroare.cod is stable and is the value you should branch on in code — not the text in mesaj, which may change.

{
    "eroare": {
        "cod": "validare",
        "mesaj": "interval_prea_lung (over 3,653 days), more than 5 currencies, invalid currency code, pana_la before de_la.",
        "detalii": {
            "de_la": [
                "The value sent does not satisfy the parameter rule."
            ]
        }
    }
}