MrGeek.Net 1.4.110

There is a newer version of this package available.
See the version list below for details.
dotnet add package MrGeek.Net --version 1.4.110
NuGet\Install-Package MrGeek.Net -Version 1.4.110
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="MrGeek.Net" Version="1.4.110" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MrGeek.Net --version 1.4.110
#r "nuget: MrGeek.Net, 1.4.110"
#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 MrGeek.Net as a Cake Addin
#addin nuget:?package=MrGeek.Net&version=1.4.110

// Install MrGeek.Net as a Cake Tool
#tool nuget:?package=MrGeek.Net&version=1.4.110

MrGeek.Net

Send emails very easily using STMP clients.

This version has breaking changes.

Changes

  1. MrGeek.Net.Smtp.Sendgrid Namespace is MrGeek.Net.Smtp
  2. MrGeek.Net.Smtp.EmailSenderOptions
    1. Host_Address is Host
    2. Host_Port is Port
    3. Host_UserName is UserName
    4. Host_Password is Password
    5. Host_SecureSocketOptions is SecureSocketOptions
    6. Sender_EMail is From
    7. Sender_Name is DisplayName

How to use

Program.cs

builder.Services.UseMailService(builder.Configuration);

ServiceExtension.cs

using MrGeek.Net.Smtp;

public static void UseMailService(this IServiceCollection services, IConfiguration config)
{
     services.Configure<EmailSenderOptions>(config.GetSection("MailSettings");
     services.AddScoped<IEmailSender, EmailSender>();
}

appsetting.json

{
    "MailSettings": {
        "DisplayName": "",
        "From": "",
        "Host": "",
        "Port": "",
        "UserName": "",
        "Password": ""
    }
}

Controller or Class file Example

private readonly IEmailSender _emailSender;

public Constructor(IEmailSender emailSender) 
{
   _emailSender = emailSender;
}

public async void SendEmail() 
{
    var message = new Message( to: "johndoe@example.com", subject: "Email Subject", content: "Email Body");
    await _emailSender.SendEmailAsync(message);
}

This is an Internal Library used by Mr. Geek Philippines, Inc.

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
1.4.126 280 11/8/2023
1.4.113 154 7/18/2023
1.4.110 138 7/7/2023
1.4.101 145 5/16/2023