Class IdToken (1.40.0)

publicclass IdTokenextendsAccessTokenimplementsSerializable

Represents a temporary IdToken and its JsonWebSignature object

Inheritance

Object > AccessToken > IdToken

Implements

Serializable

Static Methods

create(String tokenValue)

publicstaticIdTokencreate(StringtokenValue)

Creates an IdToken given the encoded Json Web Signature.

Parameter
Name Description
tokenValue String

String representation of the ID token.

Returns
Type Description
IdToken

returns com.google.auth.oauth2.IdToken

Exceptions
Type Description
IOException

if JWT token parsing fails

create(String tokenValue, JsonFactory jsonFactory)

publicstaticIdTokencreate(StringtokenValue,JsonFactoryjsonFactory)

Creates an IdToken given the encoded Json Web Signature and JSON Factory

Parameters
Name Description
tokenValue String

String representation of the ID token.

jsonFactory com.google.api.client.json.JsonFactory

JsonFactory to use for parsing the provided token.

Returns
Type Description
IdToken

returns com.google.auth.oauth2.IdToken

Exceptions
Type Description
IOException

if JWT token parsing fails

Methods

equals(Object obj)

publicbooleanequals(Objectobj)
Parameter
Name Description
obj Object
Returns
Type Description
boolean
Overrides

hashCode()

publicinthashCode()
Returns
Type Description
int
Overrides

toString()

publicStringtoString()
Returns
Type Description
String
Overrides

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.