0
votes

I am working on an ADB2C Signup Custom Policy. There are some fields/user attributes which I want to prefill based on the values passed in url using some query parameter or so. I have tried {OAUTH-KV:query_parameter} claim resolver mentioned in the following link: https://docs.microsoft.com/en-us/azure/active-directory-b2c/claim-resolver-overview#using-claim-resolvers but was not able to achieve this. Any suggestion/solution will be really helpful.Thanks in Advance.

1

1 Answers

0
votes

This will depend largely on the type of Technical Profile, but there are two things I would recommend checking in your implementation.

First, you need to make sure that you are setting the DefaultValue attribute, and setting AlwaysUseDefaultValue to true. Here is a working example from a Self Asserted technical profile.

<InputClaims>
  <InputClaim ClaimTypeReferenceId="email" DefaultValue="{OAUTH-KV:userEmailParameter}" AlwaysUseDefaultValue="true"/>
</InputClaims>
<OutputClaims>
   <OutputClaim ClaimTypeReferenceId="email" Required="true"/>
   <OutputClaim ClaimTypeReferenceId="password" Required="true"/>
</OutputClaims>

Second, on some technical profiles, you must have the IncludeClaimResolvingInClaimsHandling metadata attribute added and set to true.

<Metadata>
  <Item Key="IncludeClaimResolvingInClaimsHandling">true</Item>
</Metadata>

Feel free to edit your original post and include the technical profile you have configured, and I may be able to better help.