0
votes

Custom Attribute added to claims but it's not saved to user profile

I added custom attribute empid to ADB2C User attributes and trying to save this when user register by calling REST-API as below

API Calling successfully and claims data updated as per the API result but user profile result not changing

User Journey

<UserJourney Id="SignUpTDNA">
      <OrchestrationSteps>    

        <OrchestrationStep Order="1" Type="ClaimsExchange">
          <ClaimsExchanges>
            <ClaimsExchange Id="SignUpWithLogonEmailExchange" TechnicalProfileReferenceId="LocalAccountSignUpWithLogonEmail" />
          </ClaimsExchanges>
        </OrchestrationStep>
        <OrchestrationStep Order="2" Type="ClaimsExchange">
          <ClaimsExchanges>
            <ClaimsExchange Id="RESTGetProfile" TechnicalProfileReferenceId="REST-GetProfile" />
          </ClaimsExchanges>
        </OrchestrationStep>
       <OrchestrationStep Order="3" Type="ClaimsExchange">
          <ClaimsExchanges>
            <ClaimsExchange Id="AADUserReadWithObjectId" TechnicalProfileReferenceId="AAD-UserReadUsingObjectId" />
          </ClaimsExchanges>
        </OrchestrationStep> 

        <OrchestrationStep Order="4" Type="SendClaims" CpimIssuerTechnicalProfileReferenceId="JwtIssuer" />
  </OrchestrationSteps> 
      <ClientDefinition ReferenceId="DefaultWeb" />
    </UserJourney>

in the AAD-UserWriteUsingLogonEmail Technical profile : I added

 <TechnicalProfile Id="AAD-UserWriteUsingLogonEmail">
              <Metadata>
                <Item Key="Operation">Write</Item>
                <Item Key="RaiseErrorIfClaimsPrincipalAlreadyExists">true</Item>
              </Metadata>
              <IncludeInSso>false</IncludeInSso>
              <InputClaims>
                <InputClaim ClaimTypeReferenceId="email" PartnerClaimType="signInNames.emailAddress" Required="true" />
               </InputClaims>
              <PersistedClaims>
                      .......................
                <PersistedClaim ClaimTypeReferenceId="extension_empid" />
              </PersistedClaims>
              <OutputClaims>
                     ...........
                <OutputClaim ClaimTypeReferenceId="extension_empid"   />
    
            </OutputClaims>
              <IncludeTechnicalProfile ReferenceId="AAD-Common" />
              <UseTechnicalProfileForSessionManagement ReferenceId="SM-AAD" />
            </TechnicalProfile>

in LocalAccountSignUpWithLogonEmail

Email signup IpAddress api.localaccountsignup Create
  </ValidationTechnicalProfiles>
  <UseTechnicalProfileForSessionManagement ReferenceId="SM-AAD" />
</TechnicalProfile>
You don’t seem to be referencing AAD-UserWriteUsingLogonEmail anywhere in your journey. So it’s not being called. Unless it’s in the VTP of LocalAccountSignUpWithLogonEmail? In which case it’s being called before your REST API in step 2. So the value would be null at this point. - Jas Suri - MSFT