autocompleteCallback property

  1. @override
(FutureOr<Iterable<CommandOptionChoiceBuilder>?> Function(AutocompleteContext)?) autocompleteCallback
override

A function called to provide autocompletion for arguments of this type.

This function should return an iterable of options the user can select from, or null to indicate failure. In the event of a failure, the user will see a "options failed to load" message in their client.

This function should return at most 25 results and should not throw.

Implementation

@override
FutureOr<Iterable<CommandOptionChoiceBuilder<dynamic>>?> Function(AutocompleteContext)?
    get autocompleteCallback => _autocompleteCallback ?? converter.autocompleteCallback;