@unmap/elevation
v0.14.0
Published
Typed client for the unmap elevation API (Canadian ground elevation)
Maintainers
Readme
@unmap/elevation
Ground elevation anywhere in Canada, from NRCan's national 30 m DEM.
import { Elevation } from "@unmap/elevation";
const elevation = new Elevation({ key: "um_live_..." });
const [metres] = await elevation.get([-114.0719, 51.0447]);Heights are metres above the CGVD2013 geoid. null means the dataset covers nothing there; it
never means sea level.
An unconfigured terrain archive throws ElevationError with status 404 and code not_found
(terrain archive not configured). A terrain tile that will not decode is status 502 and code
upstream_error (elevation sample failed). That 502 has no Retry-After. The client still
retries it, on its own backoff. A coordinate the archive does not cover stays null.
@unmap/sdk exposes the same object as unmap.elevation. Full documentation:
https://unmap.dev/docs/apis/elevation.
