Building a free airtime price API for Nigerian VTU services
If you are running a small digital operation out of a co-working space in Sydney or a home office in Brisbane, the chance that your customers or clients might one day want to send airtime to a contact in Lagos is higher than you might think. The Nigerian VTU ecosystem moves millions of dollars every week through tiny micro-transactions, and resellers, side hustlers, and community platforms across the Australian diaspora regularly need accurate price lists to stay competitive when topping up phones for relatives back home.
This walkthrough shows how to build a free API endpoint that returns real-time airtime prices for Nigerian networks, using open-source tools and free-tier hosting services. By the end you will have a small JSON service that any front-end, Telegram bot, or reseller dashboard can ping, without paying a single dollar to a cloud provider or an upstream data vendor.
Why real-time airtime pricing matters for resellers
Airtime in Nigeria is sold by the four major carriers, MTN, Glo, Airtel, and 9mobile, and each operator runs dozens of discounted rates that change weekly, sometimes daily. Resellers who rely on stale data lose money on every transaction because they quote customers one rate and then the VTU backend sends a different amount after fees and bonus adjustments. A live airtime price API fixes this by pulling current rates from a provider like VTpass, ClubKonnect, or a carrier's own SME portal and exposing them in a clean, machine-readable format.
For an Australian developer thinking about cross-border tooling, this is a tidy niche. You can serve local customers who need to recharge phones for relatives back home, or you can plug your endpoint into a larger content site that already gets Nigerian traffic. The market is fragmented enough that there is room for small, focused services rather than one monolithic global platform, and the regulatory environment is light enough that a single developer can ship a useful tool in a weekend.
Picking a free stack for your endpoint
You do not need anything fancy to host this kind of service. A typical setup combines a lightweight scraper written in Node.js or Python, a serverless function on a platform like Vercel, Netlify, or Cloudflare Workers, and a small cache layer so you do not hammer the source every time someone refreshes a dashboard. All three hosts have generous free tiers that comfortably handle hundreds of thousands of requests per month, which is more than enough for a bootstrapped VTU side project even if it gets shared on a popular WhatsApp group.
If you prefer a slightly different approach, Railway and Fly.io both offer free monthly credits that work well for long-running scrapers that wake up on a cron schedule. Many devs in Melbourne's startup scene lean on these because the deployment story feels closer to a traditional server than to a function-as-a-service model. Pick whichever stack matches your comfort level, because the code itself is simple enough to port between hosts in an afternoon if your first choice starts to feel awkward.
Writing the price-fetching logic
The core of your endpoint is a function that fetches rates from at least one provider and normalises them into a consistent JSON shape. In Node, this often looks like an async function that calls the provider's REST endpoint, parses the response, and then maps each network's discount percentage, bonus amount, and minimum recharge into a single object per carrier. You will also want a timestamp field so clients know how fresh the data is, which matters more than it sounds during volatile periods like festive seasons or carrier flash sales.
Python developers often reach for requests plus BeautifulSoup when the upstream does not expose a clean API, scraping the SME portal directly. This works but introduces a maintenance burden because layout changes break the script, so it is worth setting up a friendly retry loop and a fallback provider. Either way, the function should return something like { network: "MTN", rate: 96.5, bonus: 5, updated: "2026-..." } so the consumer side stays predictable regardless of which upstream you choose to trust today.
Deploying your free endpoint
Once the logic is solid, deploying it as a serverless function is mostly a matter of dropping the code into a project folder and pushing to Git. Vercel and Netlify both detect Node or Python automatically and expose a public URL as soon as the build finishes, and Cloudflare Workers works similarly but expects you to use the Workers KV or D1 for any persistent state, which is fine for a simple price cache that you only read from.
To keep the endpoint free in production, add a scheduled trigger that refreshes the cache every fifteen or thirty minutes. The user-facing endpoint then simply returns the cached JSON without making a network call to the upstream provider on every request. This pattern keeps you inside free-tier limits even if your endpoint gets picked up by an aggregator or mentioned on a busy Telegram channel, and it also makes response times fast enough to feel snappy on mobile networks where many Nigerian users live.
Securing and documenting the API
Even a free endpoint benefits from basic protection. Add a simple rate limit using the host's built-in middleware or a tiny token-based check, so random callers cannot exhaust your free quota or accidentally turn your service into a denial-of-yourself incident. Document the schema in a README or a small OpenAPI file, and include a curl example so less technical users, including the tradie who runs a phone-recharge booth on the side and wants to compare rates before placing an order, can hit the endpoint without reading your source code.
If you want to go a step further, expose the endpoint through a community forum or a Q&A board so other developers can suggest improvements. Australian open-source communities, particularly the ones around the Brisbane and Perth meetups, are pretty welcoming of new contributors and can spot edge cases you might miss, such as handling NBN-fluctuating upload speeds when scraping from home. A short changelog in the repo also helps anyone who relies on the API track breaking changes without surprises.
Plugging the endpoint into a VTU site or store
With the endpoint live, you can wire it into a reseller dashboard, a Telegram bot, or a content site. A common pattern is to fetch the latest rates on page load, render a comparison table for visitors, and let them click through to your preferred provider. If you are selling related digital products, a guide on free online store setup walks through the rest of the pipeline, from catalogue to checkout, without leaving the free tier.
You can also expose the same JSON to other developers by publishing it under a permissive licence, which sometimes attracts unexpected integrations from community forums or side projects. Over time, a small free endpoint like this can become the data backbone for a much larger toolset, especially if you treat it as a learning project rather than a finished product.
Drop your repo link in the community Q&A or share which free host worked best for you, and pair the endpoint with a simple reseller page so visitors can actually do something with the prices. The combination of cheap upstream data, generous free hosting, and a clear JSON contract makes this a fun weekend build that can quietly grow into something useful for resellers on both sides of the equator.