I have already successfully retrieved messages from channels.
I do that with the iter_messages function
However, the message object does not contain the comments, only the users wrote the comments.
In the object is a channel_id, this seems to be the linked group. But the group doesn’t have a URL like t.me/xxx. Does anyone have an approach for a solution?
Here is an excerpt from the object as JSON.
"replies": {
"_": "MessageReplies",
"replies": 8,
"replies_pts": 17846,
"comments": true,
"recent_repliers": [
{
"_": "PeerUser",
"user_id": 57135752
},
{
"_": "PeerUser",
"user_id": 564589817
},
{
"_": "PeerUser",
"user_id": 888542547
}
],
"channel_id": 1484030956,
"max_id": 13402,
"read_max_id": null
},
2
Answers
Finally i found a solution which is working fine. When you have the specific message id you can set the flag reply_to. Then you get the comments of the channel posts.
If you had joined to this group manually, It can work.
But better way is to get full channel request, so you can get a channel itself and chat as an entities (and maybe join it?), then find if any of them are replies to channel post.
This code is untested, but I am working on it o_0