Package | Description |
---|---|
com.google.api.client.auth.oauth2 |
Implementation of the OAuth 2.0 Authorization
Framework.
|
com.google.api.client.auth.openidconnect |
Modifier and Type | Field and Description |
---|---|
protected Class<? extends TokenResponse> |
TokenRequest.responseClass
Response container class for deserialization.
|
Modifier and Type | Method and Description |
---|---|
TokenResponse |
TokenResponse.clone() |
TokenResponse |
TokenRequest.execute()
Executes request for an access token, and returns the parsed access token response.
|
protected TokenResponse |
Credential.executeRefreshToken()
Executes a request for new credentials from the token server.
|
TokenResponse |
TokenResponse.set(String fieldName,
Object value) |
TokenResponse |
TokenResponse.setAccessToken(String accessToken)
Sets the access token issued by the authorization server.
|
TokenResponse |
TokenResponse.setExpiresInSeconds(Long expiresInSeconds)
Sets the lifetime in seconds of the access token (for example 3600 for an hour) or
null
for none. |
TokenResponse |
TokenResponse.setRefreshToken(String refreshToken)
Sets the refresh token which can be used to obtain new access tokens using the same
authorization grant or
null for none. |
TokenResponse |
TokenResponse.setScope(String scope)
Sets the scope of the access token or
null for none. |
TokenResponse |
TokenResponse.setTokenType(String tokenType)
Sets the token type (as specified in Access Token Types).
|
Modifier and Type | Method and Description |
---|---|
Class<? extends TokenResponse> |
TokenRequest.getResponseClass()
Returns the response class.
|
Modifier and Type | Method and Description |
---|---|
Credential |
AuthorizationCodeFlow.createAndStoreCredential(TokenResponse response,
String userId)
Creates a new credential for the given user ID based on the given token response
and stores it in the credential store.
|
void |
AuthorizationCodeFlow.CredentialCreatedListener.onCredentialCreated(Credential credential,
TokenResponse tokenResponse)
Notifies of a created credential after a successful token response in
AuthorizationCodeFlow.createAndStoreCredential(com.google.api.client.auth.oauth2.TokenResponse, java.lang.String) . |
void |
CredentialRefreshListener.onTokenResponse(Credential credential,
TokenResponse tokenResponse)
Notifies of a successful token response from
Credential.refreshToken() . |
void |
DataStoreCredentialRefreshListener.onTokenResponse(Credential credential,
TokenResponse tokenResponse) |
void |
CredentialStoreRefreshListener.onTokenResponse(Credential credential,
TokenResponse tokenResponse)
Deprecated.
|
Credential |
Credential.setFromTokenResponse(TokenResponse tokenResponse)
Sets the
access token , refresh token (if
available), and expires-in time based on the values from the token
response. |
Modifier and Type | Method and Description |
---|---|
PasswordTokenRequest |
PasswordTokenRequest.setResponseClass(Class<? extends TokenResponse> responseClass) |
ClientCredentialsTokenRequest |
ClientCredentialsTokenRequest.setResponseClass(Class<? extends TokenResponse> responseClass) |
AuthorizationCodeTokenRequest |
AuthorizationCodeTokenRequest.setResponseClass(Class<? extends TokenResponse> responseClass) |
RefreshTokenRequest |
RefreshTokenRequest.setResponseClass(Class<? extends TokenResponse> responseClass) |
TokenRequest |
TokenRequest.setResponseClass(Class<? extends TokenResponse> responseClass)
Sets the TokenResponse class to allow specifying object parsing.
|
Constructor and Description |
---|
TokenRequest(HttpTransport transport,
JsonFactory jsonFactory,
GenericUrl tokenServerUrl,
String grantType,
Class<? extends TokenResponse> responseClass)
Creates a new TokenRequest.
|
Modifier and Type | Class and Description |
---|---|
class |
IdTokenResponse
Beta OAuth ID Connect JSON model for a successful access token response as specified in OpenID Connect Basic Client Profile 1.0 (draft 23). |
Copyright © 2011–2019 Google. All rights reserved.