I am trying to create a policy in Azure APIM to validate JWT Tokens (Azure AD tokens) based on two different claims.
My API may be consumed by either other applications or users - it may be called from an user context or an application context. As such, the token might contain either the "scp" claim e.g. user_impersonation
or "roles" claim like [ "CallApiAsAnApp" ]
.
From the documentation, I have not found any way to do this. Is this possible or do I have to implement custom code to do this at the API level? Any claims added to "required-claims" in the policy become mandatory. There doesn't seem to be any "match-any" option at the claims level, only values level.