UserCommandInfo

Represents a context command that acts on a user.

Properties

Link copied to clipboard

The permissions required for the bot to run this command.

Link copied to clipboard
abstract val context: BContext

The main context.

Link copied to clipboard

Purely for debugging purposes, will be shown in exceptions.

Link copied to clipboard

All options representing a Discord input.

Link copied to clipboard

Returns the full command name of this application command, separate with spaces.

Link copied to clipboard
abstract val function: KFunction<*>

The target function of this executable.

Link copied to clipboard
open override val guildId: Long?

The ID of the guild on which this command was pushed on.

Link copied to clipboard
open override val id: Long

The ID of this application command, this is a snowflake that contains the time at which the command was created.

Link copied to clipboard
abstract val isDefaultLocked: Boolean

Whether this application command is (initially) locked to administrators.

Link copied to clipboard
abstract val isGuildOnly: Boolean

Whether this application command is usable only in guilds (i.e., no DMs).

Link copied to clipboard

Discord's metadata about this application command.

Link copied to clipboard
abstract val name: String

The name of this command.

Link copied to clipboard
abstract val nsfw: Boolean

Whether this application commands is usable only in NSFW channels.

Link copied to clipboard

The parameters of this executable.

Link copied to clipboard

The parent of this command, null for top-level commands.

Link copied to clipboard
abstract val path: CommandPath

The complete path that leads to this command.

Link copied to clipboard
abstract val scope: CommandScope

The scope on which this application command is pushed on.

Link copied to clipboard
open override val timeModified: OffsetDateTime

The time at which this application command was created/modified, retrieved from the version.

Link copied to clipboard
abstract override val topLevelInstance: UserCommandInfo

Retrieves the top-level command owning this application command.

Link copied to clipboard

The permissions required for the caller to use this command.

Link copied to clipboard
open override val version: Long

The version of this application command, this is a snowflake that contains the time at which the command was created/updated.

Functions

Link copied to clipboard
@Nonnull
open fun getId(): String
Link copied to clipboard
open override fun getIdLong(): Long
Link copied to clipboard

Returns the option with the supplied declared name (i.e., name of the method parameter), or null if not found.

Link copied to clipboard
open override fun getParameter(declaredName: String): UserContextCommandParameter?

Returns the aggregated parameter with the supplied declared name (i.e., name of the method parameter), or null if not found.

Link copied to clipboard
@Nonnull
open fun getTimeCreated(): OffsetDateTime
Link copied to clipboard
abstract fun getUsability(inputUser: InputUser, channel: MessageChannel): Usability

Returns a Usability instance, representing whether this application command can be used.

Link copied to clipboard
abstract fun hasFilters(): Boolean

Return true if this has a one or more filters.

Link copied to clipboard
abstract fun hasRateLimiter(): Boolean

Return true if this has a rate limiter.

Link copied to clipboard

Retrieves the IntegrationPrivileges for this application command.