Skip to content

Instantly share code, notes, and snippets.

@dapacruz
Last active November 26, 2018 17:03
Show Gist options
  • Select an option

  • Save dapacruz/8a49c4018b2a21f08bec4dc8c59f20b2 to your computer and use it in GitHub Desktop.

Select an option

Save dapacruz/8a49c4018b2a21f08bec4dc8c59f20b2 to your computer and use it in GitHub Desktop.
Send Email From PowerShell
$params = @{
To = 'user@domain.com'
From = 'test@client.com'
Subject = 'Test Alert'
Body = ' '
SmtpServer = 'smtp-relay.gmail.com'
UseSsl = $true
}
Send-MailMessage @params
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment