photos.uploadProfilePhoto

Updates current user profile photo.

photos.photo#20212ca8 photo:Photo users:Vector<User> = photos.Photo;
---functions---
photos.uploadProfilePhoto#93c9a51 flags:# fallback:flags.3?true file:flags.0?InputFile video:flags.1?InputFile video_start_ts:flags.2?double video_emoji_markup:flags.4?VideoSize = photos.Photo;

Parameters

Name Type Description
flags # Flags, see TL conditional fields
fallback flags.3?true  
file flags.0?InputFile Profile photo
video flags.1?InputFile Animated profile picture video
video_start_ts flags.2?double Floating point UNIX timestamp in seconds, indicating the frame of the video that should be used as static preview.
video_emoji_markup flags.4?VideoSize  

Result

photos.Photo

Possible errors

Code Type Description
400 ALBUM_PHOTOS_TOO_MANY You have uploaded too many profile photos, delete some before retrying.
400 FILE_PARTS_INVALID The number of file parts is invalid.
400 IMAGE_PROCESS_FAILED Failure while processing image.
400 PHOTO_CROP_FILE_MISSING Photo crop file missing.
400 PHOTO_CROP_SIZE_SMALL Photo is too small.
400 PHOTO_EXT_INVALID The extension of the photo is invalid.
400 PHOTO_FILE_MISSING Profile photo file missing.
400 PHOTO_INVALID Photo invalid.
400 STICKER_MIME_INVALID The specified sticker MIME type is invalid.
400 VIDEO_FILE_INVALID The specified video file is invalid.

Related pages

Uploading and Downloading Files

How to transfer large data batches correctly.