Reactions
The Reactions API enables you to create, list and delete reactions.
React to post
Add reaction to a post on behalf of the authenticated user.
POST /api/posts/{id}/reactions
Path parameters
idintegerrequiredPost id.
Body parameters
contentstringrequiredA single emoji character describing the reaction, e.g. '
👍' or '❤️'.
Example request
curl {WEAVY-URL}/api/posts/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
--json "{ 'content': '😍' }"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
422 Validation Failed
React to comment
Add reaction to a comment on behalf of the authenticated user.
POST /api/comments/{id}/reactions
Path parameters
idintegerrequiredComment id.
Body parameters
contentstringrequiredA single emoji character describing the reaction, e.g. '
👍' or '❤️'.
Example request
curl {WEAVY-URL}/api/comments/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
--json "{ 'content': '😍' }"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
422 Validation Failed
React to message
Add reaction to a message on behalf of the authenticated user.
POST /api/messages/{id}/reactions
Path parameters
idintegerrequiredMessage id.
Body parameters
contentstringrequiredA single emoji character describing the reaction, e.g. '
👍' or '❤️'.
Example request
curl {WEAVY-URL}/api/messages/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
--json "{ 'content': '😍' }"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
422 Validation Failed
List post reactions
List reactions for a post.
GET /api/posts/{id}/reactions
Path parameters
idintegerrequiredPost id.
Query parameters
contentstringLists reactions with the specified emoji character. Omit this parameter to list all reactions.
qstringA string used to find matching items by name, e.g.
q=test.
tagstringList items with the specified tag.
trashedbooleanIndicates whether trashed items should be listed (default is
false). Specifynullto list both trashed and non-trashed items.
order_bystringSpecifies the sort order and direction for the listing, e.g.
order_by=idororder_by=id+desc.
skipintegerThe number of items to skip. Used together with
taketo return a specific range of items (for pagination).
takeintegerMaximum number of items to return in the listing. Should be a value between
1and100. Default is25.
count_onlybooleantrueto count the number of matching items instead of listing them; when specified the response will only contain thecountproperty.
Example request
curl {WEAVY-URL}/api/posts/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN | API-KEY}"
Response codes
200 OK
401 Unauthorized
404 Not Found
Response schema
{
"data": [
{
"content": "string",
"created_at": "string"
}
],
"start": "integer",
"end": "integer",
"count": "integer"
}
List comment reactions
List reactions for a comment.
GET /api/comments/{id}/reactions
Path parameters
idintegerrequiredComment id.
Query parameters
contentstringLists reactions with the specified emoji character. Omit this parameter to list all reactions.
qstringA string used to find matching items by name, e.g.
q=test.
tagstringList items with the specified tag.
trashedbooleanIndicates whether trashed items should be listed (default is
false). Specifynullto list both trashed and non-trashed items.
order_bystringSpecifies the sort order and direction for the listing, e.g.
order_by=idororder_by=id+desc.
skipintegerThe number of items to skip. Used together with
taketo return a specific range of items (for pagination).
takeintegerMaximum number of items to return in the listing. Should be a value between
1and100. Default is25.
count_onlybooleantrueto count the number of matching items instead of listing them; when specified the response will only contain thecountproperty.
Example request
curl {WEAVY-URL}/api/comments/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN | API-KEY}"
Response codes
200 OK
401 Unauthorized
404 Not Found
Response schema
{
"data": [
{
"content": "string",
"created_at": "string"
}
],
"start": "integer",
"end": "integer",
"count": "integer"
}
List message reactions
List reactions for a message.
GET /api/messages/{id}/reactions
Path parameters
idintegerrequiredMessage id.
Query parameters
contentstringLists reactions with the specified emoji character. Omit this parameter to list all reactions.
qstringA string used to find matching items by name, e.g.
q=test.
tagstringList items with the specified tag.
trashedbooleanIndicates whether trashed items should be listed (default is
false). Specifynullto list both trashed and non-trashed items.
order_bystringSpecifies the sort order and direction for the listing, e.g.
order_by=idororder_by=id+desc.
skipintegerThe number of items to skip. Used together with
taketo return a specific range of items (for pagination).
takeintegerMaximum number of items to return in the listing. Should be a value between
1and100. Default is25.
count_onlybooleantrueto count the number of matching items instead of listing them; when specified the response will only contain thecountproperty.
Example request
curl {WEAVY-URL}/api/messages/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN | API-KEY}"
Response codes
200 OK
401 Unauthorized
404 Not Found
Response schema
{
"data": [
{
"content": "string",
"created_at": "string"
}
],
"start": "integer",
"end": "integer",
"count": "integer"
}
Unreact to post
Delete authenticated user's reaction to a post.
DELETE /api/posts/{id}/reactions
Path parameters
idintegerrequiredPost id.
Example request
curl -X DELETE {WEAVY-URL}/api/posts/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
Unreact to comment
Delete authenticated user's reaction to a comment.
DELETE /api/comments/{id}/reactions
Path parameters
idintegerrequiredComment id.
Example request
curl -X DELETE {WEAVY-URL}/api/comments/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found
Unreact to message
Delete authenticated user's reaction to a message.
DELETE /api/messages/{id}/reactions
Path parameters
idintegerrequiredMessage id.
Example request
curl -X DELETE {WEAVY-URL}/api/messages/1/reactions
-H "Authorization: Bearer {ACCESS-TOKEN}"
Response codes
204 No Content
400 Bad Request
401 Unauthorized
403 Forbidden
404 Not Found