Class AuthResultDto
Data transfer object for authentication operation results.
Inherited Members
Namespace: OEMS.Core.Application.DTOs.Login
Assembly: OEMS.Core.dll
Syntax
public class AuthResultDto
Remarks
This DTO is returned from login, registration, and token refresh operations.
Properties
ErrorMessage
Error message in case of authentication failure.
Declaration
public string ErrorMessage { get; set; }
Property Value
Type | Description |
---|---|
string |
Remarks
This field will be null or empty when Success is true.
ExpiryDate
Expiration date and time of the JWT token.
Declaration
public DateTime? ExpiryDate { get; set; }
Property Value
Type | Description |
---|---|
DateTime? |
RefreshToken
Refresh token for obtaining a new JWT token when the current one expires.
Declaration
public string RefreshToken { get; set; }
Property Value
Type | Description |
---|---|
string |
Success
Indicates whether the authentication operation was successful.
Declaration
public bool Success { get; set; }
Property Value
Type | Description |
---|---|
bool |
Token
JWT token for authenticating subsequent requests.
Declaration
public string Token { get; set; }
Property Value
Type | Description |
---|---|
string |
Remarks
This token should be included in the Authorization header for protected API endpoints.
User
The authenticated user object with details.
Declaration
public User User { get; set; }
Property Value
Type | Description |
---|---|
User |
Remarks
Only provided when authentication is successful.