Skip to main content

Pyfiscal calculation of tax data.

Project description

Calculation of tax data in México

Features [x] Support for Python 2.7-3.8

Installation

Install pyfiscal.

pip install pyfiscal

CURP

The Clave Única de Registro de Población (CURP) is a unique 18 character alphanumeric identity code for both Mexican residents and citizens.

alt picture

RFC

The Federal Taxpayer Registry is a code used in Mexico to distinguish each individual or company required to pay taxes. The people or organizations that have their RFC are called contributors.

1.- Physical person:

alt picture

This homoclave will be designated by the SAT, reviewing the request through already designated official paper.

NSS

The Social Security Number (NSS) is unique, permanent and nontransferable and is assigned to keep a record of workers and insured.

alt picture

Validation:

  • Only 11 digits will be validated.
  • Validation by the Luhn algorithm.
  • Calculate the last digit.

Unit Tests

python -m unittest tests/data_fiscal_test.py

python -m unittest tests/validator_test.py 

License

See LICENSE for more details (The MIT License).

References

https://es.wikipedia.org/wiki/Algoritmo_de_Luhn

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

pyfiscal-2.1.1.tar.gz (12.9 kB view hashes)

Uploaded Source

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