Yes, Microsoft Graph API supports sending emails on behalf of users from their own email ID, and it’s well-suited for the kind of scenario you’ve described, but it must be set up securely and correctly.
Summary of What You Need:
- Microsoft Graph API can send emails on behalf of users.
- You'll need to register an Azure AD App.
- You must get user consent to send mail on their behalf.
- Use OAuth 2.0 Authorization Code Flow to securely authenticate users.
- Use delegated permissions, not application-wide credentials, for your use case.
Microsoft Graph API Flow: Sending Email as a User
API Endpoint
POST https://graph.microsoft.com/v1.0/me/sendMail
Authorization: Bearer {user_access_token}
Content-Type: application/json
The email will be sent from the authenticated user’s account (e.g., ******@company.com), provided they’ve consented to the Mail.Send
permission.
How to Manage Multiple Users
Each sales team member will need to log in once to grant your app permission. You can:
Store their refresh_token
securely (encrypted).
Automatically refresh access tokens as needed.
This way:
- You don’t need to manage their credentials.
- Emails are always sent from their real accounts.
- You comply with security best practices.
Let me know if you need further help
Kind regards
Mark Dicks