Skip to content

getCityByPostalCode

function getCityByPostalCode(postalCode): string | null;

Defined in: postal.ts:48

Returns the city for a Pakistani postal code.

Only codes of post offices in a city on pakdatakit’s city list return a city (54660 → Lahore). The code of a post office in a town or village that is not on the list returns null; use getPostOffice for those.

Parameter Type Description
postalCode string Postal code to look up (whitespace is ignored)

string | null

City name or null if not found