SetStickerSetThumbRequest

Only bots can use this method. See code examples.

---functions---
stickers.setStickerSetThumb#9a364e30 stickerset:InputStickerSet thumb:InputDocument = messages.StickerSet

Returns

messages.StickerSet

This type can be an instance of either:

StickerSetStickerSetNotModified

Parameters

stickersetInputStickerSet
thumbInputDocument

Known RPC errors

This request can cause 2 known errors:

StickerThumbPngNopngErrorStickerset thumb must be a png file but the used file was not png.
StickerThumbTgsNotgsErrorStickerset thumb must be a tgs file but the used file was not tgs.

You can import these from telethon.errors.

Example

from telethon.sync import TelegramClient
from telethon import functions, types

with TelegramClient(name, api_id, api_hash) as client:
    result = client(functions.stickers.SetStickerSetThumbRequest(
        stickerset=types.InputStickerSetID(
            id=-12398745604826,
            access_hash=-12398745604826
        ),
        thumb=types.InputDocument(
            id=-12398745604826,
            access_hash=-12398745604826,
            file_reference=b'arbitrary\x7f data \xfa here'
        )
    ))
    print(result.stringify())