Перейти к основному содержимому

POST /api/v1/comments/{id}/like

Adds a "like" reaction to a comment. If the user has already disliked the comment, the dislike is replaced with a like.

Authentication

Required. Bearer token in Authorization header.

Request

Path Parameters

ParameterTypeRequiredDescription
idintegerYesComment ID

Example

curl -X POST https://intotes.com/api/v1/comments/1/like \
-H "Authorization: Bearer <access_token>"

Response

200 OK

{
"message": "comment liked successfully"
}

Errors

StatusCodeDescription
401unauthorizedMissing or invalid authentication token
404not_foundComment not found
500internal_errorServer failed to add reaction