AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector 1.0.0-beta6

This is a prerelease version of AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector.
dotnet add package AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector --version 1.0.0-beta6
NuGet\Install-Package AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector -Version 1.0.0-beta6
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="AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector" Version="1.0.0-beta6" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector --version 1.0.0-beta6
#r "nuget: AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector, 1.0.0-beta6"
#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 AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector as a Cake Addin
#addin nuget:?package=AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector&version=1.0.0-beta6&prerelease

// Install AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector as a Cake Tool
#tool nuget:?package=AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector&version=1.0.0-beta6&prerelease

Azure AI Community GitHub

AzureAI Community Microsoft Semantic Kernel Plugin - Google GMailConnector

The AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector This component offers send email using GMail

Building a Google GMail Connector

This guide will lead you through the steps of creating a plugin for utilizing Gmail services to send and retrieve emails.

Prerequisites

Install AzureAI.Community.Microsoft.Semantic.Kernel.PlugIn.Google.GMailConnector package from nuget server

Plugin Building Steps

Create an Instance of GMailConnector

The GMailConnector class is responsible for sending emails. You need to provide an instance of the GmailService class to this class.

Here's an example code snippet:

	
	GmailService gmailService;
	IEmailConnector gMailConnector = new GMailConnector(gmailService);

Importing a Plugin into the Kernel

To import a Plugin into the kernel, you can use the following C# code snippet:

	EmailPlugin emailPlugin = new EmailPlugin(gMailConnector);
	var gmail = kernel.ImportFunctions(emailPlugin, nameof(EmailPlugin));

Running a Plugin within the Kernel

To run a plugin within the kernel and dispatch an email., you can use the following C# code snippet:

var result = await kernel.RunAsync("Bot composer",  gmail["SendEmail"]);

Output

Console.WriteLine(result);

Get my email address


  SKContext emailAddressResult = await kernel.RunAsync(string.Empty, gmail["GetMyEmailAddress"]);
  string myEmailAddress = emailAddressResult.Result;

GetMessagesAsync


  SKContext emailAddressResult = await kernel.RunAsync(string.Empty, gmail["GetMessagesAsync"]);
  var messages = emailAddressResult.Result;

Product Compatible and additional computed target framework versions.
.NET 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 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.0.0-beta6 187 11/12/2023
1.0.0-beta1 87 11/1/2023