12 lines
449 B
C#
12 lines
449 B
C#
using Backend.Domain;
|
|
|
|
namespace Backend.Repositories;
|
|
|
|
public interface IUserSessionRepository
|
|
{
|
|
Task<UserSession?> GetActiveByTokenAsync(string token, CancellationToken cancellationToken = default);
|
|
Task<int> CountRecentSessionsFromIpAsync(string ipAddress, DateTimeOffset since, CancellationToken cancellationToken = default);
|
|
void Add(UserSession session);
|
|
Task SaveChangesAsync(CancellationToken cancellationToken = default);
|
|
}
|