PowerShell is a necessary tool to connect to O365 administration, more than the 40% of the features of O365 are not visible in the administration panel, so the only way to manage them is via PowerShell code. To the vast majority of users the web portal will be more useful, but if you need to do repetitive tasks or very complex PowerShell is your tool.
So, how do we connect to the several services that offer O365? Let’s being:
Azure Active Directory
$credential = get-credential
Connect-MsolService -Credential $credential
$exchangeSession = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $credential -Authentication “Basic” -AllowRedirection
Connect-SPOService -Url https://<NombreDelTenant>-admin.sharepoint.com -credential $credential
Skype for Business
$lyncSession = New-CsOnlineSession -Credential $credential
BONUS: Microsoft Azure
#opens a web page on the Windows Azure Management Portal, from which you can download the subscription information. The information is contained in a .publishsettings file.
#the previous commands allow to view account and subscription details
Depending of which operations or services we are using, we will be able to connect to the service without problem