React to a post
const url = 'https://api.gampeon.com/v1/posts/1/reaction';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"reaction":"like"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://api.gampeon.com/v1/posts/1/reaction \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "reaction": "like" }'One reaction per person; a new one replaces the old one. No notification is sent for reactions.
Not available with access tokens.
Rate limit: 300 per hour per account (together with likes).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Post ID
Request Bodyrequired
Section titled “Request Bodyrequired”object
Responses
Section titled “Responses”Saved
object
object
All reactions together
Up to three most frequent reactions, most frequent first (for the icons)
Number per reaction, only reactions that occur
object
Older field: any reaction
Older field: all reactions
Example
{ "reaction": "like", "reactions": { "top": [ "like" ] }}Error codes: invalid_field
object
Machine-readable error code, for example not_found or rate_limited.
Human-readable detail. Only present for some errors.
Example generated
{ "error": "example", "message": "example"}Error codes: unauthorized
object
Machine-readable error code, for example not_found or rate_limited.
Human-readable detail. Only present for some errors.
Example generated
{ "error": "example", "message": "example"}Error codes: token_not_allowed
object
Machine-readable error code, for example not_found or rate_limited.
Human-readable detail. Only present for some errors.
Example generated
{ "error": "example", "message": "example"}Error codes: not_found
object
Machine-readable error code, for example not_found or rate_limited.
Human-readable detail. Only present for some errors.
Example generated
{ "error": "example", "message": "example"}Limit: 300 per hour per account (together with likes). Error codes: rate_limited
object
Machine-readable error code, for example not_found or rate_limited.
Human-readable detail. Only present for some errors.
Example generated
{ "error": "example", "message": "example"}