indian-pincode-search
v1.0.3
Published
Details of Post Office by searching Postal PIN Code or Post Office Branch Name of India.
Downloads
5
Readme
About this package
Details of Post Office by searching Postal PIN Code or Post Office Branch Name of India.
Installation
Use the package to install into your project 😎
npm i indian-pincode-search
Usage
import { getNamesbyPincode, getPincodeByName } from "indian-pincode-search";
(async () => {
console.log(await getNamesbyPincode(760008));
})();
#returns
[
{
name: 'Industrial Estates',
district: 'Ganjam',
state: 'Odisha',
country: 'India'
},
{
name: 'Lanjipalli',
district: 'Ganjam',
state: 'Odisha',
country: 'India'
}
]
#Error handling
(async () => {
console.log(await getNamesbyPincode(760005558));
})();
#returns
No records found
(async () => {
console.log(await getPincodeByName("lanjipalli"));
})();
# returns
[
{
pincode: '760008',
district: 'Ganjam',
state: 'Odisha',
country: 'India'
}
]
#Error handling
(async () => {
console.log(await getPincodeByName("jsksjshsjnsnhj"));
})();
#returns
No records found