MailboxValidator.SingleValidation 2.0.1

dotnet add package MailboxValidator.SingleValidation --version 2.0.1                
NuGet\Install-Package MailboxValidator.SingleValidation -Version 2.0.1                
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="MailboxValidator.SingleValidation" Version="2.0.1" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MailboxValidator.SingleValidation --version 2.0.1                
#r "nuget: MailboxValidator.SingleValidation, 2.0.1"                
#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 MailboxValidator.SingleValidation as a Cake Addin
#addin nuget:?package=MailboxValidator.SingleValidation&version=2.0.1

// Install MailboxValidator.SingleValidation as a Cake Tool
#tool nuget:?package=MailboxValidator.SingleValidation&version=2.0.1                

MailboxValidator VB.NET Libary

This VB.NET library provides an easy way to call the MailboxValidator API which validates if an email address is a valid one.

This library can be used in many types of projects such as:

  • validating a user's email during sign up
  • cleaning your mailing list prior to an email marketing campaign
  • a form of fraud check

Compilation

Just open the solution file in Visual Studio 2022 or later and compile:

Dependencies

An API key is required for this library to function.

Go to https://www.mailboxvalidator.com/plans#api to sign up for a FREE API plan and you'll be given an API key.

Usage for validating emails

Imports Newtonsoft.Json

Module Program
    Sub Main(args As String())
        Dim apikey = "PASTE_YOUR_API_KEY_HERE"
        Dim email = "example@example.com"
        Dim mbv As New MailboxValidator.SingleValidation(apikey)

        Dim mytask = mbv.ValidateEmailAsync(email) ' async API Call
        Dim myobj = mytask.Result

        Console.WriteLine(JsonConvert.SerializeObject(myobj, Formatting.Indented)) ' to pretty-print the JSON

        Console.WriteLine("email_address:" & myobj("email_address").ToString)
        Console.WriteLine("domain:" & myobj("domain").ToString)
        Console.WriteLine("is_free:" & myobj("is_free").ToString)
        Console.WriteLine("is_syntax:" & myobj("is_syntax").ToString)
        Console.WriteLine("is_domain:" & myobj("is_domain").ToString)
        Console.WriteLine("is_smtp:" & myobj("is_smtp").ToString)
        Console.WriteLine("is_verified:" & myobj("is_verified").ToString)
        Console.WriteLine("is_server_down:" & myobj("is_server_down").ToString)
        Console.WriteLine("is_greylisted:" & myobj("is_greylisted").ToString)
        Console.WriteLine("is_disposable:" & myobj("is_disposable").ToString)
        Console.WriteLine("is_suppressed:" & myobj("is_suppressed").ToString)
        Console.WriteLine("is_role:" & myobj("is_role").ToString)
        Console.WriteLine("is_high_risk:" & myobj("is_high_risk").ToString)
        Console.WriteLine("is_catchall:" & myobj("is_catchall").ToString)
        Console.WriteLine("mailboxvalidator_score:" & myobj("mailboxvalidator_score").ToString)
        Console.WriteLine("time_taken:" & myobj("time_taken").ToString)
        Console.WriteLine("status:" & myobj("status").ToString)
        Console.WriteLine("credits_available:" & myobj("credits_available").ToString)
    End Sub
End Module

Functions

SingleValidation(api_key)

Creates a new instance of the MailboxValidator object with the API key.

ValidateEmailAsync(email_address)

Performs email validation on the supplied email address.

Result Fields

email_address

The input email address.

domain

The domain of the email address.

is_free

Whether the email address is from a free email provider like Gmail or Hotmail.

Return values: True, False

is_syntax

Whether the email address is syntactically correct.

Return values: True, False

is_domain

Whether the email address has a valid MX record in its DNS entries.

Return values: True, False, -   (- means not applicable)

is_smtp

Whether the mail servers specified in the MX records are responding to connections.

Return values: True, False, -   (- means not applicable)

is_verified

Whether the mail server confirms that the email address actually exist.

