使用 Office365 帐户通过 PowerShell 发送电子邮件
我想使用 PowerShell 的 cmdlet Send-MailMessage
发送电子邮件,但是我们使用 Office365 进行操作,基础设施工程师建议使用 PowerShell 连接到 Exchange,用户需要管理员权限,这是可以理解的,他们不需要想要授予。我认为这太过分了,想看看是否有任何解决方法可以让我使用标准电子邮件帐户通过 PowerShell 发送电子邮件
I want to send out emails using PowerShell's cmdlet Send-MailMessage
, however we operate with Office365 and an infrastructure engineer has suggested to connect to Exchange with PowerShell, the user needs admin rights, which understandably, they do not want to grant. I thought this was excessive and wanted to see if there were any work arounds which allowed me to send emails through PowerShell using a standard email account
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用 Graph API 或 EWS,请参阅<一个href="https://learn.microsoft.com/en-us/exchange/client-developer/exchange-web-services/explore-the-ews-management-api-ews-and-web-services-in-exchange " rel="nofollow noreferrer">探索 Exchange 中的 EWS 托管 API、EWS 和 Web 服务以了解详细信息。
You can use Graph API or EWS, see Explore the EWS Managed API, EWS, and web services in Exchange for more information.