✨ https://ratesapi.nz ✨
Rates API is a free OpenAPI service to retrieve the latest lending rates offered by New Zealand financial institutions – updated hourly.
Setup • GitHub • Documentation
This project uses Bun, Hono and Cloudlfare Workers.
Cloudflare Workers is a JavaScript edge runtime on Cloudflare CDN.
You can develop the application locally and publish it with a few commands using Wrangler. Wrangler includes a transcompiler, so we can write directly in TypeScript.
bun i
Run the development server locally. Then, access http://localhost:8787
in your web browser.
bun run dev
First, create your worker via the Cloudflare dashboard by following these steps:
- Log in to the Cloudflare dashboard and select your account.
- Select Workers & Pages > Create application.
- Select Create Worker > Deploy.
Then, deploy the worker using the following command:
bun run deploy
Check out the available scripts within ./bin
to scrape and save data.
e.g.
bun run bin/scrape-mortgage-rates.ts