Send mail using O365 API

MS Techie 2,716 Reputation points
2021-06-04T10:19:39.98+00:00

How to send mail using O365 API ? Any C# code will be helpful.

Is Microsoft graph related to O365 API

I am trying to send mails from Azure Web App using O365 API and from Azure function using O365 API ( i dont want to use Logic app to send mail via O365 )

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,330 questions
0 comments No comments
{count} votes

Accepted answer
  1. Cristian SPIRIDON 4,481 Reputation points
    2021-06-05T09:13:23.797+00:00

    Hi,

    You can send emails using MS Graph as you guessed:

    https://learn.microsoft.com/en-us/graph/api/user-sendmail?view=graph-rest-1.0&tabs=http

    Hope this helps.

    Cristian

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Bill Bell 101 Reputation points
    2021-06-05T22:13:22.973+00:00

    If you have an Office 365 account then you can send using System.Net.Mail. I use this technique.

    https://blog.elmah.io/how-to-send-emails-from-csharp-net-the-definitive-tutorial/


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.