You can use the Cmdlets4Sas to connect to any server via SAS token authentication (the token authentication has to be configured in the SAS management console first). To learn more about token authentication see the official SAS documentation (link)
In this sample we will cover the following steps:
# ensure module is loaded
if(!(Get-Module Cmdlets4Sas))
{Import-Module Cmdlets4Sas}
# connect to SAS metadata server using IWA
$omi = Connect-SasMetadataServer "iom://mycompany.com:8561;Bridge;SECURITYPACKAGE=Negotiate"
# request one time login token from metadata server
$token = Get-SasMetaToken $omi
# use token as credentials to connect to a new SAS workspace server session
$ws = Connect-SasWorkspaceServer "iom://mycompany.com:8591;Bridge;" $token
# here you can do your stuff with the workspace, e.g. Read-SasLog $ws
# disconnect from workspace and metadata server
Disconnect-SasServer $ws
Disconnect-SasServer $omi