ToggleBotUsernameIsActive class final
ToggleBotUsernameIsActive (toggleBotUsernameIsActive) - TDLib function
Changes active state for a username of a bot. The editable username can't be disabled. May return an error with a message "USERNAMES_ACTIVE_TOO_MUCH" if the maximum number of active usernames has been reached. Can be called only if userTypeBot.can_be_edited == true.
- botUserId: Identifier of the target bot.
- username: The username to change.
- isActive: Pass true to activate the username; pass false to disable it.
Ok is returned on completion.
- Inheritance
-
- Object
- TdFunction
- ToggleBotUsernameIsActive
Constructors
- ToggleBotUsernameIsActive({required int botUserId, required String username, required bool isActive})
-
ToggleBotUsernameIsActive (toggleBotUsernameIsActive) - TDLib function
const
Properties
- botUserId → int
-
Identifier of the target bot
final
- currentObjectId → String
-
TDLib object type for current class instance
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- isActive → bool
-
Pass true to activate the username; pass false to disable it
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- username → String
-
The username to change
final
Methods
-
copyWith(
{int? botUserId, String? username, bool? isActive}) → ToggleBotUsernameIsActive - Copy model with modified properties.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
[dynamic extra]) → Map< String, dynamic> -
Convert model to TDLib JSON format
override
-
toString(
) → String -
Convert model to TDLib JSON format, encoded into String.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Constants
- defaultObjectId → const String
- TDLib object type