-
I am currently searching for a way on how to connect to Microsoft Graph with PnP Powershell when using a Certificate for app permissions. Only way I currently found to also get all the permission scopes defined in my App Registration is the following:
As per the documentation all combinations of Connect-PnPOnline using a certificate would always require to provide a URL and do not allow parameter AADDomain. So is there a way to connect to Microsoft Graph respecting all of my Scopes defined in the App Registration using a Combination of ClientID and a Certificate or is this currently not supported within PnP Powershell? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @zapftho Yes, you can use the certificate thumbprint method to connect with a certificate: Connect-PnPOnline -Url "siteUrl" -ClientId "clientID" -Tenant "tenantName" -Thumbprint "certThumbprint" As you mentioned the scopes are defined in the app reg. You do need to register the cert in the app reg too. I'm not sure why you need to use "AADDomain". Would you be able to clarify that? |
Beta Was this translation helpful? Give feedback.
Hi @zapftho Yes, you can use the certificate thumbprint method to connect with a certificate:
Connect-PnPOnline -Url "siteUrl" -ClientId "clientID" -Tenant "tenantName" -Thumbprint "certThumbprint"
As you mentioned the scopes are defined in the app reg. You do need to register the cert in the app reg too. I'm not sure why you need to use "AADDomain". Would you be able to clarify that?