Skip to content
Zonio Developers

Provenance & pipeline

Behind the API is a purpose-built geospatial ETL. Knowing how it works tells you how far to trust each answer.

From source to API

 public source ──fetch──▶ staging ──transform──▶ working copy ──validate──▶ clean table ──▶ API · MCP · tiles
 (WFS, ArcGIS,             raw rows               reproject to               atomic swap
  ATOM, WMS, files)        + run id               EPSG:2180, fix              per run
                                                  geometries
  • Fetch. Each of ~45 topics has its own fetcher for its source's protocol: OGC WFS with adaptive tile paging, ArcGIS REST, ATOM/GML downloads, per-powiat BDOT10k packages, WMS sampling, Overpass. Fetchers compare what they received against the server's own feature count and fail loudly on a shortfall.
  • Transform. Geometry is reprojected to EPSG:2180 and validated; invalid shapes are repaired, and anything that still fails goes to a dead-letter queue for inspection instead of aborting the run.
  • Promote. Data reaches the clean table in one atomic step. A failed run leaves the previous version in place.
  • Index. GiST spatial indexes on every geometry; large tables are partitioned by gmina so a regional query only touches that region.

Every row is traceable

Each row in every table carries:

ColumnMeaning
source_run_idThe pipeline run that produced it
fetched_atWhen it was fetched
source_urlThe exact endpoint it came from
source_bboxThe area that run covered

Detail endpoints expose this as a provenance object, so you can always show "from GDOŚ, fetched 2026-09-28" next to a constraint, or audit an answer months later.

Normalisation

  • Zoning symbols. Thousands of local spellings (MN, MN1, 1MN/U, M.N.) are mapped to a common taxonomy of categories; the raw symbol is always kept and anything unrecognised is flagged for review instead of guessed.
  • Coordinates. One storage CRS for everything, so a distance is always metres. See Coordinates.
  • Identifiers. Parcels keyed by EGiB id, regions by TERYT, so data from any source joins cleanly.

Quality checks

After each national load we check row counts against the publisher's totals and look at the category breakdown. A category with zero rows nationally is treated as a bug until proven otherwise. Verification dates and national counts are recorded per layer.