Sharing a Power App grants the user the right to run the Power App. However, when the user runs the Power App for the first time, he/she needs to approve the connections that the Power App connects with.
You can turn this consent prompt off by executing the following script.
Prerequisites
- Only Office 365 Global admins or Azure Active Directory Global admins can perform this action.
- The person running the script should be added as a co-owner of the App
Script
Install-Module -Name Microsoft.PowerApps.Administration.PowerShell
Install-Module -Name Microsoft.PowerApps.PowerShell -AllowClobber
Add-PowerAppsAccount
Set-AdminPowerAppApisToBypassConsent -AppName <App Id> -EnvironmentName <Env Id>
You can get the App Id from the Power Apps portal
You can get the Environment Name by running the following Powershell cmdlet
Get-AdminPowerAppEnvironment
If you do not get any results back, probably you do not have admin rights