- LoginResponseDto에 nextAction, emailVerified, verifySessionId, emailSent 추가 - 미인증 유저 로그인 시 verify session/인증코드 생성 + 메일 발송 - Swagger Description에 분기 설명 추가 Closes #177
46 lines
1.2 KiB
C#
46 lines
1.2 KiB
C#
using System.Text.Json.Serialization;
|
|
|
|
namespace SPMS.Application.DTOs.Auth;
|
|
|
|
public class LoginResponseDto
|
|
{
|
|
[JsonPropertyName("access_token")]
|
|
public string AccessToken { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("refresh_token")]
|
|
public string RefreshToken { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("expires_in")]
|
|
public int ExpiresIn { get; set; }
|
|
|
|
[JsonPropertyName("next_action")]
|
|
public string NextAction { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("email_verified")]
|
|
public bool EmailVerified { get; set; }
|
|
|
|
[JsonPropertyName("verify_session_id")]
|
|
public string? VerifySessionId { get; set; }
|
|
|
|
[JsonPropertyName("email_sent")]
|
|
public bool? EmailSent { get; set; }
|
|
|
|
[JsonPropertyName("admin")]
|
|
public AdminInfoDto? Admin { get; set; }
|
|
}
|
|
|
|
public class AdminInfoDto
|
|
{
|
|
[JsonPropertyName("admin_code")]
|
|
public string AdminCode { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("email")]
|
|
public string Email { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("name")]
|
|
public string Name { get; set; } = string.Empty;
|
|
|
|
[JsonPropertyName("role")]
|
|
public string Role { get; set; } = string.Empty;
|
|
}
|