LogoAntiRaid

@antiraid-ext/lockdowns/lockdownmanager

API reference for @antiraid-ext/lockdowns/lockdownmanager

@antiraid-ext/lockdowns/lockdownmanager

Types

CreateLockdown

Raw Type
type CreateLockdown = {
	id: string?,

	-- ID of the lockdown, if not provided a random one will be generated
	reason: string,

	-- Reason for the lockdown
	type: mode.LockdownMode,

	-- The type of lockdown mode to use
	data: any
}
PropTypeDescription
id?
-
reason
-
type
-
data
-

LockdownManager

Raw Type
type LockdownManager = {
	--- Returns a list of all lockdowns
	list: () -> {mode.Lockdown},

	--- Returns a lockdown by ID
	get: (id: string) -> mode.Lockdown | nil,

	--- Sets a lockdown, creating it if it does not exist
	---
	--- Returns the ID of the lockdown
	set: (lockdown: CreateLockdown) -> mode.Lockdown,

	--- Deletes a lockdown by ID
	delete: (id: string) -> ()
}
PropTypeDescription
list
() -> {mode.Lockdown}
Returns a list of all lockdowns
get
(id: string) -> (mode.Lockdown | nil)
Returns a lockdown by ID
set
Sets a lockdown, creating it if it does not existReturns the ID of the lockdown
delete
(id: string) -> ()
Deletes a lockdown by ID

Functions

LockdownManager

A data fetcher for lockdowns.

Function Signature
--- A data fetcher for lockdowns.
function LockdownManager(ctx: Primitives.TemplateContext, reg_val: mode.LockdownModeRegistry?) -> LockdownManager end

Arguments

ctx

Primitives.TemplateContext

reg_val

This field is optional and may not be specified

mode.LockdownModeRegistry?

Returns

ret1

LockdownManager

Last updated on