Layer 220
method Users Bots
bots.setBotInfo#10cf3123 flags:# bot:flags.2?InputUser lang_code:string name:flags.3?string about:flags.0?string description:flags.1?string = Bool;

Parameters

Name Type Description
Flags # Flags, see TL conditional fields
Bot flags.2?InputUser If called by a user, must contain the peer of a bot we own.
LangCode string Language code, if left empty update the fallback about text and description
Name flags.3?string New bot name
About flags.0?string New about text
Description flags.1?string New description

Returns

Bool

Possible Errors

Code Type Description
400 BOT_INVALID This is not a valid bot.
400 USER_BOT_INVALID User accounts must provide the bot method parameter when calling this method. If there is no such method parameter, this method can only be invoked by bot accounts.

Gogram Example

// BotsSetBotInfo - using Params struct
result, err := client.BotsSetBotInfo(&tg.BotsSetBotInfoParams{
    LangCode: "...",

    // Optional fields:
    // Bot: &tg.InputUserSelf{},
    // Name: "...",
    // About: "...",
    // Description: "...",
})
if err != nil {
    // handle error
}
// result is *tg.Bool