[keycloak-user] Add other claims to authorization response

Tom Billiet tom.billiet at airties.com
Wed Oct 2 06:19:16 EDT 2019


Hi,

When you have a successful oauth authorization, you'll get a json struct returned that contains some fields like "access_token" and "refresh_token".
I would like to add some extra properties to this json structure to pass some information to the client. Unfortunately I don't think it's possible at the moment is keycloak?

At the moment we're embedding this "metadata" inside the access_token field, but this requires the client to parse the access_token. We'd rather avoid this requirement.
Looking at the code, I would think the "org.keycloak.representations.AccessTokenResponse" allows for this (the "otherClaims" property), but I don't think there is any way to set this information from a custom plugin, or am I missing something?

Thanks,
Tom
[http://www.airties.com.tr/images/internal/IMZA_ALT_BANNER.jpg]


This message has been scanned for malware by Websense. www.websense.com


More information about the keycloak-user mailing list