AdvancedEmailValidator 2.1.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package AdvancedEmailValidator --version 2.1.0                
NuGet\Install-Package AdvancedEmailValidator -Version 2.1.0                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="AdvancedEmailValidator" Version="2.1.0" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add AdvancedEmailValidator --version 2.1.0                
#r "nuget: AdvancedEmailValidator, 2.1.0"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install AdvancedEmailValidator as a Cake Addin
#addin nuget:?package=AdvancedEmailValidator&version=2.1.0

// Install AdvancedEmailValidator as a Cake Tool
#tool nuget:?package=AdvancedEmailValidator&version=2.1.0                

Advanced Email Validator

Welcome to the Advanced Email Validator, a comprehensive email validation library built to provide a robust solution for validating email addresses. This library offers a variety of validations like Regex Validation, MX record Validation, Typo Detection, Disposable Email Detection, and much more.

Features

  • Regex Validation: Validates email addresses against standard and simple regex patterns. You also have an option to provide a custom regex pattern.
  • MX Record Validation: Checks if the email domain has a valid MX record.
  • Typo Detection: Checks for common typos in the email address based on a specific algorithm. Useful in detecting and suggesting corrections for user input.
  • Disposable Email Detection: Checks if the email address belongs to a commonly known disposable email domain.

Getting Started

Installation

Firstly, add the NuGet package to your .NET project. In the NuGet package manager console, run:

Install-Package AdvancedEmailValidator

Configuration

In your Startup.cs file, use the provided extension method to add the necessary services to your dependency injection container:

public void ConfigureServices(IServiceCollection services)
{
    services.AddEmailValidator();
    // Other services...
}

Usage

Inject the IEmailValidator interface where you need to perform email validation:

public class SomeService
{
    private readonly IEmailValidator _emailValidator;

    public SomeService(IEmailValidator emailValidator)
    {
        _emailValidator = emailValidator;
    }

    public async Task DoSomething(string email)
    {
        var validationResult = await _emailValidator.ValidateAsync(email);
        //...
    }
}

By default, all validations are enabled. You can customize this

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
2.2.2 2,877 9/6/2023
2.2.1 147 9/6/2023
2.2.0 149 8/30/2023
2.1.0 159 8/28/2023
2.0.2 144 8/28/2023
2.0.1 189 7/24/2023
2.0.0 165 7/24/2023
1.2.1 802 10/6/2021
1.0.3 351 10/1/2021
1.0.2 340 9/30/2021
1.0.1 370 9/27/2021