Skip to main content

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.

Build Status Coverage Status Supported versions PyPI Package version License

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 -U 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 license. See LICENSE file.

Change Log

v1.0.5

  • Added params to docstrings

  • Fixed a typo in README.

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

saudi-id-validator-1.0.5.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

saudi_id_validator-1.0.5-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file saudi-id-validator-1.0.5.tar.gz.

File metadata

  • Download URL: saudi-id-validator-1.0.5.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

Hashes for saudi-id-validator-1.0.5.tar.gz
Algorithm Hash digest
SHA256 d4f88608ba9b7df5e56da2c8fc420d7763588b264a22f65fac3290e38e7999d5
MD5 f8f530be0f82fb6f683653e3514cd38e
BLAKE2b-256 17f3f6300d2a82952fb077640f6ec2c8024652d582a97ac2641b734404d2e08c

See more details on using hashes here.

File details

Details for the file saudi_id_validator-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: saudi_id_validator-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 3.4 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

Hashes for saudi_id_validator-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 3ab81074f3c8cd2ae3ca8304d59552440aa17fabda02d4c777506490ccdd7b5b
MD5 3e3d76f160bad89fbc0ba8577e967372
BLAKE2b-256 44059e5a4ddbb8e89c61ebe073384f82cbed12f686b8d3c520dc9aa138949714

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page