add "me" endpoint
This commit is contained in:
parent
98b38f645f
commit
ae1a8d2b97
7 changed files with 49 additions and 10 deletions
16
SurveyBackend/SurveyBackend.API/DTOs/User/UserLoginDto.cs
Normal file
16
SurveyBackend/SurveyBackend.API/DTOs/User/UserLoginDto.cs
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
namespace SurveyBackend.DTOs.User;
|
||||
|
||||
/// <summary>
|
||||
/// Схема авторизации пользователя
|
||||
/// </summary>
|
||||
public record UserLoginDto
|
||||
{
|
||||
/// <summary>
|
||||
/// Почта
|
||||
/// </summary>
|
||||
public required string Email { get; set; }
|
||||
/// <summary>
|
||||
/// Пароль
|
||||
/// </summary>
|
||||
public required string Password { get; set; }
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
namespace SurveyBackend.DTOs.User;
|
||||
|
||||
public class UserOutputDto
|
||||
{
|
||||
public long Id { get; set; }
|
||||
public required string Email { get; set; }
|
||||
public required string FirstName { get; set; }
|
||||
public string? LastName { get; set; }
|
||||
}
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
namespace SurveyBackend.DTOs.User;
|
||||
|
||||
/// <summary>
|
||||
/// Схема регистрации пользователя
|
||||
/// </summary>
|
||||
public record UserRegistrationDto
|
||||
{
|
||||
/// <summary>
|
||||
/// Почта
|
||||
/// </summary>
|
||||
public required string Email { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Имя
|
||||
/// </summary>
|
||||
public string FirstName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Фамилия
|
||||
/// </summary>
|
||||
public string LastName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Пароль
|
||||
/// </summary>
|
||||
public string Password { get; set; }
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue