I normalised 51 million property transactions from 16 government registries — here's the bug that nearly ruined it
Property registry data is open in many countries. HM Land Registry publishes every sale in England and Wales. The Dubai Land Department publishes transactions. US counties publish deeds. It's all free, and any developer can download it this afternoon. So why did I spend a year building an API over data anyone can get? Because of a bug I want to describe, since I think it generalises well beyond…
Many governments publish property transaction data, such as HM Land Registry for England and Wales, Dubai Land Department, and US county deeds. Developers can freely download this data and build APIs around it. However, a bug in one such API nearly ruined the project. The bug is that the API returns plausible-looking results, but those results are only a small fraction of the actual transactions, leading to a two-orders-of-magnitude error in the market picture.
This issue is not limited to a single district or market, but can occur in every market with its own conventions, such as changing postcodes, towns absorbed into others, and buildings recorded under project names instead of actual owners. To address this, the API includes endpoints for resolving addresses to the correct market and reporting the coverage and recency of the data.
The API supports sixteen different markets, including the UK, France, Ireland, Singapore, Taiwan, Dubai, and ten US metros. It provides endpoints for retrieving comparable sales, statistics, trends, valuation, and even CSV and PDF exports. The API also includes two endpoints specifically to solve the mentioned bug: /v1/resolve, which determines the market for a given address, and /v1/coverage, which provides information about each market's source, geography, and current status.
The API is tested with regression tests for all sixteen markets, ensuring that any broken examples are caught early. This has enabled developers to focus on building property reasoning applications, with the data problem remaining as expensive as before.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.