respond abstract method Null safety

  1. @override
Future<IMessage> respond(
  1. MessageBuilder builder,
  2. {bool private = false,
  3. bool? hidden}
)
override

Send a response to the command.

If private is set to true, then the response will only be made visible to the user that invoked the command. In interactions, this is done by sending an ephemeral response, in text commands this is handled by sending a Private Message to the user.

If hidden is set to true, the response will be ephemeral (hidden). However, unlike hidden, not setting hidden will result in the value from CommandOptions.hideOriginalResponse being used instead. hidden will override private.

You might also be interested in:

  • acknowledge, for acknowledging interactions without resopnding.

Implementation

@override
Future<IMessage> respond(MessageBuilder builder, {bool private = false, bool? hidden});