Create Static Claim in AAD Claim Transformation Policy

Daniel Milnes 21 Reputation points
2022-07-01T08:24:26.277+00:00

Hi there,

I'm having trouble creating an arbitrary string claim using AAD Claim Transformation policies. I've tried to adapt from the AAD B2C docs (https://learn.microsoft.com/en-us/azure/active-directory-b2c/string-transformations#createstringclaim) to the JSON required here, but I get a generic ClaimsMappingPolicy.BaseClient.Patch(): unexpected status 400 with OData. error: Request_BadRequest: Property definition has an invalid value. error.

   {  
     "ClaimsMappingPolicy": {  
       "ClaimsSchema": [  
         {  
           "ID": "StaticKey",  
           "SamlClaimType": "claimnamehere",  
           "Source": "transformation",  
           "TransformationId": "StaticTransformationKey"  
         }  
       ],  
       "ClaimsTransformations": [  
         {  
           "ID": "StaticTransformationKey",  
           "InputParameters": [  
             {  
               "ID": "value",  
               "Value": "example"  
             }  
           ],  
           "OutputClaims": [  
             {  
               "ClaimTypeReferenceId": "StaticKey",  
               "TransformationClaimType": "createdClaim"  
             }  
           ],  
           "TransformationMethod": "CreateStringClaim"  
         }  
       ],  
       "IncludeBasicClaimSet": "true",  
       "Version": 1  
     }  
   }  

Is there something I've missed here? This is functionality we need to work.

Thanks!

Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
18,656 questions
{count} votes