Nida
Unofficial package for fetching users information based on National ID Number made by kalebu
Installation
You can install it directly or using pip
Here how to install directly
git clone https://github.com/Kalebu/Nida
cd Nida
Nida -> python setup.y install
Here how to install from pip
pip install nida
Usage
To fetch user information based on ID number do this;
>>> from nida import load_user
>>> user_detail = load_user(national_id='XXXXXXXXX')
>>> print(user_detail)
user
{'Nin': 'XXXXXX', 'Firstname': 'XXXXXX', 'Middlename': 'XXXXXX', 'Surname': 'XXXXXX', 'Othernames': 'XXXXXX', 'Sex': 'XXXXXX', 'Dateofbirth': 'XXXXXX', 'Residentregion': 'XXXXXX', 'Residentdistrict': 'XXXXXX', 'Residentward': 'XXXXXX', 'Residentvillage': 'XXXXXX', 'Residentstreet': 'XXXXXX', 'Residentpostcode': 'XXXXXX', 'Permanentregion': 'XXXXXX', 'Permanentdistrict': 'XXXXXX', 'Permanentward': 'XXXXXX', 'Permanentvillage': 'XXXXXX', 'Permanentstreet': 'XXXXXX', 'Birthcountry': 'XXXXXX', 'Birthregion': 'XXXXXX', 'Birthdistrict': 'XXXXXX', 'Birthward': 'XXXXXX', 'Nationality': 'XXXXXX', 'Phonenumber': 'XXXXXX', 'Maritalstatus': 'XXXXXX', 'Occupation': 'XXXXXX', 'Primaryschooleducation': 'XXXXXX', 'Primaryschooldistrict': 'XXXXXX', 'Primaryschoolyear': 'XXXXXX', 'Photo': 'XXXXXX', 'Signature': 'XXXXXX', 'Nationalidnumber': 'XXXXXX', 'Lastname': 'XXXXXX'}
You can access user infromation by using keys and attributes just as shown below;
>>> user_detetail['Firstname']
'XXXXXX'
>>> user_detail.get('Middlename')
'XXXXXX'
>>> user_detail.Lastname
'XXXXXX'
Image and Signature are currently not supported (Depreciated !!)
National ID Photo and Signature are auto converted into PIL Images and you can easily save just as shown below;
>>> user_detail.Photo.save('National_ID.png')
>>> user_detail.Signature.save('Signature.png')
If you want the data to be in the same from an API without any side effect preprocessing do this instead while loading user;
>>> user_detail = load_user('xxxxxxxxxx', json = True)
>>> print(user_detail)
{
....
}
Give it star
Did you find this repository useful to you ? Well then give it a star so as more people can get to know about it;
Issues
Are you facing any issue with usage of the package, just raise an issue and I looking to fixing it as soon as I can.
Contributions
If there is anything yould would like to add warmly welcome, Just fork it
Disclaimers
This is not an official package, therefore I'm not responsible for any misinformation or misuse of the package of any kind !!!
Credits
All the credits to Kalebu and StackOverflow comment from dbrax
Metadata
Release files for nida 0.1.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| nida-0.1.7-py3-none-any.whl | Python 3 | none | any | Details |
Release files / nida-0.1.7-py3-none-any.whl
| Download URL | nida-0.1.7-py3-none-any.whl |
|---|---|
| Size | 3.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6326f34da19327ed2f0ab578d0bf3d5f56324d9ac6ad521a445d30b87fb385d2
|
|
BLAKE2b-256 checksum How to use checksums |
ca8d35b0cc59e481231fb644ea3c73538cf4041ac598d1376a5e68efabe94718
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.8.10
|
Security for nida 0.1.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.