Apply PnP Template suddenly fails

We didn't change configuration. Keep getting either error AADSTS65001: The user or administrator has not consented to use the application... PnP Management Shell or "cannot get user name", depending on whether a Credentials or Admin Auth conenction.

Hello! Please grant the admin consent to the application by loading this link:
https://login.microsoftonline.com/{tenant-id}/adminconsent?client_id={client-id}
{tenant-id} - find it in the Azure admin centre.
{client-id} - take it from the error message.

Happening again, this time with a different error:
Cannot contact web site 'https://xxxxx.sharepoint.com/' or the web site does not support SharePoint Online credentials. The response status code is 'Unauthorized'. The response headers are 'X-SharePointHealthScore=2, X-MSDAVEXT_Error=917656; Access+denied.+Before+opening+files+in+this+location%2c+you+must+first+browse+to+the+web+site+and+select+the+option+to+login+automatically.

etc.

Enabled legacy auth (which was disabled months ago without issue), and now the error is 403 - Forbidden...

Hello! Please perform these steps:

  • share the raw inputs and outputs of the failed action in both cases;
  • specify what type of API key you use: custom user credentials or admin permissions? If the first one, does it have MFA? If yes, could you try a new app password? I mean create a new API key with the updated app password, copy it, and update the Plumsail Actions connection in Power Automate - share the raw outputs if the action fails in this case too;
  • please try to apply the same template through PowerShell and share the results you have.

Please send the collected data to support@plumsail.com and refer to this topic.