Python package for mapping pins to the place where it belong
Project description
indiapins
Indiapins is a Python package for getting the places tagged to particular Indian pincode
Data is last updated of 10, August, 2024, with 157177 area pin codes
Free software: MIT license
Documentation: https://pawangeek.github.io/indiapins/
Github Repo: https://github.com/pawangeek/indiapins
Installation
Install the plugin using ‘pip’:
$ pip install indiapins
Alternatively, install from source by cloning this repo then running ‘setup.py’:
$ python setup.py install
Features
Get all the mappings of given pins
The Python sqlite3 module is not required, so easily to use in Clouds (no additional dependencies)
Works with 3.9, 3.10, 3.11, 3.12, 3.13 and PyPy
Cross-platform: Windows, Mac, and Linux are officially supported.
Simple usage and very fast results
Examples
1. Exact Match
To find the names of all places, districts, circles and related information by given Indian Pincode
Important: The Pincode should be of 6 digits, in string format
indiapins.matching('110011')
[{'Name': 'Nirman Bhawan', 'BranchType': 'Sub Post Office', 'DeliveryStatus': 'Delivery', 'Circle': 'Delhi', 'District': 'Central Delhi', 'Division': 'New Delhi Central', 'Region': 'Delhi', 'Block': 'New Delhi', 'State': 'Delhi', 'Country': 'India', 'Pincode': '110011'},
{'Name': 'South Avenue', 'BranchType': 'Sub Post Office', 'DeliveryStatus': 'Non-Delivery', 'Circle': 'Delhi', 'District': 'Central Delhi', 'Division': 'New Delhi Central', 'Region': 'Delhi', 'Block': 'New Delhi', 'State': 'Delhi', 'Country': 'India', 'Pincode': '110011'},
{'Name': 'Udyog Bhawan', 'BranchType': 'Sub Post Office', 'DeliveryStatus': 'Non-Delivery', 'Circle': 'Delhi', 'District': 'Central Delhi', 'Division': 'New Delhi Central', 'Region': 'Delhi', 'Block': 'New Delhi', 'State': 'Delhi', 'Country': 'India', 'Pincode': '110011'}]
2. Valid Pincode
To check if the given Pincode is valid or not
indiapins.isvalid('110011')
True
3. District by Pincode
It extracts the district of given Indian pincode
indiapins.districtmatch('302005')
'Jaipur'
4. Coordinates of Pincode
It extracts all the coordinates of given Indian pincode
indiapins.coordinates('110011')
{'Udyog Bhawan': {'latitude': '28.6111111', 'longitude': '77.2127500'},
'Nirman Bhawan': {'latitude': '28.6108611', 'longitude': '77.2148611'}}
History
1.0.1 (2024-08-10)
Added latest libs
1.0.1 (2023-09-12)
Fix pins import error
0.1.7 (2023-09-11)
Update Pincode data to latest (Sept 2023)
Added coordinates info with pins
Fetch longitude and latitude of any pin
Update security vulnerabilities
0.1.0 (2021-07-27)
Match location with the pins
Mark pin is valid or not
Extract cities on basis of pins
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file indiapins-1.0.3.tar.gz
.
File metadata
- Download URL: indiapins-1.0.3.tar.gz
- Upload date:
- Size: 2.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b63a77bbaf77905366603f6ee7e4711cae259342f41ac089727a152c67812d7d |
|
MD5 | 91468b0b62055bb31fccda8bc4b8fce4 |
|
BLAKE2b-256 | 59ebc108e80e0045d148b9d3ae07ef742997500ef619ba0d9f8a385c79b8d155 |
File details
Details for the file indiapins-1.0.3-py2.py3-none-any.whl
.
File metadata
- Download URL: indiapins-1.0.3-py2.py3-none-any.whl
- Upload date:
- Size: 2.3 MB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 960e4239d9b349281ebdeac9cfcedea7ef6743479246977c16baa73a58c37fa7 |
|
MD5 | e39c8ec7ccbcb8607c2b24f91403d0d4 |
|
BLAKE2b-256 | 781aa4509073c10fedccef17fe5f4725faefd98c4cb6fc976acce2a44e0b2fc9 |