OAuthComments
Class: OAuthComments
Defined in: oauth/comments.ts:11
Constructors
Constructor
new OAuthComments(
oauth,request):OAuthComments
Defined in: oauth/comments.ts:14
Parameters
oauth
request
Request
Returns
OAuthComments
Properties
oauth
oauth:
OAuth
Defined in: oauth/comments.ts:14
Methods
deleteComment()
deleteComment(
commentId):Promise<void>
Defined in: oauth/comments.ts:131
Deletes a Comment.
Parameters
commentId
string
The ID of the comment to delete.
Returns
Promise<void>
editComment()
editComment(
commentId,text):Promise<Comment>
Defined in: oauth/comments.ts:70
Edit a Comment on a Video or Channel discussion.
Parameters
commentId
string
The ID of the comment.
text
string
The new text content of the comment.
Returns
Promise<Comment>
markCommentAsSpam()
markCommentAsSpam(
commentId):Promise<void>
Defined in: oauth/comments.ts:91
Marks a Comment as spam.
Parameters
commentId
string
The ID of the comment to mark as spam.
Returns
Promise<void>
postComment()
postComment(
text,channelResolvable,videoResolvable):Promise<Comment>
Defined in: oauth/comments.ts:25
Post a Comment on a Video or Channel discussion.
Parameters
text
string
The text content of the comment.
channelResolvable
The channel to post the comment on.
videoResolvable
The video of the channel to post the comment on. If falsey, the comment will be posted to the channel discussion.
Returns
Promise<Comment>
replyToComment()
replyToComment(
commentId,text):Promise<Comment>
Defined in: oauth/comments.ts:51
Replies to a Comment.
Parameters
commentId
string
The ID of the comment to reply to.
text
string
The text to reply with. Required for Comment.url to be correct.
Returns
Promise<Comment>
setCommentModerationStatus()
setCommentModerationStatus(
commentId,moderationStatus,banAuthor?):Promise<void>
Defined in: oauth/comments.ts:105
Sets the moderation status of a Comment
Parameters
commentId
string
The ID of the comment to set the moderation status of.
moderationStatus
"heldForReview" | "published" | "rejected"
The moderation status to set the comment to.
banAuthor?
boolean
Whether or not to ban the author from making future comments.
Returns
Promise<void>