Yurba.js / @yurbajs/types / CommandDefinition
Interface: CommandDefinition
Represents the definition of a command.
Example
ts
{
* name: "greet",
* description: "Send a greeting",
* options: [
* { name: "user", type: "user", required: true, description: "User to greet" }
* ],
* handler: async (message, args) => {
* // Implementation here
* }
* }Properties
description
description:
string
handler()
handler: (
message,args) =>Promise<void>
Parameters
message
args
any
Returns
Promise<void>
name
name:
string
options
options:
CommandOption[]