DiscordLua
discorddiscord
v1.2.4
Install

Typing

Class
On this page

Typing 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

Typing.channel

# readonly
Name
channel
Type
any
Access
readonly
Description
Channel this Typing belongs to, when resolved from cache.
Availability
Populated from the Gateway/REST payload or constructor for this Typing.

Typing.channelId

# readonly
Name
channelId
Type
any
Access
readonly
Description
Instance field Typing.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 Typing.

Typing.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 Typing.

Typing.guild

# readonly
Name
guild
Type
any
Access
readonly
Description
Guild this Typing belongs to, when the payload included a guild id.
Availability
Populated from the Gateway/REST payload or constructor for this Typing.

Typing.guildId

# readonly
Name
guildId
Type
any
Access
readonly
Description
Instance field Typing.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 Typing.

Typing.member

# readonly
Name
member
Type
any
Access
readonly
Description
Guild member view of the user, when the event occurred in a guild.
Availability
Populated from the Gateway/REST payload or constructor for this Typing.

Typing.raw

# readonly
Name
raw
Type
any
Access
readonly
Description
Instance field Typing.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 Typing.

Typing.startedAt

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

Typing.startedTimestamp

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

Typing.user

# readonly
Name
user
Type
any
Access
readonly
Description
User object associated with this Typing.
Availability
Populated from the Gateway/REST payload or constructor for this Typing.

Typing.userId

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

Methods

Typing:inGuild()

#

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

Signature

Typing:inGuild()

Parameters

No parameters.

Returns

Typing — the same instance, for chaining.

Example

lua
local discord = require("discord")
-- object is a Typing
object:inGuild()

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