# 获取 403 错误：用户无法取消点赞帖子

**URL:** <https://meta.discourse.org/t/getting-403-for-unlike-a-post-by-the-user/120763>\
**Category:** Development\
**Created:** [2019 年6 月 19 日 06:25 UTC](https://meta.discourse.org/t/getting-403-for-unlike-a-post-by-the-user/120763 "2019-06-19T06:25:30Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

作者： ![Vishal\_Kaushik](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vishal_kaushik/32/140452_2.png) [@Vishal\_Kaushik](https://meta.discourse.org/u/Vishal_Kaushik)\
发布日期： [2019 年6 月 19 日 06:25 UTC](https://meta.discourse.org/t/getting-403-for-unlike-a-post-by-the-user/120763/1 "2019-06-19T06:25:30Z")

</div>

I am trying to hit the unlike API on discourse with HTTP, Node.js. I am sending the particular payload :

```
      host: discourseHost,
      port: discoursePort,
      path: '/post_actions/' + parseInt(req.params.post_id),
      method: 'DELETE',
      headers: {
        'Content-Type': 'application/json',
        'Content-Length': Buffer.byteLength(data),
        'Api-Key': DISCOURSE_API_KEY,
        'Api-Username': userData.discourse_username,
        'Accept': 'application/json'
      }

```

But I am getting this as response :

STATUS: 403  
BODY: {“errors”:[“You are not permitted to view the requested resource.”]}

Can anyone suggest me what I need to change in my payload/request.

---

_[View the full topic](https://meta.discourse.org/t/getting-403-for-unlike-a-post-by-the-user/120763)._
