DiscordLua
discorddiscord
v1.2.4
Install

GuildScheduledEvent

Class
On this page

GuildScheduledEvent is a DiscordLua class representing a Discord resource. Obtain it from a manager, an event payload, or the constructor when one is documented below.

class Module 1.2.4 Source

Properties

GuildScheduledEvent.channelId

# readonly
Name
channelId
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.channelId. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.client

# readonly
Name
client
Type
any
Access
readonly
Description
Owning Client instance used for REST, cache, and event dispatch.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.creator

# readonly
Name
creator
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.creator. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.creatorId

# readonly
Name
creatorId
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.creatorId. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.description

# mutable
Name
description
Type
any
Access
mutable
Description
Instance field GuildScheduledEvent.description. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.entityId

# readonly
Name
entityId
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.entityId. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.entityMetadata

# readonly
Name
entityMetadata
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.entityMetadata. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.entityType

# readonly
Name
entityType
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.entityType. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.guildId

# readonly
Name
guildId
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.guildId. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.id

# readonly
Name
id
Type
any
Access
readonly
Description
Snowflake id of this GuildScheduledEvent.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.image

# readonly
Name
image
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.image. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.name

# mutable
Name
name
Type
any
Access
mutable
Description
Display name of this GuildScheduledEvent.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.partial

# readonly
Name
partial
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.partial. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.privacyLevel

# readonly
Name
privacyLevel
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.privacyLevel. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.raw

# readonly
Name
raw
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.raw. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.recurrenceRule

# readonly
Name
recurrenceRule
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.recurrenceRule. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.scheduledEndAt

# readonly
Name
scheduledEndAt
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.scheduledEndAt. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.scheduledEndTimestamp

# readonly
Name
scheduledEndTimestamp
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.scheduledEndTimestamp. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.scheduledStartAt

# readonly
Name
scheduledStartAt
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.scheduledStartAt. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.scheduledStartTimestamp

# readonly
Name
scheduledStartTimestamp
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.scheduledStartTimestamp. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.status

# mutable
Name
status
Type
any
Access
mutable
Description
Instance field GuildScheduledEvent.status. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

GuildScheduledEvent.userCount

# readonly
Name
userCount
Type
any
Access
readonly
Description
Instance field GuildScheduledEvent.userCount. Read it after the object is constructed or wrapped from Gateway/REST data.
Availability
Populated from the Gateway/REST payload or constructor for this GuildScheduledEvent.

Methods

GuildScheduledEvent:channel()

#

Performs channel on this GuildScheduledEvent. Call it from bot code when you need that operation on the current object.

Signature

GuildScheduledEvent:channel()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:channel()

GuildScheduledEvent:coverImageURL()

#

Performs cover image url on this GuildScheduledEvent. Call it from bot code when you need that operation on the current object.

Signature

GuildScheduledEvent:coverImageURL(options)

Parameters

NameTypeRequiredBehavior
options table optional Lua option table. Field names match the corresponding DiscordLua option type when one exists.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:coverImageURL({})

GuildScheduledEvent:createdAt()

#

Create dAt through REST and cache the result when the request succeeds. Pass function(err, result) to handle failures without raising.

Signature

GuildScheduledEvent:createdAt()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:createdAt()

GuildScheduledEvent:createdTimestamp()

#

Create dTimestamp through REST and cache the result when the request succeeds. Pass function(err, result) to handle failures without raising.

Signature

GuildScheduledEvent:createdTimestamp()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:createdTimestamp()

GuildScheduledEvent:createInviteURL()

#

Create InviteURL through REST and cache the result when the request succeeds. Pass function(err, result) to handle failures without raising.

Signature

GuildScheduledEvent:createInviteURL(options)

Parameters

NameTypeRequiredBehavior
options table optional Lua option table. Field names match the corresponding DiscordLua option type when one exists.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:createInviteURL({})

GuildScheduledEvent:delete()

#

Permanently delete this resource through REST.

Signature

GuildScheduledEvent:delete(callback)

Parameters

