Extends
BaseHandler
Constructors
new Denylist()
new Denylist(
handler):Denylist
Parameters
| Parameter | Type |
|---|---|
handler | RequestHandler |
Returns
Inherited from
BaseHandler.constructor
Properties
| Property | Modifier | Type | Inherited from |
|---|---|---|---|
_handler | public | RequestHandler | BaseHandler._handler |
Methods
createDenylist()
createDenylist(
guildId,data):Promise<DenylistEntry>
Create a new denylist entry
Parameters
| Parameter | Type | Description |
|---|---|---|
guildId | string | The guild ID to create the entry in |
data | { id: string; type: "channel" | "role" | "user"; } | The entry data |
data.id | string | - |
data.type | "channel" | "role" | "user" | - |
Returns
deleteAllDenylists()
deleteAllDenylists(
guildId):Promise<CountResponse>
Delete all denylists for a guild
Parameters
| Parameter | Type | Description |
|---|---|---|
guildId | string | The guild ID to delete denylists from |
Returns
deleteAllDenylistsByType()
deleteAllDenylistsByType(
guildId,type):Promise<CountResponse>
Delete all denylists for a guild by type
Parameters
| Parameter | Type | Description |
|---|---|---|
guildId | string | The guild ID to delete denylists from |
type | "channel" | "role" | "user" | The type of denylists to delete |
Returns
deleteDenylistById()
deleteDenylistById(
guildId,type,id):Promise<DenylistEntry>
Delete a specific denylist entry
Parameters
| Parameter | Type | Description |
|---|---|---|
guildId | string | The guild ID the entry is in |
type | "channel" | "role" | "user" | "internal" | - |
id | string | The ID of the entry to delete, this can be the internal ID, user ID, channel ID or role ID |
Returns
getDenylists()
Get all denylists for a guild
Parameters
| Parameter | Type | Description |
|---|---|---|
guildId | string | The guild ID to get denylists for |