In this article, I’ll explain how you can create Custom Connector for the Microsoft Graph API in Power Apps.


Connectors enable logic app to integrate with the data and business processes. There are many pre-built connectors available for this purpose. Sometimes you may want to integrate with APIs, Services and Systems that are not available as pre-built connectors. To support this situation, we can create custom connectors with our own triggers and actions. All these connectors are function-based, which means that data will be returned based on calling specific functions in the underlying service. Custom connectors are essentially wrappers for Restful APIs, which allow basic services to communicate with logic apps. Therefore, even before creating a custom connector, you need Restful API.

Register Azure AD Application

  1. For registering Azure AD application, you must have an azure account with an active subscription and azure AD tenant.
  2. Sign-in to the with an account that has permissions to make Azure Active Directory applications.
  3. To register an application, select Azure Active Directory and select App registrations and select + New registration. Enter Application Name, select a supported account type, which will decide who may use the application and select Application type Web and enter Sign-on URL (e.g.: https://localhost/customconnector) under Redirect URI. Click Register after setting the values.
  • After registering Azure AD application, copy Application(Client Id) and save it.
  • To add client secret, select Certificates & secrets and click on New client secret enter Description and select duration from the Expires list and click Add. After adding client secret, copy client secret and save it 
  • Select API permissions for granting the delegated permissions your application needs to interact with the MS Graph API. Select Add a permission, select Delegate permission and add Directory.Read.All and Group.Read.All delegated permissions.
  • After adding permissions provide admin consent by Clicking on Grant admin consent.

Create Custom Connector

  1. Sign-in to Microsoft graph explorer using
  2. Either use method from Microsoft graph’s sample queries or directly enter URL. After that click on Run query. Copy URL and Response from Response preview tab
  • Sign into the
  • Expand Data from the navigation tab then select Custom Connector and click on New custom connector and then select Create from blank from the list.
  • Enter Connector name in pop-up.In General tab, enter icon background color, connector’s Description . Select scheme as HTTPS, host name as and base URL as /
  • Navigate to Security tab. Select OAuth 2.0 as the API. Select Azure Active Directory as Identity Provider. Enter Client id (The client or app id from Azure), Client secret(The client or app secret from Azure), Login URL as, Resource URL as Enter Directory.Read.All and Group.Read.All in Scope to grant permissions.
  • Navigate to Definition tab, enter Summary, Description and Unique Operation ID.
  • Click on Add default response and enter the response that you have copied from graph explorer and click Import.
  • Click on Create Connector and navigate to Security tab. Redirect URL will be generated. Copy URL.
  • Navigate to your App Homepage in Azure Portal and click on Redirect URIs link
  • Select Authentication from the left tab and click on Add URI and enter Redirect URL that you have copied to authenticate your connector and click Save.
  1. Now navigate to Test tab in power apps. Click on New connection to test your Action.
  2. A popup message will appear, click Create.
  3. Enter credential to authenticate
  4. After authentication your connection will be add to connection list select the connection. Enter input parameter for your operation and click Test operation.
  1. The operation return the same response as in graph explorer.
  2. Click Update connector.
  3. In your canvas application, Click Data Source then expand Connector and you can use your custom connector that you created like other data source just by adding it and calling action.


In this article, I explained how you can create custom connector to integrate Microsoft Graph API within Power app and using same method, you’ll be able to create custom connector to integrate any Restful APIs within Powerapp.