Calling APIs
In this section, we will learn how to call Admin Center APIs. I suggest doing this in two different ways, as follows:
- From PowerShell, to show automation scenarios
- From Postman, to show a user-friendly interface
For example, you often update development sandboxes from a test or production sandbox, and you don't want to open the Admin portal each time and click through all those settings. You could create a PowerShell script and just run it each time you need to have a new environment.
Postman is one of the most popular REpresentational State Transfer (REST) clients. You can use it to test APIs, for single calls or demonstration purposes.
In this section, we will look into both environments.
PowerShell
- Run PowerShell as an administrator. We need to install the
AzureAD
module and theMicrosoft.Identity.Client
package (if you haven't already done so). For this, run the next script:Install-Module AzureAD Install-Package -Name...