You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I have created an app registration which I can connect to successfully. Command used to connect is:
Connect-PnPOnline TENANT-admin.sharepoint.com -ClientId CLIENTID -Tenant TENANT.onmicrosoft.com -CertificatePath C:\it\PowershellPnP.pfx -CertificatePassword $password
This connects fine, however when I run the following command I get a 401 unauthorised error
Get-PnPTenantSite
Get-PnPTenantSite: The remote server returned an error: (401) Unauthorized.
Any other pnp command I use returns the same.
I have granted the app registration the following permissions
What I am currently trying to achieve is to grab a list of all sites, storage used, and get the content of the description of the site.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hey,
So I have created an app registration which I can connect to successfully. Command used to connect is:
Connect-PnPOnline TENANT-admin.sharepoint.com -ClientId CLIENTID -Tenant TENANT.onmicrosoft.com -CertificatePath C:\it\PowershellPnP.pfx -CertificatePassword $password
This connects fine, however when I run the following command I get a 401 unauthorised error
Get-PnPTenantSite
Get-PnPTenantSite: The remote server returned an error: (401) Unauthorized.
Any other pnp command I use returns the same.
I have granted the app registration the following permissions
What I am currently trying to achieve is to grab a list of all sites, storage used, and get the content of the description of the site.
How can I achieve this using pnp?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions