Validate ID numbers of Saudi Arabian identity cards
Project description
A Python package to validate ID numbers of Saudi Arabian identity cards for both citizens and residents.
The validation formula is based on Luhn algorithm which is in wide use today by many governments to distinguish valid numbers from mistyped or otherwise incorrect numbers.
Installation
$ pip install saudi-id-validator
Basic Usage
To validate an ID:
from saudi_id_validator import validate
v = validate(1071724369)
print(v)
# False
The validate method will return a boolean (True or False) indicating whether ID is valid or not.
License
This package is distributed under an MIT licence. See LICENSE file.
Change Log
v1.0.4
Updated README.
v1.0.3
Updated usage example.
Updated README badges.
Removed LICENSE file extension.
v1.0.2
Improved README content.
v1.0.1
Fixed some typos in README file.
v1.0.0
First release.
Project details
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 saudi-id-validator-1.0.4.tar.gz
.
File metadata
- Download URL: saudi-id-validator-1.0.4.tar.gz
- Upload date:
- Size: 3.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0e82569bbbf9117ec10012b4e4b91965a137883bc8e77327b8b53877fa9368c7 |
|
MD5 | f2c4681a53be4329cd79865a8cbc2626 |
|
BLAKE2b-256 | be897c9a33d71f978aa4c8850c34728ea6b94ede239d3517c1fee7f9616d1bb9 |
File details
Details for the file saudi_id_validator-1.0.4-py3-none-any.whl
.
File metadata
- Download URL: saudi_id_validator-1.0.4-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed5b8fe2866f163a2eeb403086910d875b8f917c73923a552c0f8184f086a7fd |
|
MD5 | 82316ab0ce8a433e7931e491442cec86 |
|
BLAKE2b-256 | d6efebef01cb189dde2e6bb013619ba6cbe94e1a7f3a70cedfc3881b572d7251 |