Check if an email address exists without sending any email, written in Rust. Comes with a ⚙️ HTTP backend.
Rust emailemail-validationemail-validation-apiemail-verificationemail-verification-apiemail-verifierhacktoberfest
fix: Lowercase Reachable enum variants (#351)
Amaury Martinyb88c20ef5bc9
diff --git a/README.md b/README.mdindex 2ae5cba8..31734bed 100644--- a/README.md+++ b/README.md@@ -20,7 +20,7 @@ This software is licensed under the GPL-3.0 license, which forbids it being inte| Included? | Feature | Description | JSON field || --------- | --------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------- |-| ✅ | **Email reachability** | How confident are we in sending an email to this address? Can be one of Safe, Risky, Invalid or Unknown. | `is_reachable` |+| ✅ | **Email reachability** | How confident are we in sending an email to this address? Can be one of `safe`, `risky`, `invalid` or `unknown`. | `is_reachable` || ✅ | **Syntax validation** | Is the address syntactically valid? | `syntax.is_valid_syntax` || ✅ | **DNS records validation** | Does the domain of the email address have valid MX DNS records? | `mx.accepts_mail` || ✅ | **Disposable email address (DEA) validation** | Is the address provided by a known [disposable email address](https://en.wikipedia.org/wiki/Disposable_email_address) provider? | `misc.is_disposable` |diff --git a/core/src/util/input_output.rs b/core/src/util/input_output.rsindex 02449a06..13655c7e 100644--- a/core/src/util/input_output.rs+++ b/core/src/util/input_output.rs@@ -84,7 +84,8 @@ impl CheckEmailInput {/// An enum to describe how confident we are that the recipient address is/// real.-#[derive(Debug, Serialize)]+#[derive(Debug, PartialEq, Serialize)]+#[serde(rename_all = "lowercase")]pub enum Reachable {/// The email is safe to send.Safe,