mirror of
https://github.com/eternnoir/pyTelegramBotAPI.git
synced 2023-08-10 21:12:57 +03:00
Added the parameter needs_repainting to the method createNewStickerSet to automatically change the color of emoji based on context (e.g., use text color in messages, accent color in statuses, etc.).
This commit is contained in:
@@ -1617,7 +1617,7 @@ async def upload_sticker_file(token, user_id, png_sticker):
|
||||
|
||||
async def create_new_sticker_set(
|
||||
token, user_id, name, title, emojis, png_sticker, tgs_sticker,
|
||||
mask_position=None, webm_sticker=None, sticker_type=None):
|
||||
mask_position=None, webm_sticker=None, sticker_type=None, needs_repainting=None):
|
||||
method_url = 'createNewStickerSet'
|
||||
payload = {'user_id': user_id, 'name': name, 'title': title, 'emojis': emojis}
|
||||
if png_sticker:
|
||||
@@ -1636,6 +1636,8 @@ async def create_new_sticker_set(
|
||||
payload['mask_position'] = mask_position.to_json()
|
||||
if sticker_type:
|
||||
payload['sticker_type'] = sticker_type
|
||||
if needs_repainting is not None:
|
||||
payload['needs_repainting'] = needs_repainting
|
||||
return await _process_request(token, method_url, params=payload, files=files, method='post')
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user