Video Comments

Reply to a thread of a video

POST
https://peertube2.cpy.re/api/v1/videos/{id}/comments/{commentId}

Body

application/json
texttext<markdown>required
Show child attributes

Text of the comment

text<html>
Example
This video is wonderful!

Parameters

idid | UUIDv4 | shortUUIDrequiredpath

The object id, uuid or short uuid

commentIdid>= 1requiredpath

The comment id

x-peertube-video-passwordstringheader

Required on password protected video

Response

successful operation

Response fields application/json
Show child attributes
idid>= 1
Example
42
urlurl<url>
texttext<html>

Text of the comment

Example
This video is wonderful!
threadIdid>= 1
Example
42
inReplyToCommentIdid | null
Show child attributes
id>= 1
Example
42
videoIdid

object id for the video

Show child attributes
id>= 1
Example
42
createdAtcreatedAt<date-time>
updatedAtupdatedAt<date-time>
deletedAtstring<date-time> | nullnull
isDeletedbooleanfalse
heldForReviewheldForReview
totalRepliesFromVideoAuthorinteger>= 0
totalRepliesinteger>= 0
Show child attributes
idid>= 1
Example
42

Same fields as comment.videoId

urlstring<url>
nameusername

immutable name of the actor, used to find or mention it

Show child attributes

immutable name of the user, used to find or mention its actor

username
Example
chocobozzz
Show child attributes
pathstring | nulldeprecated

Deprecated in PeerTube v8.0, use fileUrl instead. Null if the file is stored in object storage: use the non-deprecated field instead.

fileUrlstring

PeerTube >= 7.1

widthinteger
heightinteger

PeerTube >= 7.3

createdAtstring<date-time>
updatedAtstring<date-time>
hoststring<hostname>

server on which the actor is resident

hostRedundancyAllowedboolean | null

whether this actor's host allows redundancy of its videos

followingCountinteger>= 0

number of actors subscribed to by this actor, as seen by this instance

followersCountinteger>= 0

number of followers of this actor, as seen by this instance

createdAtstring<date-time>
updatedAtstring<date-time>
userIdid | null

object id for the user tied to this account

Show child attributes
id>= 1
Example
42
displayNamestring

editable name of the account, displayed in its representations

descriptionstring | null

text or bio displayed on the account's profile

404Not Found

thread or video does not exist

Authorization

OAuth2oauth2

Authenticating via OAuth requires the following steps:

  • Have an activated account
  • Generate an access token for that account at /api/v1/users/token.
  • Make requests with the Authorization: Bearer <token> header
  • Profit, depending on the role assigned to the account

Note that the access token is valid for 1 day and is given along with a refresh token valid for 2 weeks.