Hi All,
I am using graph api to send an email.
If I use some specific email sender email as UserPrincipalName then it works.
But If I use any other emails as sender email (UserPrincipalName) It is giving 404error and not proper description.
404 Not Found at ssMSGraphConnectorOauth2_0_Core.CcMicrosoftGraph.ActionSendMailAsOtherUser(HeContext heContext, ICcMicrosoftGraphCallbacks _callbacks, String inParamUserPrincipalName, String inParamAuthorization, STSendMailAsOtherUserRequestStructure inParamRequest) at ssMSGraphConnectorOauth2_0_Core.Actions.ActionSendMailFromFunctionalAccount(HeContext heContext, STSendMailAsOtherUserRequestStructure inParamMailRequest)
Please suggest
Hi
What do you mean with "if i use any other emails as sender email" ? Do you mean an arbitrary mail address like noreply@mydomain.com? This does not work. The User Principal name (UPN) is a named mailbox. If you want to send from a generic - non user related mailbox - you would have to create a resource mailbox for it.
Best
Stefan
Hi Stephen,
it is working only for one named email client specific ex,info@somedomain.com
But it is not working neither the personal gmail or noreply@domain.con
Do I need to configure anything principal name and what is resource mailbox,.thank you
Here is an article of mine that explains the configuration on how to send a mail from a resource mailbox https://medium.com/itnext/send-actionable-messages-from-outsystems-applications-7073cec90618
You can also download the demo application mentioned in the article. Although the article shows how to send Actionable Messages you will find the basic sending part in it.
Hi Ujwwala,
Just check these below post if it helps.
https://stackoverflow.com/questions/73246816/get-405-404-error-when-trying-to-send-mails-with-graph-api-oauth2-client-creden
https://learn.microsoft.com/en-us/answers/questions/481050/graph-api-daemon-web-404-error
Thanks,
Sachin