Ethan
Ethan

Reputation: 85

How can I get profile images from telegram messenger channels?

How can I get profile images from telegram messenger channels programmatically in java codes? I don't want change images manually in my app.

Upvotes: 2

Views: 1929

Answers (1)

Charles Okwuagwu
Charles Okwuagwu

Reputation: 10876

channel#a14dca52 flags:# creator:flags.0?true kicked:flags.1?true left:flags.2?true editor:flags.3?true moderator:flags.4?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true democracy:flags.10?true signatures:flags.11?true min:flags.12?true id:int access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int version:int restriction_reason:flags.9?string = Chat;

This is the field you are looking for under the channel object: photo:ChatPhoto

ChatPhoto is of the following types:

chatPhotoEmpty#37c1011c = ChatPhoto;
chatPhoto#6153276a photo_small:FileLocation photo_big:FileLocation = ChatPhoto;

fileLocationUnavailable#7c596b46 volume_id:long local_id:int secret:long = FileLocation;
fileLocation#53d69076 dc_id:int volume_id:long local_id:int secret:long = FileLocation;

Upvotes: 1

Related Questions