MCPcopy
hub / github.com/authlib/authlib / get_authorization_code_claims

Method get_authorization_code_claims

authlib/oidc/core/grants/code.py:28–39  ·  view source on GitHub ↗
(self, authorization_code: AuthorizationCodeMixin)

Source from the content-addressed store, hash-verified

26
27class OpenIDToken(LegacyMixin):
28 def get_authorization_code_claims(self, authorization_code: AuthorizationCodeMixin):
29 claims = {
30 "nonce": authorization_code.get_nonce(),
31 "auth_time": authorization_code.get_auth_time(),
32 }
33
34 if acr := authorization_code.get_acr():
35 claims["acr"] = acr
36
37 if amr := authorization_code.get_amr():
38 claims["amr"] = amr
39 return claims
40
41 def generate_user_info(self, user, scope):
42 """Provide user information for the given scope. Developers

Callers 1

encode_id_tokenMethod · 0.95

Calls 4

get_nonceMethod · 0.45
get_auth_timeMethod · 0.45
get_acrMethod · 0.45
get_amrMethod · 0.45

Tested by

no test coverage detected