Infinite parameters for slash commands

Comments

1 comment

  • LightningPirate

    You may have already figured this out but each command or subcommand supports up to 10 arguments or parameters.

    So for example your cleanup command would be registered like this:

    {
    name: 'cleanup',
    description: 'deletes messages with a given string by a given user',
    options: [
    {
    name: 'user'
    description: 'the user whose messages will be deleted',
    type: 6,
    required: true
    },
    {
    name: 'text'
    description: 'messages with this text will be deleted',
    type: 3,
    required: true
    }
    ]
    }

    1

Please sign in to leave a comment.