MCPcopy Create free account
hub / github.com/authlib/authlib / get_authorization_code_claims

Method get_authorization_code_claims

authlib/oidc/core/grants/code.py:28–41  ·  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 if nonce := authorization_code.get_nonce():
31 claims["nonce"] = nonce
32
33 if auth_time := authorization_code.get_auth_time():
34 claims["auth_time"] = auth_time
35
36 if acr := authorization_code.get_acr():
37 claims["acr"] = acr
38
39 if amr := authorization_code.get_amr():
40 claims["amr"] = amr
41 return claims
42
43 def generate_user_info(self, user, scope):
44 """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