2024-11-13 23:16:49 +00:00
|
|
|
using BotSharp.Abstraction.Repositories.Filters;
|
2023-06-11 23:46:02 +00:00
|
|
|
using BotSharp.Abstraction.Users.Models;
|
2024-05-26 01:34:29 +00:00
|
|
|
using BotSharp.OpenAPI.ViewModels.Users;
|
2023-06-11 23:46:02 +00:00
|
|
|
|
|
|
|
|
namespace BotSharp.Abstraction.Users;
|
|
|
|
|
|
|
|
|
|
public interface IUserService
|
|
|
|
|
{
|
2023-11-14 01:25:25 +00:00
|
|
|
Task<User> GetUser(string id);
|
2024-10-31 19:36:26 +00:00
|
|
|
Task<PagedItems<User>> GetUsers(UserFilter filter);
|
2024-11-13 23:16:49 +00:00
|
|
|
Task<User?> GetUserDetails(string userId);
|
2024-11-14 23:33:26 +00:00
|
|
|
Task<bool> IsAuthorizedUser(string userId);
|
|
|
|
|
Task<UserAuthorization> GetUserAuthorizations(string? agentId = null);
|
2024-11-13 23:16:49 +00:00
|
|
|
Task<bool> UpdateUser(User user, bool isUpdateUserAgents = false);
|
2023-06-11 23:46:02 +00:00
|
|
|
Task<User> CreateUser(User user);
|
2024-05-26 01:34:29 +00:00
|
|
|
Task<Token> ActiveUser(UserActivationModel model);
|
2024-09-20 07:48:34 +00:00
|
|
|
Task<Token?> GetAffiliateToken(string authorization);
|
2024-10-19 09:16:55 +00:00
|
|
|
Task<Token?> GetAdminToken(string authorization);
|
2024-09-21 07:12:08 +00:00
|
|
|
Task<Token?> GetToken(string authorization);
|
2023-06-11 23:46:02 +00:00
|
|
|
Task<User> GetMyProfile();
|
2024-05-30 09:11:42 +00:00
|
|
|
Task<bool> VerifyUserNameExisting(string userName);
|
|
|
|
|
Task<bool> VerifyEmailExisting(string email);
|
2024-10-12 07:13:46 +00:00
|
|
|
Task<bool> VerifyPhoneExisting(string phone);
|
2024-10-06 09:49:34 +00:00
|
|
|
Task<bool> SendVerificationCodeResetPasswordNoLogin(User user);
|
|
|
|
|
Task<bool> SendVerificationCodeResetPasswordLogin();
|
2024-06-28 09:59:49 +00:00
|
|
|
Task<bool> ResetUserPassword(User user);
|
2024-07-24 10:49:54 +00:00
|
|
|
Task<bool> ModifyUserEmail(string email);
|
2024-10-22 10:43:34 +00:00
|
|
|
Task<bool> ModifyUserPhone(string phone, string regionCode);
|
2024-09-17 10:31:38 +00:00
|
|
|
Task<bool> UpdatePassword(string newPassword, string verificationCode);
|
2024-09-17 09:39:34 +00:00
|
|
|
Task<DateTime> GetUserTokenExpires();
|
2024-09-29 11:26:17 +00:00
|
|
|
Task<bool> UpdateUsersIsDisable(List<string> userIds, bool isDisable);
|
2023-06-11 23:46:02 +00:00
|
|
|
}
|