using adas_core.Domain.Models.MongoModels; using adas_core.Domain.Models.Responses; using MongoDB.Bson; namespace adas_core.Application.Services.Interfaces; public interface IAuthService { /// /// Asynchronously retrieves the current login response, returning null when no login state is available. /// /// A that resolves to the current , or null if no login response exists. Task GetLoginResponse(); /// /// Asynchronously retrieves a token. /// /// A task that represents the asynchronous operation. The task result contains the retrieved token string. Task GetToken(); /// /// Retrieves a list of authorizations associated with the specified unit identifier. /// /// The unique identifier of the unit whose authorizations are being queried. /// A task that represents the asynchronous operation, containing a list of objects matching the provided unit identifier. Task> GetByUnitId(ObjectId unitId); /// /// Asynchronously deletes the record identified by the specified display identifier. /// /// The display identifier of the record to delete. /// A task that represents the asynchronous operation, containing a value indicating whether the record was successfully deleted. Task DeleteByDisplayId(ObjectId displayId); /// /// Asynchronously deletes the entity associated with the specified unit identifier. /// /// The unique identifier of the unit whose associated entity should be deleted. /// A task that represents the asynchronous operation, containing a value indicating whether the deletion was successful. Task DeleteByUnitId(ObjectId unitId); /// /// Retrieves the list of authorizations associated with the specified user identifier. /// /// The unique identifier of the user whose authorizations are being retrieved. /// A task that represents the asynchronous operation, containing the list of authorizations for the user. Task> GetUserAuthorities(ObjectId id); }