https://github.com/aniketfuryrocks/phone-number-verifier
phone number verification library for rust
https://github.com/aniketfuryrocks/phone-number-verifier
rust rust-library
Last synced: 7 months ago
JSON representation
phone number verification library for rust
- Host: GitHub
- URL: https://github.com/aniketfuryrocks/phone-number-verifier
- Owner: aniketfuryrocks
- License: mit
- Created: 2021-08-02T08:31:30.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2021-08-02T10:09:30.000Z (about 4 years ago)
- Last Synced: 2025-04-01T14:17:48.906Z (7 months ago)
- Topics: rust, rust-library
- Language: Rust
- Homepage: https://crates.io/crates/phone-number-verifier
- Size: 11.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# Phone Number Verifier
*phone number verification library for rust*### With Country Code
```rust
pub fn verify_phone_number_with_country_code(ph: &str) -> bool
``````regex
^(\+\d{1,2}\s?)?1?\-?\.?\s?\(?\d{3}\)?[\s.-]?\d{3}[\s.-]?\d{4}$
```### Without Country Code
```rust
pub fn verify_phone_number_without_country_code(ph: &str) -> bool
``````regex
^1?\-?\.?\s?\(?\d{3}\)?[\s.-]?\d{3}[\s.-]?\d{4}$
```