Therefore, if you haven’t created a PS profile already, just run the following command in the PowerShell or, what I personally prefer, in the PS ISE.

Test-Path $Profile

If you receive a “False”, you do not have a profile already, so let’s create one with the following command and then open it in the notepad:

New-Item –Path $Profile –Type File –Force
Notepad $Profile

So now that you own a PS or ISE profile, you can do some nice stuff with it. And as an O365 admin, you probably love to do admin tasks with your PS instead with the GUI. But isn’t it annoying to login in everytime you open up your PS or ISE or even worse, login with different credentials, when you need to administer a customers tenant? That’s why I implemented my own login process in my ISE in order to define quick actions, which do the authentication process automatically with a few clicks. Simply paste the following code to your profile and replace with your credentials.

Now if you re-open up your ISE (if you have followed the previous steps in your ISE) you should see the following Add-Ons options:

So now you are good to go and click on your Tenant and start using your PS profile. And as you might guess you can paste more of these Add-Ons into your profile in order to add more tenants. But what’s not that ideal is that the password is inserted in plain text. Therefore you can follow the following routine in order to use encrypted passwords for your PS profiles.

At first, run the following command in your PS in order to create an encrypted password and save it to your disk (you may adapt the path):