@@ -32,6 +32,16 @@ def introspect_idp_access_token(
32
32
client_secret : Optional [str ] = None ,
33
33
token_type_hint : str = "access_token" ,
34
34
) -> Optional [AccessTokenJWTClaims ]:
35
+ """Introspects a token JWT from an authorization code response.
36
+ Access tokens and refresh tokens are JWTs signed with the project's JWKs.
37
+ Access tokens contain a standard set of claims as well as any custom claims generated from templates.
38
+
39
+ Fields:
40
+ - access_token: The access token (or refresh token) to introspect.
41
+ - client_id: The ID of the client.
42
+ - client_secret: The secret of the client.
43
+ - token_type_hint: A hint on what the token contains. Valid fields are 'access_token' and 'refresh_token'.
44
+ """
35
45
return self .introspect_idp_access_token_local (
36
46
access_token , client_id
37
47
) or self .introspect_idp_access_token_network (
@@ -45,6 +55,16 @@ async def introspect_idp_access_token_async(
45
55
client_secret : Optional [str ] = None ,
46
56
token_type_hint : str = "access_token" ,
47
57
) -> Optional [AccessTokenJWTClaims ]:
58
+ """Introspects a token JWT from an authorization code response.
59
+ Access tokens and refresh tokens are JWTs signed with the project's JWKs.
60
+ Access tokens contain a standard set of claims as well as any custom claims generated from templates.
61
+
62
+ Fields:
63
+ - access_token: The access token (or refresh token) to introspect.
64
+ - client_id: The ID of the client.
65
+ - client_secret: The secret of the client.
66
+ - token_type_hint: A hint on what the token contains. Valid fields are 'access_token' and 'refresh_token'.
67
+ """
48
68
local_introspection_response = self .introspect_idp_access_token_local (access_token , client_id )
49
69
if local_introspection_response is not None :
50
70
return local_introspection_response
@@ -59,6 +79,16 @@ def introspect_idp_access_token_network(
59
79
client_secret : Optional [str ] = None ,
60
80
token_type_hint : str = "access_token" ,
61
81
) -> Optional [AccessTokenJWTClaims ]:
82
+ """Introspects a token JWT from an authorization code response.
83
+ Access tokens and refresh tokens are JWTs signed with the project's JWKs.
84
+ Access tokens contain a standard set of claims as well as any custom claims generated from templates.
85
+
86
+ Fields:
87
+ - access_token: The access token (or refresh token) to introspect.
88
+ - client_id: The ID of the client.
89
+ - client_secret: The secret of the client.
90
+ - token_type_hint: A hint on what the token contains. Valid fields are 'access_token' and 'refresh_token'.
91
+ """
62
92
headers : Dict [str , str ] = {"Content-Type" : "application/x-www-form-urlencoded" }
63
93
data : Dict [str , Any ] = {
64
94
"token" : access_token ,
@@ -95,6 +125,16 @@ async def introspect_idp_access_token_network_async(
95
125
client_secret : Optional [str ] = None ,
96
126
token_type_hint : str = "access_token" ,
97
127
) -> Optional [AccessTokenJWTClaims ]:
128
+ """Introspects a token JWT from an authorization code response.
129
+ Access tokens and refresh tokens are JWTs signed with the project's JWKs.
130
+ Access tokens contain a standard set of claims as well as any custom claims generated from templates.
131
+
132
+ Fields:
133
+ - access_token: The access token (or refresh token) to introspect.
134
+ - client_id: The ID of the client.
135
+ - client_secret: The secret of the client.
136
+ - token_type_hint: A hint on what the token contains. Valid fields are 'access_token' and 'refresh_token'.
137
+ """
98
138
headers : Dict [str , str ] = {"Content-Type" : "application/x-www-form-urlencoded" }
99
139
data : Dict [str , Any ] = {
100
140
"token" : access_token ,
@@ -129,6 +169,14 @@ def introspect_idp_access_token_local(
129
169
access_token : str ,
130
170
client_id : str ,
131
171
) -> Optional [AccessTokenJWTClaims ]:
172
+ """Introspects a token JWT from an authorization code response.
173
+ Access tokens and refresh tokens are JWTs signed with the project's JWKs.
174
+ Access tokens contain a standard set of claims as well as any custom claims generated from templates.
175
+
176
+ Fields:
177
+ - access_token: The access token (or refresh token) to introspect.
178
+ - client_id: The ID of the client.
179
+ """
132
180
_scope_claim = "scope"
133
181
generic_claims = jwt_helpers .authenticate_jwt_local (
134
182
project_id = self .project_id ,
0 commit comments