# Issue on API membership POST request

**URL:** <https://community.ofelia.com/t/issue-on-api-membership-post-request/11610>\
**Category:** Q&A\
**Tags:** extensions\
**Created:** [29 August 2023 05:06 UTC](https://community.ofelia.com/t/issue-on-api-membership-post-request/11610 "2023-08-29T05:06:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![chris\_dev](https://avatars.discourse-cdn.com/v4/letter/c/aca169/32.png) [@chris\_dev](https://community.ofelia.com/u/chris_dev)\
**Post date:** [29 August 2023 05:06 UTC](https://community.ofelia.com/t/issue-on-api-membership-post-request/11610/1 "2023-08-29T05:06:34Z")

</div>

I created an account "sysad" and map this&nbsp;account under administrator profile.  
I logged in then try to add a new user to a new membership group/role and it was successful.

But when i used and log "sysad" via api and then perform post request for identity/membership for a particular user, i received an error 401 error. But when i use "install" account, it was successful.  
  
Is this a bug issue?

---

<div class="post-metadata">

**Author:** ![thalia.cruz](https://dub1.discourse-cdn.com/flex013/user_avatar/community.ofelia.com/thalia.cruz/32/1230_2.png) [@thalia.cruz](https://community.ofelia.com/u/thalia.cruz)\
**Post date:** [14 September 2023 09:53 UTC](https://community.ofelia.com/t/issue-on-api-membership-post-request/11610/2 "2023-09-14T09:53:05Z")

</div>

Hi chris\_dev,

Just a question: are you passing the `X-Bonita-API-Token` as a HTTP header? It is required for a POST and if not it might be the reason of the 401:&nbsp;https://api-documentation.bonitasoft.com/latest/#tag/PortalAuthentication/operation/login

hope this helps,

Thalia

&nbsp;
