Admin boundaries: richer response + SDK v0.2.0
/v1/admin-boundaries now returns province_name, population, area_km2, centroid, and more for every polygon. @gogoduk/[email protected] surfaces them as optional types.
/v1/admin-boundaries shipped on day one with a deliberately minimal
response — just name and boundary. The underlying vn_admin_boundaries
table has always carried more than that, and today we surface the rest.
New optional fields on every boundary
province_name,province_id— parent province per district (no more client-side joins)population,area_km2— for density rollups and service-area planningpre_merge_info— human-readable note about the unit's most recent reorganisation, useful for resolving old addresses after the 2025 provincial consolidationadmin_center— seat of government city/townphone,website— official contact info where publishedcentroid— single[lng, lat]point per unit, cheaper than measuring polygon centroids client-side
Coverage is 100% for both levels (34/34 provinces, 3,323/3,323 districts).
Backwards-compatible
name and boundary keep their existing shape. All new fields are
optional in both the JSON response and the TypeScript types — existing
@gogoduk/[email protected] consumers continue to work without code changes.
SDK v0.2.0
@gogoduk/[email protected] ships
the additive types today. pnpm add @gogoduk/sdk@latest and the new
fields show up on the AdminBoundary type with no other changes needed.
Updated dataset deep-dive: Vietnam admin boundaries: 34 provinces, 3,323 districts, and rich metadata.