Building VisaDB: visa data you can trace back to the source
How VisaDB turns official government pages into a visa data API, with AI doing the reading and people deciding what's true.

Visa rules are scattered across hundreds of government websites. They change without notice, and they're written for people, not software. Every booking site, airline and visa service needs the same answers: does this traveler need a visa, which one, what does it cost, and what do they have to provide? Keeping track of all that by hand doesn't scale.
VisaDB is my attempt at doing this properly: a visa data API where every answer can be traced back to the official page it came from.
One rule
The whole platform follows one rule: crawler finds, AI suggests, human approves, API publishes.
AI is good at reading a long government page and pulling out the rules. It's also capable of being confidently wrong, and a wrong visa answer can leave someone stuck at an airport. So in VisaDB, AI output is only ever a suggestion. Nothing reaches the API until it has been approved, and every approved rule keeps a link to the evidence it came from.

Reading a whole government website
You register an official source and give it a trust level. The site crawler starts from one page and maps the rest of the site, following its sitemaps and internal links. It reads plain pages, pages that need a real browser to render, and PDFs. It respects robots.txt, and it never tries to get past logins, CAPTCHAs or bot protection.
Every captured page is saved as evidence: the text, details about the capture, and the structure of any application form on the page. A crawl of one site can capture a couple of hundred pages.
Two AI passes, to keep costs sane
Sending a couple of hundred pages to a large model would be slow and expensive, and most of them are contact pages and news. So there are two passes:
- A fast, cheap model labels every page: visa rule, eligibility, fee, document, or irrelevant.
- Only the relevant pages go to a stronger model, which turns them into candidate rules with a confidence score.
Classification is something a person starts, not something that runs automatically, so the AI bill stays under control.

Review that scales
Early on, every candidate went to a person, and the review queue quickly became the bottleneck. The fix was tiered review. Candidates with high confidence that come from a primary official source are approved automatically. Everything else still waits for a reviewer, and a reviewer can override any automatic approval. The queue shows how many were auto-approved and how often people disagreed.

Publishing like code
Approving a rule doesn't publish it. Publishing is its own step, treated a bit like deploying code. You preview what will change, VisaDB skips anything whose content hasn't changed, every publish creates a new version, and any rule can be rolled back to an earlier one.
The API itself only reads published data and its cache. It never crawls or calls AI while a client waits, so answers stay fast and predictable.
Forms, not just rules
Visa services also need to know what the official application form asks for. When the crawler captures a page with a form, it records every field: its name, type, whether it's required, and its validation. AI maps those raw fields to standard names like passport_number or date_of_birth, a person approves the result, and the form becomes available through the API.

Built in a week
VisaDB was built between 26 and 31 May 2026, in 31 numbered phases. I worked with two Claude sessions: one acting as project lead, writing a spec for each phase and checking the result against it, and one in VS Code writing the code. A long master document holds the hard rules, like no hardcoded countries or fees, ISO codes everywhere, and no AI in the live request path, so every phase starts from the same picture.
The result is a monorepo with a NestJS API, an admin app, a customer portal and a background worker, with 75 data models and 119 test files.
What's next
VisaDB isn't public yet. Developer docs, an SDK and embeddable widgets are next, and then the long job of filling it with real, reviewed data.
About the screenshots
The screenshots come from a copy of the admin app fed with invented sample data. "Arcadia" is a fictional country, so none of the rules shown are real.
- visadb
- nestjs
- ai
- crawling