AI-generated Key Takeaways
-
GoogleNowAuthState is a class that extends Object and implements Parcelable, representing the output of SearchAuthApi.getGoogleNowAuth.
-
It provides methods to retrieve the OAuth access token, the OAuth authorization code, or the next allowed request time if the request was throttled.
-
The access token is provided if an auth code was previously issued, while the auth code is used to obtain tokens via a web application.
-
The class also includes inherited methods from Object and Parcelable.
Output of
SearchAuthApi.getGoogleNowAuth(com.google.android.gms.common.api.GoogleApiClient,
String).
Inherited Constant Summary
Public Method Summary
| String |
getAccessToken()
Returns the OAuth access token or null if access token is unavailable.
|
| String |
getAuthCode()
Returns the OAuth authorization code or null if authorization code is
unavailable.
|
| long |
getNextAllowedTimeMillis()
If the request was rejected by the throttler then the next allowed request wall
time (milliseconds since epoch) is returned.
|
| String |
toString()
|
Inherited Method Summary
Public Methods
public String getAccessToken ()
Returns the OAuth access token or null if access token is unavailable.
Access token is made available instead of auth code when an authorization code was already issued for the web app client ID. This access token may be used with the Now API or it can be revoked to subsequently obtain a new auth code.
public String getAuthCode ()
Returns the OAuth authorization code or null if authorization code is unavailable.
The authorization code may be sent to the web application where it can be sent along with the client secret to the Google OAuth server to obtain a pair of refresh and access tokens. For details see Cross-client Identity.
If an authorization code was already issued for the web app client ID then an
authorization code will not be available and an access token will be made available
instead. See
getAccessToken().
public long getNextAllowedTimeMillis ()
If the request was rejected by the throttler then the next allowed request wall time (milliseconds since epoch) is returned.