Class SetMyCommands


public class SetMyCommands extends AbstractBaseRequest<SetMyCommands,Boolean>
SetMyCommands class. Returns True on success.
Since:
3 March 2025
See Also:
  • Constructor Details

    • SetMyCommands

      public SetMyCommands(BotCommand[] commands, Api api)
      Required
      Parameters:
      commands - commands
      api - api
  • Method Details

    • scope

      public SetMyCommands scope(BotCommandScope scope)
      Optional
      Parameters:
      scope - A JSON-serialized object, describing scope of users for which the commands are relevant. Defaults to BotCommandScopeDefault
      Returns:
      SetMyCommands
    • languageCode

      public SetMyCommands languageCode(String languageCode)
      Optional
      Parameters:
      languageCode - A two-letter ISO 639-1 language code. If empty, commands will be applied to all users from the given scope, for whose language there are no dedicated commands
      Returns:
      SetMyCommands