I am running below command in SharePoint Online Management Shell as administrator to get PnP Provisioning Template from a site collection in SharePoint online.
Get-PnPProvisioningTemplate -out Lists.xml -Handlers Lists
It throws following error in PowerShell window:
"Access denied.You do not have permission toperform this action or access this resource."
I have checked following things:
1. User I am running with PowerShell is a site collection administrator.
2. Permission is not broken for any lists.
3. Above command runs with handlers fields and contenttypes.
4. No list has any item/document/page checked out. All data is checked in with major version published.
it could be a Term Store Administration permission issue.
Could you check if your User is a Term Store Admin?