A common "Promodag Reports Application" is now used to access Office 365 and SharePoint Online.
It does, however, require additional permissions to access SharePoint Online.
The "Promodag Reports Application" must have been created and registered in Microsoft Entra ID, see Certificate-based authentication to Office 365.
The assignment of the permission on the chosen SharePoint site is done through PnP PowerShell, a cross-platform PowerShell Module.
Follow the instructions provided in this article to create the PnP app on Microsoft Entra ID.
Run PowerShell 7.x and enter this command: Connect-PnPOnline -Url https://<Office 365 tenant>.sharepoint.com/ -Interactive -ClientId <Application ID of the PnP app>
Run Windows PowerShell as and enter this command:
Grant-PnPAzureADAppSitePermission -AppId '<Application ID of the Promodag Application>' -DisplayName 'Promodag Reports RBAC Application' -Permissions Write
Run PowerShell 7.x as an administrator and enter this command:
Grant-PnPAzureADAppSitePermission -AppId '<Application ID of the Promodag Application>' -DisplayName 'Promodag Reports RBAC Application' -Site 'https://<Office 365 tenant>.sharepoint.com/sites/<sub-site> -Permissions Write