NameTypeRequiredBehavior
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:delete(function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:edit()

#

Apply a REST update to this resource.

Signature

GuildScheduledEvent:edit(options, callback)

Parameters

NameTypeRequiredBehavior
options table optional Lua option table. Field names match the corresponding DiscordLua option type when one exists.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:edit({}, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:fetch()

#

Request a fresh copy of this resource from REST and update the cache.

Signature

GuildScheduledEvent:fetch(options, callback)

Parameters

NameTypeRequiredBehavior
options table optional Lua option table. Field names match the corresponding DiscordLua option type when one exists.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:fetch({}, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:fetchSubscribers()

#

Fetch Subscribers from REST and update the local cache when the request succeeds.

Signature

GuildScheduledEvent:fetchSubscribers(options, callback)

Parameters

NameTypeRequiredBehavior
options table optional Lua option table. Field names match the corresponding DiscordLua option type when one exists.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:fetchSubscribers({}, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:guild()

#

Performs guild on this GuildScheduledEvent. Call it from bot code when you need that operation on the current object.

Signature

GuildScheduledEvent:guild()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:guild()

GuildScheduledEvent:isActive()

#

Predicate that returns whether this GuildScheduledEvent matches isActive. Use it to branch before calling type-specific methods.

Signature

GuildScheduledEvent:isActive()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:isActive()

GuildScheduledEvent:isCanceled()

#

Predicate that returns whether this GuildScheduledEvent matches isCanceled. Use it to branch before calling type-specific methods.

Signature

GuildScheduledEvent:isCanceled()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:isCanceled()

GuildScheduledEvent:isCompleted()

#

Predicate that returns whether this GuildScheduledEvent matches isCompleted. Use it to branch before calling type-specific methods.

Signature

GuildScheduledEvent:isCompleted()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:isCompleted()

GuildScheduledEvent:isScheduled()

#

Predicate that returns whether this GuildScheduledEvent matches isScheduled. Use it to branch before calling type-specific methods.

Signature

GuildScheduledEvent:isScheduled()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:isScheduled()

GuildScheduledEvent:setDescription()

#

Set the Description field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setDescription(description, callback)

Parameters

NameTypeRequiredBehavior
description any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setDescription(description, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:setLocation()

#

Set the Location field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setLocation(location, callback)

Parameters

NameTypeRequiredBehavior
location any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setLocation(location, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:setName()

#

Set the Name field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setName(name, callback)

Parameters

NameTypeRequiredBehavior
name any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setName(name, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:setScheduledEndTime()

#

Set the ScheduledEndTime field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setScheduledEndTime(time, callback)

Parameters

NameTypeRequiredBehavior
time any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setScheduledEndTime(time, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:setScheduledStartTime()

#

Set the ScheduledStartTime field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setScheduledStartTime(time, callback)

Parameters

NameTypeRequiredBehavior
time any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setScheduledStartTime(time, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:setStatus()

#

Set the Status field. Builders return this GuildScheduledEvent so setters can be chained.

Signature

GuildScheduledEvent:setStatus(status, callback)

Parameters

NameTypeRequiredBehavior
status any required Passed through to the implementation as written.
callback function optional Optional completion callback function(err, result). If omitted, failures raise a DiscordLua error.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:setStatus(status, function(err, result)
    if err then error(err) end
end)

GuildScheduledEvent:toJSON()

#

Serialize this GuildScheduledEvent into a Lua table suitable for REST or debugging.

Signature

GuildScheduledEvent:toJSON()

Parameters

No parameters.

Returns

any.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:toJSON()

GuildScheduledEvent:toString()

#

function toString() { [native code] }

Signature

GuildScheduledEvent:toString()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:toString()

GuildScheduledEvent:url()

#

Performs url on this GuildScheduledEvent. Call it from bot code when you need that operation on the current object.

Signature

GuildScheduledEvent:url()

Parameters

No parameters.

Returns

GuildScheduledEvent — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a GuildScheduledEvent
object:url()

Examples

Obtain this object from a manager, wrap helper, or event payload — it is not constructed directly in typical bot code.

ActionRow · Activity · ActivityInstance · ActivityLocation · AnonymousGuild · ApplicationCommand · ApplicationRoleConnectionMetadata · Attachment

Version: discord 1.2.4 · runtime 1.0.0

Search Ctrl K Navigate Open Esc