Class TokenResponseException (1.55.0)

Stay organized with collections Save and categorize content based on your preferences.
public class TokenResponseException : Exception, ISerializable

Token response exception which is thrown in case of receiving a token error when an authorization code or an access token is expected.

Inheritance

Object > Exception > TokenResponseException

Implements

ISerializable

Namespace

Google.Apis.Auth.OAuth2.Responses

Assembly

Google.Apis.Auth.dll

Constructors

TokenResponseException(TokenErrorResponse)

public TokenResponseException(TokenErrorResponse error)

Constructs a new token response exception from the given error.

Parameter
NameDescription
errorTokenErrorResponse

TokenResponseException(TokenErrorResponse, Nullable<HttpStatusCode>)

public TokenResponseException(TokenErrorResponse error, HttpStatusCode? statusCode)

Constructs a new token response exception from the given error nad optional HTTP status code.

Parameters
NameDescription
errorTokenErrorResponse
statusCodeNullable<HttpStatusCode>

Properties

Error

public TokenErrorResponse Error { get; }

The error information.

Property Value
TypeDescription
TokenErrorResponse

StatusCode

public HttpStatusCode? StatusCode { get; }

HTTP status code of error, or null if unknown.

Property Value
TypeDescription
Nullable<HttpStatusCode>

Extension Method