Table of Contents

Class LoginCommandHandler

Namespace
KadicAuth.Application.Auth.Commands.LoginCommands
Assembly
KadicAuth.Application.dll
public sealed class LoginCommandHandler : IRequestHandler<LoginCommand, LoginResponseDto>
Inheritance
object
LoginCommandHandler
Implements
IRequestHandler<LoginCommand, LoginResponseDto>

Constructors

LoginCommandHandler(IAuthRepository, IUserTenantBranchRepository, IPasswordHasher, IJwtTokenGenerator, IRefreshTokenRepository, IUserSessionRepository, ILoginAttemptRepository, IPlatformAdminService, IStringLocalizer<AuthMessages>, IAuditService?, IAuthUnitOfWork?, IOptions<JwtSettings>?, ILogger<LoginCommandHandler>?)

public LoginCommandHandler(IAuthRepository authRepository, IUserTenantBranchRepository userTenantBranchRepository, IPasswordHasher passwordHasher, IJwtTokenGenerator jwtTokenGenerator, IRefreshTokenRepository refreshTokenRepository, IUserSessionRepository userSessionRepository, ILoginAttemptRepository loginAttemptRepository, IPlatformAdminService platformAdminService, IStringLocalizer<AuthMessages> localizer, IAuditService? auditService = null, IAuthUnitOfWork? unitOfWork = null, IOptions<JwtSettings>? jwtOptions = null, ILogger<LoginCommandHandler>? logger = null)

Parameters

authRepository IAuthRepository
userTenantBranchRepository IUserTenantBranchRepository
passwordHasher IPasswordHasher
jwtTokenGenerator IJwtTokenGenerator
refreshTokenRepository IRefreshTokenRepository
userSessionRepository IUserSessionRepository
loginAttemptRepository ILoginAttemptRepository
platformAdminService IPlatformAdminService
localizer IStringLocalizer<AuthMessages>
auditService IAuditService
unitOfWork IAuthUnitOfWork
jwtOptions IOptions<JwtSettings>
logger ILogger<LoginCommandHandler>

Methods

Handle(LoginCommand, CancellationToken)

Handles a request

public Task<LoginResponseDto> Handle(LoginCommand request, CancellationToken cancellationToken)

Parameters

request LoginCommand

The request

cancellationToken CancellationToken

Cancellation token

Returns

Task<LoginResponseDto>

Response from the request