Skip to content

Chilean economic indicators that always load

Pulso shows 10 indicators of the Chilean economy in near real time (UF, dollar, euro, CPI, UTM, Imacec, policy rate, copper, IVP and unemployment) with a grid, a historical chart, favorites and a peso converter. Behind it sits its own API, the only piece that talks to the Central Bank.

Site
pulso-cyan-zeta.vercel.app ↗
Stack
Next.js 16 (App Router), React 19, TypeScript, SWR, Chart.js
Quality
Vitest, Playwright (E2E), CI on GitHub Actions, deployed on Vercel
Role
Everything: product, architecture, backend and frontend
Pulso dashboard (interface in Spanish): chart of the observed dollar rate over the last month and a grid with Chile's economic indicators.

The problem

The first version used mindicador.cl, and in production it sometimes just didn't load. The Central Bank's official API is stable, but it isn't meant to be called from the browser: if every visitor requested the 10 indicators and their history, the calls would multiply with only a handful of users.

The decision

I built my own intermediate API: the frontend only talks to it, and it's the only thing that calls the Central Bank, with in-memory caching and a per-indicator fallback, so if one indicator fails the other nine still load.

ISO-8859-1Responses that have to be decoded by hand before they can be read as JSON.
Errors with 200 OKFailures are only signaled in the body, not in the HTTP status.
Ghost valuesDates with no real data that repeat the last value and have to be discarded.

The result

19 s0.23 s

Parallelizing the 10 calls to the Central Bank cut load time from about 19 seconds to 0.23. From then on, parallelism became an architectural requirement rather than an optimization.

Pulso historical chart showing the observed dollar rate over the last month, with 1-month, 1-year and 2-year filters.
Pulso converter: 100,000 Chilean pesos equal 2.4381 UF.
‹ Back to homeNext: Pulso UF y Dólar