PnP Connection Scopes Not Passing thru App Registration #191229
-
Discussion TypeProduct Feedback Discussion ContentI am connecting to PnPOnline via an App Registration, but when I use the Get-PnPConnection command, the Scopes value is blank. I tried to run the Get-PnPTenantSite and the returned error is: Get-PnPTenantSite: Unexpected response from the server. The content type of the response is "". The status code is "Forbidden". I have the API/Permissions set as 'SharePoint Sites.FullControl.All' (Application) & 'SharePoint User.ReadWrite.All' (Application) and Admin consent is granted for the domain. Can anyone point me in the right direction? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
|
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Beta Was this translation helpful? Give feedback.
-
|
Hi @packercountryusa, Regarding the Forbidden error for Get-PnPTenantSite:
If this points you in the right direction, please feel free to Mark as Answer! |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for posting in the GitHub Community, @packercountryusa! We're happy you're here. You are more likely to get a useful response if you are posting your question in the applicable category, the Discussions category is solely related to conversations around the GitHub product Discussions. This question should be in the |
Beta Was this translation helpful? Give feedback.
I was researching your responses when I came across this:
https://pnp.github.io/powershell/cmdlets/Register-PnPEntraIDApp.html
I followed the instructions on this page and did not have any issues. When I compared my manual registration and the automated registration, other than the cert vs secret, the difference was 3 additional API permissions: Graph > Group.ReadWrite.All, Graph > User.ReadWrite.All & SharePoint > AllSites.FullControl.
When I added those three additional permissions and tested it, it still connected, but could not access anything.
I am sure it is not a matter of a cert vs secret, but the Register-PnPEntraIDApp command appeared to fix my issue.
Thanks for you assistance t…