telegram api method · layer 229 · #66a08c7e
account.updateConnectedBot
Connect a business bot » to the current account, or to change the current connection settings.
definition
account.updateConnectedBot#66a08c7e flags:# deleted:flags.1?true rights:flags.0?BusinessBotRights bot:InputUser recipients:InputBusinessBotRecipients = Updates;
parameters
| name | type | description |
|---|---|---|
flags | # | Flags, see TL conditional fields |
deleted | true | Whether to fully disconnect the bot from the current account. |
rights | BusinessBotRights | Business bot rights. |
bot | InputUser | The bot to connect or disconnect |
recipients | InputBusinessBotRecipients | Configuration for the business connection |
returns
errors (4)
| code | error | description |
|---|---|---|
| 400 | BOT_BUSINESS_MISSING | The specified bot is not a business bot (the user.bot_business flag is not set). |
| 400 | BUSINESS_CONNECTION_NOT_ALLOWED | This method was invoked over a business connection using invokeWithBusinessConnection, but either (1) we're a user, and users cannot invoke methods over a business connection; (2) we're a bot, but business mode was disabled in @botfather or (3); we're a bot, but this method cannot be invoked over a business connection. |
| 400 | BUSINESS_RECIPIENTS_EMPTY | You didn't set any flag in inputBusinessBotRecipients, thus the bot cannot work with *any* peer. |
| 401 | AUTH_KEY_UNREGISTERED | The specified authorization key is not registered in the system (for example, a PFS temporary key has expired). |
history
present in layers 176–229 · constructor id changed 2×
| id | layers |
|---|---|
| #9c2d527d | 176 |
| #43d8521d | 177–200 |
| #66a08c7e | 201–229 |