I have around 3 Millions users in a csv file, And I am trying to create them in Azure AD B2C using graph API using PowerShell cmdlets (Not SDK) I want to create them in azure ad b2c and at the time also need to record the accepted and rejected users from b2c Steps I followed in PowerShell Script :
- Importing CSV using Import-CSV
- Creating a Synchronized Arraylist for storing Accepted users
- Creating a Synchronized Arraylist for storing Rejecting users
- Creating Batch requests (20 at a time) using Batching in Graph API
- Calling graph API for each batch using for-each object -parallel -Throttlelimit 100
- For each request checking the status code for Accepted and Error and adding the user to respective Arraylist 7.Exporting the Arraylists as CSV
But while following these steps the Microsoft graph API is throwing throttling issues
Can anyone guide me how to handle throttling in this scenario ? or is there any other alternative to achieve this?