Validate brazilian documents using Type Hints in classes inheriting Pydantic's (V2) BaseModel
Project description
Install
pip install brdocs-validation
Supported docs and its formats
| Supports | Format |
|---|---|
| CNPJ | 12.345.678/9012-34 OR Without special chars |
| CPF | 123.456.789-01 OR Without special chars |
| CNH | Only numbers |
Usage
from br_docs import CPF, CNPJ, CNH
from pydantic import BaseModel
class User(BaseModel):
name: str
age: int
cpf: CPF
cnpj: CNPJ
cnh: CNH
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file brdocs-validation-0.0.4.tar.gz.
File metadata
- Download URL: brdocs-validation-0.0.4.tar.gz
- Upload date:
- Size: 5.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f4628f3817691ad58cab1453ab9acff8053c4e21aecf4635d354bf8b8017374d
|
|
| MD5 |
783e5bfa5f1c4f7531db915db5fb4d0e
|
|
| BLAKE2b-256 |
80cc26fbbafda8805f710fc26bd5a126249dab3c9814c7c3789d7c91943813f7
|
File details
Details for the file brdocs_validation-0.0.4-py3-none-any.whl.
File metadata
- Download URL: brdocs_validation-0.0.4-py3-none-any.whl
- Upload date:
- Size: 6.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0d7a75db341507df624be5355987aacc79c08d60da05f6d50922065af5c4f04e
|
|
| MD5 |
7695e454609fd7e2b5d17b2b087a24e7
|
|
| BLAKE2b-256 |
317d0fdc576e88261ce73763ba59cad8e4c90dff6ae1b37fce77d613e731b0a4
|