Skip to main content

Python için TCKN (TC Kimlik No) ve VKN (Vergi Kimlik No) doğrulama kütüphanesi.

Project description

tcknvkn (Python)

tcknvkn, Türkiye Cumhuriyeti Kimlik Numarası (TCKN) ve Vergi Kimlik Numarası (VKN) doğrulaması için geliştirilmiş hafif bir Python kütüphanesidir.

Bu paket yalnızca algoritmik/format doğrulaması yapar; resmi kurum sorgusu yapmaz.

Kurulum

pip install tcknvkn

Hızlı başlangıç

from tcknvkn import (
    validate_tckn,
    validate_multiple_tckn,
    validate_vkn,
    validate_multiple_vkn,
)

tekil_tckn = validate_tckn("10000000146")
print(tekil_tckn.valid)   # True
print(tekil_tckn.errors)  # []

tekil_vkn = validate_vkn("1000036109")
print(tekil_vkn.valid)    # True

sonuclar = validate_multiple_tckn(["10000000146", "10000000145", "11111111111"])
for sonuc in sonuclar:
    print(sonuc.value, sonuc.valid, sonuc.errors)

API özeti

  • validate_tckn(value: str) -> ValidationResult
  • validate_multiple_tckn(values: list[str]) -> list[ValidationResult]
  • validate_vkn(value: str) -> ValidationResult
  • validate_multiple_vkn(values: list[str]) -> list[ValidationResult]

ValidationResult

from dataclasses import dataclass

@dataclass(frozen=True)
class ValidationResult:
    valid: bool
    value: str
    errors: list[str]

Test çalıştırma

python -m unittest discover -s tests

İlgili bağlantılar

Lisans

MIT

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

tcknvkn-1.0.3.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tcknvkn-1.0.3-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file tcknvkn-1.0.3.tar.gz.

File metadata

  • Download URL: tcknvkn-1.0.3.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tcknvkn-1.0.3.tar.gz
Algorithm Hash digest
SHA256 aafd583dd41b5be3664e844c4e3d5aaae21baa20486533fdacae4f195b4c1792
MD5 a08b41426c7ade1162678c3b491130f5
BLAKE2b-256 bf7303531f90c13cdf60ab85f78a186ba4321f1e4e6ec5617421c4df86b33199

See more details on using hashes here.

Provenance

The following attestation bundles were made for tcknvkn-1.0.3.tar.gz:

Publisher: ci.yml on tcknvkn/tcknvkn-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file tcknvkn-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: tcknvkn-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tcknvkn-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 5c58d40517a9192cecb1bc1bd1cec9553733689151dff120fe14a900700c7d7c
MD5 1afb787a0fd3708d7ec4be7ebcda53e7
BLAKE2b-256 de11f3cb4c5094f4946a3e68e3b9ba3327ae12819e163c6f98d798b0760a7a68

See more details on using hashes here.

Provenance

The following attestation bundles were made for tcknvkn-1.0.3-py3-none-any.whl:

Publisher: ci.yml on tcknvkn/tcknvkn-python

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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