API ReferencePosts
POST /posts/{postId}/reactions
Reagir ao post
POST
/posts/{postId}/reactionsAuth: accessTokenUPSERT reaction (1 por user/post). Trocar tipo é UPDATE. Dispara notif post_reaction ao dono do post.
Request
| Campo | Tipo | Requerido | Descrição |
|---|---|---|---|
| type | "power_up" | "epic" | "critical" | "loot" | "gg" | sim |
Response
200
Sem corpo na resposta.
Erros
Sem respostas de erro documentadas.
Exemplos
curl -X POST 'http://localhost:3003/posts/{postId}/reactions' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer SEU_ACCESS_TOKEN' \
-d '{}'await fetch('http://localhost:3003/posts/{postId}/reactions', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
Authorization: 'Bearer ' + accessToken,
},
body: JSON.stringify({}),
})