Files
YouTube.js/examples/comments/README.md
2022-08-03 17:10:56 -03:00

1.2 KiB

Comments

YouTube.js has full support for comments, including comment actions such as liking, disliking, replying etc.

Usage

Get a Comments instance:

const comments = await session.getComments(VIDEO_ID);

API

contents

A list of comment threads. Note: More about comment threads here.

Type: CommentThread[]

createComment(text)

Creates a top-level comment.

Param Type Description
text string Comment content

Returns: Promise<ActionsResponse>

getContinuation()

Retrieves next batch of comment threads.

Returns: Promise.<Comments>

page

Returns original InnerTube response (sanitized).

Returns: ParsedResponse

Example

See index.ts.