scenario :capture query string parameters using a Claims Resolver.
If you have captured ?queryname=queryvalue
as the query string parameter, that could be resolved via the {OAUTH-KV:queryname }
claims resolver.
In your 's output claims, you could then refer to a claim and the value like this:
<OutputClaim ClaimTypeReferenceId="customClaimId" AlwaysUseDefaultValue="true" DefaultValue="{OAUTH-KV:queryname }" />
You would just need a Claim definition for customClaimId.
<UserJourneyBehaviors>
<ContentDefinitionParameters>
<Parameter Name="Value">{OAUTH-KV:queryname }</Parameter>
</ContentDefinitionParameters>
<ScriptExecution>Allow</ScriptExecution>
</UserJourneyBehaviors>
Or you can send the hard coded values to the query string parameter
<RelyingParty>
<DefaultUserJourney ReferenceId="MyUserJourney" />
<UserJourneyBehaviors>
<JourneyInsights TelemetryEngine="ApplicationInsights" InstrumentationKey="{Settings:AppInsightsKey}" DeveloperMode="true" ClientEnabled="true" ServerEnabled="true" TelemetryVersion="1.0.0" />
<ScriptExecution>Allow</ScriptExecution>
</UserJourneyBehaviors>
<TechnicalProfile Id="PolicyProfile">
…
<OutputClaims>
<OutputClaim ClaimTypeReferenceId="objectId" PartnerClaimType="sub" AlwaysUseDefaultValue="true" DefaultValue="4545xxxx" />
<OutputClaim ClaimTypeReferenceId="value" DefaultValue="{OAUTH-KV:queryvaluevalue}" AlwaysUseDefaultValue="true" />
</OutputClaims>
<SubjectNamingInfo ClaimType="sub" />
</TechnicalProfile>
</RelyingParty>
And then call the token endpoint like below as said by @JasSuri in azure ad b2c - AzureB2C - Client credentials and query parameters in a custom policy - Stack Overflow
https://{tenant
name}.b2clogin.com/{tenantname}.onmicrosoft.com/B2C_1A_/oauth2/v2.0/token?grant_type=client_credentials&client_id=&client_secret=<client_secret>&scope=https://{tenant}.onmicrosoft.com/api/.default&value=somefoo
Also check this oauth 2.0 - Azure B2C - Accept query params into OAuth2 JWT - Stack Overflow