Class OAuthTokenResponse
RFC 6749-compliant token response of the token endpoint (authorization_code, refresh_token and
client_credentials grants).
public sealed record OAuthTokenResponse : IEquatable<OAuthTokenResponse>
- Inheritance
-
OAuthTokenResponse
- Implements
- Inherited Members
- Extension Methods
Constructors
OAuthTokenResponse()
public OAuthTokenResponse()
Properties
AccessToken
[JsonPropertyName("access_token")]
public required string AccessToken { get; init; }
Property Value
ExpiresIn
[JsonPropertyName("expires_in")]
public required int ExpiresIn { get; init; }
Property Value
RefreshToken
Gets a new access token (and a new refresh token) at the token endpoint with
grant_type=refresh_token; each refresh token is valid once. Only for the authorization_code
and refresh_token grants.
[JsonPropertyName("refresh_token")]
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
public string? RefreshToken { get; init; }
Property Value
TokenType
[JsonPropertyName("token_type")]
public string TokenType { get; init; }
Property Value
Methods
Equals(object?)
public override bool Equals(object? obj)
Parameters
objobject
Returns
Equals(OAuthTokenResponse?)
public bool Equals(OAuthTokenResponse? other)
Parameters
otherOAuthTokenResponse
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(OAuthTokenResponse?, OAuthTokenResponse?)
public static bool operator ==(OAuthTokenResponse? left, OAuthTokenResponse? right)
Parameters
leftOAuthTokenResponserightOAuthTokenResponse
Returns
operator !=(OAuthTokenResponse?, OAuthTokenResponse?)
public static bool operator !=(OAuthTokenResponse? left, OAuthTokenResponse? right)
Parameters
leftOAuthTokenResponserightOAuthTokenResponse