Get Comments
Returns all comments and replies for a specific video, including like counts and the current user’s like status.Parameters
The video ID to fetch comments for
Request
Response
Array of top-level comment objects (limit: 100 newest comments)
Total number of comments and replies returned
Example Response
Notes
Comments are sorted by creation date (newest first). Only the 100 most recent top-level comments are returned, but all replies are included.
Create Comment
Create a new comment or reply on a video. Requires reCAPTCHA verification.Parameters
The video ID to comment on
Headers
reCAPTCHA token for verification (skipped in local dev without
RECAPTCHA_SECRET_KEY)Body
Comment text contentValidation:
- Must not be empty or whitespace-only
- Maximum 300 characters
- Trimmed before storage
Parent comment UUID (for replies). Omit for top-level comments.
Request
Response (201 Created)
New comment UUID
Comment text (trimmed)
ISO 8601 timestamp
Author information
Initial like count (always 0)
Initial user like status (always null)
Initial replies array (always empty)
Example Response
Rate Limiting
Error Responses
Validation failed:
{"error": "Content is required"}- Empty or whitespace-only content{"error": "Comment must be 300 characters or less"}- Content too long
reCAPTCHA verification failed:
{"error": "Invalid request"}- Missing token{"error": "reCAPTCHA verification failed"}- Token invalid or score < 0.5
Rate limit exceeded:
{"error": "You have left too many comments already"}- 10 comments in 24h
Like Comment
Like or unlike a comment. Requires reCAPTCHA verification. Liking a comment you’ve already liked will unlike it (toggle behavior).Parameters
The comment UUID to like/unlike
Headers
reCAPTCHA token for verification
Request
Response
New like status for this comment:
true- Comment was liked (created like)null- Comment was unliked (removed like)
Example Responses
Liking a comment:Behavior
Toggle Behavior:
- If user has not liked the comment → Creates like
- If user has already liked the comment → Removes like
Error Responses
reCAPTCHA verification failed:
{"error": "Invalid request"}- Missing token{"error": "reCAPTCHA verification failed"}- Token invalid or score < 0.5
Notes
The like count is calculated dynamically when fetching comments. This endpoint only returns the user’s new like status, not the total like count.