18 lines
506 B
C#
18 lines
506 B
C#
using System.Net;
|
|
|
|
namespace SharpChat.Bans;
|
|
|
|
public interface BansClient {
|
|
Task BanCreateAsync(
|
|
BanKind kind,
|
|
TimeSpan duration,
|
|
IPAddress remoteAddr,
|
|
string? userId = null,
|
|
string? reason = null,
|
|
IPAddress? issuerRemoteAddr = null,
|
|
string? issuerUserId = null
|
|
);
|
|
Task<bool> BanRevokeAsync(BanInfo info);
|
|
Task<BanInfo?> BanGetAsync(string? userIdOrName = null, IPAddress? remoteAddr = null);
|
|
Task<BanInfo[]> BanGetListAsync();
|
|
}
|