namespace MyOffice.Data.Repositories.Users;

using Models.Users;

public interface IUserExternalRepository
{
	int AddUserExternal(UserExternal external);
	Task<int> AddUserExternalAsync(UserExternal external, CancellationToken cancellationToken = default);

	Task<List<UserExternal>> GetUserExternalsByUserIdAsync(Guid userId);

	Task<UserExternal?> GetByUserIdAsync(Guid userId, string provider);
	UserExternal? GetByUserId(Guid userId, string provider);

	UserExternal? GetByExternalId(string externalId, string provider);
	Task<UserExternal?> GetByExternalIdAsync(string externalId, string provider);

	void RemoveUserExternal(UserExternal userExternal);
	Task RemoveUserExternalAsync(UserExternal userExternal, CancellationToken cancellationToken = default);
}