Skip to main content

bots.reorderUsernames

Reorder usernames associated to a bot we own.

func (c *Client) BotsReorderUsernames(ctx context.Context, request *BotsReorderUsernamesRequest) (bool, error)

Calling this method

client.Run(ctx, func(ctx context.Context) error {
api := client.API()

res, err := api.BotsReorderUsernames(ctx, &tg.BotsReorderUsernamesRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // bool
return nil
})

Parameters

NameTypeRequiredDescription
BotInputUserClassyesThe bot
Order[]stringyesThe new order for active usernames. All active usernames must be specified.

Returns

bool

Possible errors

CodeTypeDescription
400BOT_INVALIDThis is not a valid bot.
400USERNAME_NOT_MODIFIEDThe username was not modified.

References