Return values: True, False, -   (- means not applicable)

is_server_down

Whether the mail server is currently down or unresponsive.

Return values: True, False, -   (- means not applicable)

is_greylisted

Whether the mail server employs greylisting where an email has to be sent a second time at a later time.

Return values: True, False, -   (- means not applicable)

is_disposable

Whether the email address is a temporary one from a disposable email provider.

Return values: True, False, -   (- means not applicable)

is_suppressed

Whether the email address is in our blacklist.

Return values: True, False, -   (- means not applicable)

is_role

Whether the email address is a role-based email address like admin@example.net or webmaster@example.net.

Return values: True, False, -   (- means not applicable)

is_high_risk

Whether the email address contains high risk keywords.

Return values: True, False, -   (- means not applicable)

is_catchall

Whether the email address is a catch-all address.

Return values: True, False, Unknown, -   (- means not applicable)

mailboxvalidator_score

Email address reputation score.

Score > 0.70 means good; score > 0.40 means fair; score ⇐ 0.40 means poor.

time_taken

The time taken to get the results in seconds.

status

Whether our system think the email address is valid based on all the previous fields.

Return values: True, False

credits_available

The number of credits left to perform validations.

Usage for checking if an email is from a disposable email provider

Imports Newtonsoft.Json

Module Program
    Sub Main(args As String())
        Dim apikey = "PASTE_YOUR_API_KEY_HERE"
        Dim email = "example@example.com"
        Dim mbv As New MailboxValidator.SingleValidation(apikey)

        Dim mytask = mbv.DisposableEmailAsync(email) ' async API Call
        Dim myobj = mytask.Result

        Console.WriteLine(JsonConvert.SerializeObject(myobj, Formatting.Indented)) ' to pretty-print the JSON

        Console.WriteLine("email_address:" & myobj("email_address").ToString)
        Console.WriteLine("is_disposable:" & myobj("is_disposable").ToString)
        Console.WriteLine("credits_available:" & myobj("credits_available").ToString)
    End Sub
End Module

Functions

SingleValidation(api_key)

Creates a new instance of the MailboxValidator object with the API key.

DisposableEmailAsync(email_address)

Check if the supplied email address is from a disposable email provider.

Result Fields

email_address

The input email address.

is_disposable

Whether the email address is a temporary one from a disposable email provider.

Return values: True, False

credits_available

The number of credits left to perform validations.

Usage for checking if an email is from a free email provider

Imports Newtonsoft.Json

Module Program
    Sub Main(args As String())
        Dim apikey = "PASTE_YOUR_API_KEY_HERE"
        Dim email = "example@example.com"
        Dim mbv As New MailboxValidator.SingleValidation(apikey)

        Dim mytask = mbv.FreeEmailAsync(email) ' async API Call
        Dim myobj = mytask.Result

        Console.WriteLine(JsonConvert.SerializeObject(myobj, Formatting.Indented)) ' to pretty-print the JSON

        Console.WriteLine("email_address:" & myobj("email_address").ToString)
        Console.WriteLine("is_free:" & myobj("is_free").ToString)
        Console.WriteLine("credits_available:" & myobj("credits_available").ToString)
    End Sub
End Module

Functions

SingleValidation(api_key)

Creates a new instance of the MailboxValidator object with the API key.

FreeEmailAsync(email_address)

Check if the supplied email address is from a free email provider.

Result Fields

email_address

The input email address.

is_free

Whether the email address is from a free email provider like Gmail or Hotmail.

Return values: True, False

credits_available

The number of credits left to perform validations.

Copyright (C) 2024 by MailboxValidator.com, support@mailboxvalidator.com

Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  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 is compatible.  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 is compatible.  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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 is compatible.  net48 is compatible.  net481 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos 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.0.1 154 3/14/2024
2.0.0 140 9/22/2023
1.1.0 1,709 9/27/2018
1.0.0 1,091 7/21/2017

Updated for compatibility with .NET 8