Quantcast
Channel: Active questions tagged youtube-api - Stack Overflow
Viewing all articles
Browse latest Browse all 3718

How to comment other comments on a YouTube via API correctly? [Part of comments are not visible]

$
0
0

I'm trying to write a bot that will respond to all comments under the video (1 nesting level).
all requests are made through googleapiclient
First of all, I receive last comments on channel (commentThreads => list):

request = self.client.commentThreads().list(allThreadsRelatedToChannelId=self.channel_id,                                            moderationStatus='published', order='time', part='snippet')

Then send comment to each comment in list (comments => insert):

request = self.client.comments().insert(part='snippet', body={"snippet": {"textOriginal": text,"parentId": comment_id,            }        })        response = request.execute()

Full code part here
The problem is that half of the submitted comments are not showing up
(the number of comments on comments differs even though the same number of requests were sent)

enter image description here

No errors occur, comments just don't show up
I've tried adding a delay between requests, but that doesn't help. Nothing is written in the documentation either.

What am I doing wrong? Do I need to enable any YouTube channel settings?

Video: https://youtu.be/CXtUZtjw5Mc


Viewing all articles
Browse latest Browse all 3718

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>