question

NoahMcGaryPACTERATECHNOLOGIESINC-5364 avatar image
0 Votes"
NoahMcGaryPACTERATECHNOLOGIESINC-5364 asked MichaelHan-MSFT edited

Connect to the SharePoint Online using Application Permission

Hi! We are trying to connect to Sharepoint Online from a runbook in an Azure Automation account. I have been looking at documention that uses Application Permissions to do this
( https://github.com/pnp/powershell/tree/dev/samples/SharePoint.ConnectUsingAppPermissions ). I have followed the steps but when I try to connect at the end it tells me it cannot find the cert thumbprint that I generated in the cert store.

Here is the exact command I am trying to run :

Connect-PnPOnline -Tenant 975f013f-7f24-47e8-a7d3-abc4752bf346 -ClientId 75b7e0f1-aa3a-4140-84ad-a24a900f63ae -Thumbprint D263053965CDBC64651234C93AC1CA93309595DB -Url https://contoso.sharepoint.com

I have uploaded the cert as it showed but it still says it cannot be found.


Can someone help with this? I tried uploading photos here but it doesn't seem to want to let me do it.

office-sharepoint-onlinesharepoint-dev
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

MichaelHan-MSFT avatar image
0 Votes"
MichaelHan-MSFT answered

Hi @NoahMcGaryPACTERATECHNOLOGIESINC-5364,

Please make sure that you install the certificate to Local Machine by running the command Import-PfxCertificate

131441-image.png


If an Answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.



image.png (51.3 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.