photos.uploadContactProfilePhoto
Upload a custom profile picture for a contact, or suggest a new profile picture to a contact.
| الاسم | النوع | مطلوب | الوصف |
|---|---|---|---|
suggest | true | لأ | If set, will send a [messageActionSuggestProfilePhoto](https://core.telegram.org/constructor/messageActionSuggestProfilePhoto.md) service message to `user_id`, suggesting them to use the specified profile picture; otherwise, will set a personal profile picture for the user (only visible to the current user). |
save | true | لأ | If set, removes a previously set personal profile picture (does not affect suggested profile pictures, to remove them simply delete the [messageActionSuggestProfilePhoto](https://core.telegram.org/constructor/messageActionSuggestProfilePhoto.md) service message with [messages.deleteMessages](https://core.telegram.org/method/messages.deleteMessages.md)). |
user_id | InputUser | أيوه | The contact |
file | InputFile | لأ | Profile photo |
video | InputFile | لأ | [Animated profile picture](https://core.telegram.org/api/files.md#animated-profile-pictures) video |
video_start_ts | double | لأ | النقطة العائمة UNIX الطابع الزمني بالثواني، تشير إلى إطار الفيديو/الملصق الذي يجب استخدامه كمعاينة ثابتة؛ لا يمكن استخدامه إلا إذا تم ضبط `video` أو `video_emoji_markup`. |
video_emoji_markup | VideoSize | لأ | يجب أن تحتوي الصورة الشخصية للملصقات المتحركة على مُنشئ [videoSizeEmojiMarkup](https://core.telegram.org/constructor/videoSizeEmojiMarkup.md) أو مُنشئ [videoSizeStickerMarkup](https://core.telegram.org/constructor/videoSizeStickerMarkup.md). |
الردود
photos.Photo
MTProto RPC
- 400 · CONTACT_MISSING — The specified user is not a contact.
- 400 · NEED_ACTION_MISSING — The caller didn't specify a valid action (either save or suggest) for the contact profile photo upload.
- 400 · USER_ID_INVALID — The provided user ID is invalid.