Class TokenResponse
- Namespace
- Visus.AddressValidation.Http
- Assembly
- Visus.AddressValidation.dll
Represents a token response returned by an OAuth 2.0 / OpenID Connect token endpoint.
[JsonConverter(typeof(TokenResponseConverter))]
public sealed record TokenResponse : IEquatable<TokenResponse>
- Inheritance
-
TokenResponse
- Implements
- Inherited Members
Constructors
TokenResponse(string?, string?, string?, string?, int, string?, string?, string?)
Represents a token response returned by an OAuth 2.0 / OpenID Connect token endpoint.
public TokenResponse(string? AccessToken, string? RefreshToken, string? IdentityToken, string? IssuedTokenType, int ExpiresIn, string? Scope, string? TokenType, string? ErrorDescription)
Parameters
AccessTokenstringThe access token issued by the authorization server.
RefreshTokenstringThe refresh token, which can be used to obtain new access tokens, or null if not issued.
IdentityTokenstringThe identity token containing claims about the authenticated user, or null if not issued.
IssuedTokenTypestringA URI that indicates the type of the issued security token, as defined by RFC 8693, or null if not present.
ExpiresInintThe lifetime in seconds of the access token.
ScopestringThe scope of the access token as a space-delimited list of scope values, or null if identical to the requested scope.
TokenTypestringThe type of the token issued (e.g.
Bearer), or null if not present.ErrorDescriptionstringA human-readable description of the error that occurred during token issuance, or null if the request was successful.
Properties
AccessToken
The access token issued by the authorization server.
public string? AccessToken { get; init; }
Property Value
ErrorDescription
A human-readable description of the error that occurred during token issuance, or null if the request was successful.
public string? ErrorDescription { get; init; }
Property Value
ExpiresIn
The lifetime in seconds of the access token.
public int ExpiresIn { get; init; }
Property Value
IdentityToken
The identity token containing claims about the authenticated user, or null if not issued.
public string? IdentityToken { get; init; }
Property Value
IssuedTokenType
A URI that indicates the type of the issued security token, as defined by RFC 8693, or null if not present.
public string? IssuedTokenType { get; init; }
Property Value
RefreshToken
The refresh token, which can be used to obtain new access tokens, or null if not issued.
public string? RefreshToken { get; init; }
Property Value
Scope
The scope of the access token as a space-delimited list of scope values, or null if identical to the requested scope.
public string? Scope { get; init; }
Property Value
TokenType
The type of the token issued (e.g. Bearer), or null if not present.
public string? TokenType { get; init; }