Notifications
Announcements
Next, make sure you are using Windows PowerShell 5.1.xxx by running the following command:
$PSVersionTable
If this returns any version other than 5.1.xxx, you will need to install or switch to Windows PowerShell version 5.1.xxx before continuing.
Once you've created the CSV file and confirmed that you're using Windows PowerShell 5.1.xxx, next you'll need to install the appropriate PowerApps modules by opening Windows PowerShell as an administrator and running the following commands:
Install-Module -Name Microsoft.PowerApps.Administration.PowerShell Install-Module -Name Microsoft.PowerApps.PowerShell -AllowClobber
Once these modules have been installed successfully, you can then run the following PowerShell script to add the users into the environment:
# Add users to Power Platform environment $CsvPath = '.\NewUsers.csv' # Replace with relative/absolute path to your CSV file $PowerAppsEnvName = 'example' # Replace with your Power Platform environment name $PowerAppsEnvGuid = (Get-AdminPowerAppEnvironment $PowerAppsEnvName).EnvironmentName foreach($User in (Import-Csv -Path $CsvPath)) { $UserEmail = $User.'Email' # Replace 'Email' with the CSV column heading Write-Output "Attempting to add $($UserEmail) to $($PowerAppsEnvName)..." $UserId = (Get-AzADUser -ObjectId $UserEmail).Id try { Add-AdminPowerAppsSyncUser -EnvironmentName $PowerAppsEnvGuid -PrincipalObjectId $UserId Write-Output "$($UserEmail) added to $($PowerAppsEnvName)!" } catch { Write-Output "$($UserEmail) is already a member of $($PowerAppsEnvName)." } }
This script will not only attempt to add each user into your Power Platform environment, but will also let you know the result. Once complete, all new users should now be in your Power Platform environment.
Key Points Worth Noting:
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
In our never-ending quest to improve we are simplifying the forum hierarchy…
We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 721 Most Valuable Professional
Michael E. Gernaey 320 Super User 2025 Season 2
Power Platform 1919 268