MrKobayashi
MrKobayashi

Reputation: 1143

O365 Send as another user via graph api

I am struggling to get a succinct answer. Has anyone had to send emails from an Azure hosted website using the graph api? If so i realise i can use delegated permissions and send as the logged in users. I am also familiar about the fact i can assign application permissions for the Mail.Send property. What i am struggling to understand is that if i create a new user like [email protected] do i then have to assign the "SendAs" permission on that mailbox for all users of my website?

Background: I am creating a pretty standard website hosted in Azure that performs a basic sign off process. The email i am sending is part of a workflow and should come from a generic account, not a user account.

Thanks

Upvotes: 0

Views: 224

Answers (1)

Allen Wu
Allen Wu

Reputation: 16438

Based on your description, if you want to use delegated permissions to send emails on that mailbox on behalf of all the other users, you have to assign the "SendAs" permission for all the other users. The answer is Yes.

In this case, now that you are familiar about the fact you can assign application permissions, you should use Application permissions instead of Delegated permissions to send the emails.

Upvotes: 1

Related Questions