GET /api/map/tariffs is the other entrance to the same data. Instead of “what
does this operator charge”, it answers “who offers a tariff like this, and how
much”.
It is what colours the public map, and it returns one figure per operator, so
you can render ~500 supply areas from a single request.
A request
The response
operators are ElCom operator ids, which match the
operator_id property on the GeoJSON features from /api/geo/dso_areas — so
joining prices to geometry is a dictionary lookup.
Read n_matched against n_total
This matters most exactly where the filter is narrowest:
Matches without a price
Five of those six dynamic operators returnrate_rp: null, priced: false. A
dynamic tariff has no fixed rate — that is the definition, not a defect.
They are still matches and are still counted. median is taken over the priced
ones only, and n_priced tells you how many that was.
If you are drawing a map, give unpriced matches their own shade rather than
dropping them or colouring them as “no data” — they are the opposite of no data.
Feed-in tariffs are excluded from this endpoint entirely. A remuneration paid to
a producer averaged into a price charged to a consumer would be a meaningless
number. Use
/api/v1/feedin instead.Handing off to the single-tariff view
The two paths share a selector, so a click on a coloured area can carry straight into Path A with the filter preserved:Drawing the map
Cache-Control, so fetch it once and keep it. See Caching and
limits.