# Update User Role via PATCH API - Is it possible?

**URL:** <https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818>\
**Category:** API and Webhooks\
**Created:** [May 13, 2024, 1:04pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818 "2024-05-13T13:04:30Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![karon.ford](https://avatars.discourse-cdn.com/v4/letter/k/9de0a6/32.png) [@karon.ford](https://devforum.zoom.us/u/karon.ford)\
**Post date:** [May 13, 2024, 1:04pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/1 "2024-05-13T13:04:30Z")

</div>

hello, we are trying to update use role via API using the PATCH /users/{userId} – the call is returning a successful 204. However, when I check the user, they aren’t in the updated role. The body I am passing for the updated role is {“role\_name”:“Member”}

---

<div class="post-metadata">

**Author:** ![philip.ross](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/philip.ross/32/19627_2.png) [@philip.ross](https://devforum.zoom.us/u/philip.ross)\
**Post date:** [May 13, 2024, 1:08pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/2 "2024-05-13T13:08:02Z")

</div>

You can do this with the API, but looks like your body might be malformed, and it’s a POST call, rather than a PATCH.

Here’s the documentation specifically to this use case:

> **[Zoom Account API](https://developers.zoom.us/docs/api/rest/reference/account/methods/#operation/AddRoleMembers)**
>
> API Reference for /docs/api/rest/reference/account/methods

I’ve had success doing this - the roleID is included in the URI, rather than in the Body

---

<div class="post-metadata">

**Author:** ![karon.ford](https://avatars.discourse-cdn.com/v4/letter/k/9de0a6/32.png) [@karon.ford](https://devforum.zoom.us/u/karon.ford)\
**Post date:** [May 13, 2024, 2:51pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/3 "2024-05-13T14:51:29Z")

</div>

Hi @philip.ross I tried the post you recommended with this body

{  
“members”: “[{“email”:”$user\_email",“id”:“$user\_id”}]"  
}

and I am receiving INVALID\_INPUT 400 bad request error. Thoughts?

---

<div class="post-metadata">

**Author:** ![karon.ford](https://avatars.discourse-cdn.com/v4/letter/k/9de0a6/32.png) [@karon.ford](https://devforum.zoom.us/u/karon.ford)\
**Post date:** [May 13, 2024, 2:54pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/4 "2024-05-13T14:54:25Z")

</div>

@philip.ross I fixed it but have another error.

},  
“body”: {  
“code”: 4711,  
“message”: “Invalid access token, does not contain scopes:[role:write:admin].”  
},

I assume the account I am making the API call from doesn’t have permission to change an admin’s role? If this is the case, what would I need to do to grant that access?

---

<div class="post-metadata">

**Author:** ![philip.ross](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/philip.ross/32/19627_2.png) [@philip.ross](https://devforum.zoom.us/u/philip.ross)\
**Post date:** [May 13, 2024, 3:35pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/5 "2024-05-13T15:35:36Z")

</div>

Nice work!

That error suggests to me that the OAuth app that you’re using doesn’t have the permission granted that’s required to make that call successfully.

This is done within your OAuth app directly.  
More specific info here on the scopes:

> **[Integrations - Classic scopes](https://developers.zoom.us/docs/integrations/oauth-scopes/#rolewriteadmin)**
>
> The Zoom Developer Platform is an open platform that allows third-party developers to build applications and integrations upon Zoom’s video-first unified communications platform.

To amend the app, go to [marketplace.zoom.us/](http://marketplace.zoom.us/) Sign in, and then to go Manage (top right) and select the OAuth app that you created to facilitate your API calls.  
Select it and under scopes, ensure that it’s got the relevant permissions for Role changes:

 ![image](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/2/c/2cd2467950202c18275dcffd54037f3e4ab8da80.png)

---

<div class="post-metadata">

**Author:** ![karon.ford](https://avatars.discourse-cdn.com/v4/letter/k/9de0a6/32.png) [@karon.ford](https://devforum.zoom.us/u/karon.ford)\
**Post date:** [May 13, 2024, 4:54pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/6 "2024-05-13T16:54:25Z")

</div>

Thanks @phillip.wright is there a reason why I don’t see role in the “add scopes” sections? I am an admin with OAuth permissions.

---

<div class="post-metadata">

**Author:** ![philip.ross](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/philip.ross/32/19627_2.png) [@philip.ross](https://devforum.zoom.us/u/philip.ross)\
**Post date:** [May 14, 2024, 7:33am UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/7 "2024-05-14T07:33:46Z")

</div>

Perhaps you’ve created your app since the transition to Granular scopes was made.

Try this doc:

> **[Integrations - Granular scopes](https://developers.zoom.us/docs/integrations/oauth-scopes-granular/#roles)**
>
> The Zoom Developer Platform is an open platform that allows third-party developers to build applications and integrations upon Zoom’s video-first unified communications platform.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/6/1/614bdd549b610bbaa46ff934617683a02bdaa03c.png) [@system](https://devforum.zoom.us/u/system)\
**Post date:** [May 17, 2025, 11:09pm UTC](https://devforum.zoom.us/t/update-user-role-via-patch-api-is-it-possible/109818/8 "2025-05-17T23:09:48Z")

</div>

Closed on May 17, 2025, 11:09pm UTC

This topic was automatically closed 368 days after the last reply. New replies are no longer allowed.
