cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
quentin-roger
Level: Powered On

Active directory custom connector : you do not have permission to view this directory or page.

Hi,

We continue to have authentication problems with OAuth Custom Connector, as mentionned in this post we encounter issue when we are trying to use OAuth Generic Connector.

 

https://powerusers.microsoft.com/t5/Building-PowerApps-Formerly/When-using-Oauth2-generic-connector-...

 

Se we tried to use the Azure active directory connector, but we found out new issue. This time the connection was created successfully, but when we try to call our api we receive a generic error.

 

See screenshots below :

 

powerapps_2_1.pngpowerapps_2_2.pngpowerapps_2_3.png

 

 

When we are trying our api we receive from the connector Test Page :

 

You do not have permission to view this directory or page.

 

I checked the bearer token sent to the Api and it seems that it doesn't send the good audience in the bearer token :

powerapps_2_4.png

 

When we are getting the token from PostMan the audience is the ressource the token is intented for.

 

powerapps_2_5.png

 

What am I missing ? Or do I misunderstand something ? 

 

Thanks.

 

 

2 REPLIES 2
Community Support Team
Community Support Team

Re: Active directory custom connector : you do not have permission to view this directory or page.

Hi @quentin-roger ,

Do you mean that you have to permission to your api connector?

Please check:

whether you have added the resource as an audience in your App Service authentication configuration

I also find some docs about how to grant permissions to users to use the Azure AD connector  for your reference:

https://alextofan.com/2019/02/06/how-to-grant-permissions-to-users-to-use-the-azure-ad-connector-in-...

https://sachinbansal.blog/2018/08/23/powerapps-secure-your-azure-function-and-custom-connector-with-...

https://sharepoint-specialist.nu/custom-connector-authentication-to-the-graph-microsoftflow-468b494d...

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
TopShelf-MSFT
Level 10

Re: Active directory custom connector : you do not have permission to view this directory or page.

Hi @quentin-roger how are you progressing with this? Was the above reply helpful?

 

@TopShelf-MSFT 

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (4,224)