This is adapted from a method I use in EWS scripts:
$windowsIdentity = [System.Security.Principal.WindowsIdentity]::GetCurrent()
$sidbind = "LDAP://<SID=" + $windowsIdentity.user.Value.ToString() + '>'
$MailAddress = ([ADSI]$sidbind).mail.tostring()
$MailAddress
That's assuming you're using an SMTP relay to send the email. Most Exchange orgs will have an Exchange receive connector set up somewhere for application servers and things like MFD's that can't authenticate to the domain to send email to Exchange recipients. Find out where that is an put it into the SMTPServer
parameter of Send-MailMessage
.