Azure DevOps task for sending emails using SendGrid from build/release definitions
SendGrid Email Task for Azure DevOps to send emails from a build/release definition
You need to have a SendGrid Account created with an appropriate plan. You can learn more about SendGrid from the SendGrid Official Website.
Obtain the API Key required to access the SendGrid API by following the instructions on the Official Documentation.
Add the SendGrid Email Task
Install the SendGrid Email Task in to your Azure DevOps account and search for the task in the available tasks. The task will appear in the Utility section of the task list. Add it to your build/release task.
Configure SendGrid Section
Configure SendGrid section has one required configuration you need to set.
SendGrid API Key : API Key given by SendGrid. You can generate an API Key from the SendGrid Portal(Required)
Email Details Section
Email Details section has 4 required configuration you need to set. Sender Email Address, To Address(s), Subject and Email Body
Sender Email Address : Email address of the sender. The value can either be only the Email Address(Eg. firstname.lastname@example.org) or the Name and the Email Address(Eg. John Smith email@example.com)(Required)
Recipient Email Addresses : Email address(s) of the recipient(s). Use a comma (,) separated list if you have multiple email addresses. (Eg. firstname.lastname@example.org, email@example.com). The email addresses can either be only the Email Address(Eg. firstname.lastname@example.org) or the Name and the Email Address(Eg. John Smith email@example.com)(Required)
Subject : Subject of the email. (Required)
Email Body : Contents of the email you want to send.To send HTML body add the HTML here and set the Send as HTML checkbox. (Optional)
Send as HTML : Check this option if you want to send the contents of the email body as HTML. (Optional)