A handy tool for matching post codes with regions in New Zealand. This tool groups post codes into regions that can be used for things like calculating shipping/postage costs etc.
A common use-case is having postage costs stored in a database/CMS for each of the regions. Then depending on a customers post code we can determine what region and cost.
npm install nz-postage-regions
yarn add nz-postage-regions
import { getRegion } from 'nz-postage-regions';
const postageRegion = getRegion(postalCode);
-
Rural
- northIslandRural
- southIslandRural
-
Non Rural
- northland
- auckland
- waikato
- gisborneHawkesBay
- bayOfPlenty
- taranakiManawatuWhanganui
- wellington
- nelsonMarlboroughTasman
- canterburyWestCoast
- otago