Using Exchange Online PowerShell cmdlets on web page RRS feed

  • Question

  • Hello,

    I need to create new AzureAD application registration on custom web page.

    Locally i use Connect-AzureAD cmdlet and then powershell script with stuff like  $App = New-AzureADApplication -DisplayName $name -ReplyUrls $appReplyURLs -PasswordCredentials $PasswordCredential -RequiredResourceAccess $reqGraph

    Is it any way to integrate those steps into web page with 2 buttons(register and create app) ? The web page is hosted on linux environment.

    Thursday, October 10, 2019 8:02 AM

All replies

  • Hi, 

    You can useMicrosoft Grapgh API to acheive this. 

    You would have to collect the required properties and then make an API call to create the application. 


    Note: You would have to register your web app and then give permissions so that it can creat an application or you would have to user's identity to create the applcation.

    Please take a moment to "Mark as Answer" and/or "Vote as Helpful" wherever applicable. Thanks!

    Thursday, October 10, 2019 10:28 AM
  • Thank you for response, but i have two doubts about the solution.

    1) I can't use beta Api in production

    2) My main goal is to access Microsoft Graph Api with bearer token provided by Azure AD. For that reason i am asking my customer to register my application in Azure and grant it access to Microsoft Graph Api with some restricted roles.  So i don't have access to Graph Api, but i'm trying to find more userfriendly way to register the app then the powershell scripts. 

    Thursday, October 10, 2019 11:07 AM
  • 1) You can probably use Azure AD Graph API in that case:

    2) PS / API are the best ways to do it. You can also consider publishing your app in the app gallery. 


    Please take a moment to "Mark as Answer" and/or "Vote as Helpful" wherever applicable. Thanks!

    Friday, October 11, 2019 9:39 AM