using StellaOps.Authority.Storage.Mongo.Documents;

namespace StellaOps.Authority.Storage.Mongo.Stores;

public interface IAuthorityScopeStore
{
    ValueTask<AuthorityScopeDocument?> FindByNameAsync(string name, CancellationToken cancellationToken);

    ValueTask<IReadOnlyList<AuthorityScopeDocument>> ListAsync(CancellationToken cancellationToken);

    ValueTask UpsertAsync(AuthorityScopeDocument document, CancellationToken cancellationToken);

    ValueTask<bool> DeleteByNameAsync(string name, CancellationToken cancellationToken);
}
