CreateBot class final
Creates a bot which will be managed by another bot. Returns the created bot. May return an error with a message "BOT_CREATE_LIMIT_EXCEEDED" if the user already owns the maximum allowed number of bots as per getOption("owned_bot_count_max"). An internal link "https://t.me/BotFather?start=deletebot" can be processed to handle the error Returns User
- Inheritance
-
- Object
- TdFunction
- CreateBot
- Available extensions
- Annotations
-
- @immutable
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- managerBotUserId → int
-
managerBotUserId Identifier of the bot that will manage the created bot
final
- name → String
-
name Name of the bot; 1-64 characters
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- username → String
-
username Username of the bot. The username must end with "bot". Use
checkBotUsername to find whether the name is suitable
final
- viaLink → bool
-
viaLink Pass true if the bot is created from an
internalLinkTypeRequestManagedBot link
final
Methods
-
copyWith(
{int? managerBotUserId, String? name, String? username, bool? viaLink}) → CreateBot -
Available on CreateBot, provided by the CreateBotExtensions extension
-
getConstructor(
) → String -
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
override
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Constants
- constructor → const String