You can invoke the command line tool plink.exe from within PowerShell which requires PuTTY to be installed, and difficult to use.
PowerShell's biggest strength probably is its ability to use .Net Libraries.
SharpSSH is a .Net implementation of SSH2 protocol and could be used from within PowerShell.
Download SharpSSH, extract the zip and load the SharpSSH assembly by writing following line of code on top of your PowerShell script.
Add-Type -Path C:\SharpSSH.dll #assumes you extracted SharpSSH in C:\
A new SSH session could be created as,
New-SshSession user1 example.org # You'll be prompted for a password
if( Invoke-Ssh who '\$'| select-string "^(?!user1).*pts/\d" ) {
Invoke-Ssh "shutdown -r 0:00" '\$'
}
else {
Invoke-Ssh "shutdown -r now" '\$'
}
Remove-SshSession
Have a look at this and this example Scripts for invoking various other SSH commands from within PowerShell.