tck_no

Crates.iotck_no
lib.rstck_no
version1.0.2
sourcesrc
created_at2021-12-13 12:57:16.404878
updated_at2021-12-14 22:44:40.308753
descriptionTurkish Citizenship ID Validator and Generator Library for Rust
homepage
repositoryhttps://github.com/peacecwz/tck_no/
max_upload_size
id497105
size7,496
Baris Ceviz (peacecwz)

documentation

README

tck_no

Turkish Citizenship ID Validator and Generator Library for Rust

Crates.io version Download docs.rs docs

API Docs | Releases

Installation

With cargo add installed run:

$ cargo add tck_no

Generate TC Identity


use tck_no::tckn;

fn main() {
    let tc_identity = tckn::generate();
    println!("{}", tc_identity);
}

Validate TC Identity


use tck_no::tckn;

fn main() {
    let tc_identity = "38246970008";

    if tckn::validate(tc_identity) {
        println!("Valid!");
    } else {
        println!("Invalid!");
    }
}

Contributing

Want to join us? Look at some of these issues:

License

Licensed under either of MIT license
Commit count: 15

cargo fmt