Answer the question
In order to leave comments, you need to log in
How do I receive new comments in group discussions?
I want to subscribe to new comments in group discussions under any entities (media_topic, photos, etc)
According to the bot_api documentation, you can only subscribe to private messages (which is also necessary), unfortunately I did not find a method for updating the group.
I tried to get statistics using group.getStatTopics so that later, when updating, I can pull a specific discussion, but the statistics are updated with a long delay
. Actually, the question is, are there any other methods for quickly receiving comments or subscribing to events in a group?
Answer the question
In order to leave comments, you need to log in
Unfortunately, it is impossible to receive new comments on the discussion similarly to private messages (through a subscription).
You can try to use the https://apiok.ru/dev/methods/rest/discussions/disc... method with the following parameters:
- discussionId - id of your topic in the group
- discussionType - GROUP_TOPIC
- fields - comment.* to get all fields comments /comment.date to get the time when a comment was posted
Comments in a response are sorted in descending order of post time, so you can look at the date of the very first comment in a response, e.g.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question