Table of Contents

Interface IOtpRepository

Namespace
SEBT.Portal.Core.Repositories
Assembly
SEBT.Portal.Core.dll

Repository interface for managing OTP (One-Time Password) codes.

public interface IOtpRepository

Methods

DeleteOtpCodeByEmailAsync(string)

Deletes the OTP code associated with the specified email.

Task DeleteOtpCodeByEmailAsync(string email)

Parameters

email string

The email address associated with the OTP code to delete.

Returns

Task

A task representing the asynchronous operation.

GetOtpCodeByEmailAsync(string)

Retrieves the OTP code associated with the specified email.

Task<OtpCode?> GetOtpCodeByEmailAsync(string email)

Parameters

email string

The email address associated with the OTP code.

Returns

Task<OtpCode>

A task that represents the asynchronous operation. The task result contains the OTP code if found; otherwise, null.

SaveOtpCodeAsync(OtpCode)

Saves the provided OTP code to the repository.

Task SaveOtpCodeAsync(OtpCode otpCode)

Parameters

otpCode OtpCode

The OTP code to save.

Returns

Task

A task representing the asynchronous operation.