We are trying to create secrets for applications in b2c tenant from powershell.
After searching a lot, came across these commands that are working fine for normal applications.
$StartDate = Get-Date
$EndDate = $StartDate.AddYears(5)
New-AzureADApplicationPasswordCredential -CustomKeyIdentifier b2csecret -ObjectId 6133a24a-2cc7-4b47-901c-2e2c67b0bed6 -EndDate $EndDate
But this fails for applications of Accounts in any identity provider or organizational directory (for authenticating users with user flows) type.
New-AzureADApplicationPasswordCredential : Error occurred while executing SetApplication
Code: Request_BadRequest
Message: Updates to converged applications are not allowed in this version.
RequestId: 9630857f-6d32-4788-8637-0a15967beb22
DateTimeStamp: Wed, 05 Apr 2023 13:22:19 GMT
HttpStatusCode: BadRequest
HttpStatusDescription: Bad Request
HttpResponseStatus: Completed
At line:3 char:1
+ New-AzureADApplicationPasswordCredential -CustomKeyIdentifier b2csecr ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [New-AzureADApplicationPasswordCredential], ApiException
+ FullyQualifiedErrorId : Microsoft.Open.AzureAD16.Client.ApiException,Microsoft.Open.AzureAD.Graph.PowerShell.Custom.NewAzureADA
pplicationPasswordCredential
Updates to converged applications are not allowed in this version means is there no way? How to create secrets in b2c application of Accounts in any identity provider or organizational directory (for authenticating users with user flows)
type programmatically from powershell?