# Zoom web sdk "rename" api usage

**URL:** <https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344>\
**Category:** Web\
**Created:** [May 22, 2019, 8:04am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344 "2019-05-22T08:04:13Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![suchita](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/suchita/32/925_2.png) [@suchita](https://devforum.zoom.us/u/suchita)\
**Post date:** [May 22, 2019, 8:04am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/1 "2019-05-22T08:04:13Z")

</div>

**Description**  
I am using sample-webapp shared by zoom for zoom sdk.  
I tried using rename API of zoom but it throws error and error code is 3003.  
But if I try to rename it on zoom SDK initialised UI interface it allows me.  
**Which version?**  
Knowing the version can help us to identify your issue faster.

**To Reproduce(If applicable)**  
Steps to reproduce the behavior:

1. Download the sample-webapp for zoom sdk “[https://github.com/zoom/sample-app-web](https://github.com/zoom/sample-app-web)”
2. run the app and try to rename participant from code it will throw exception.
3. Try to rename participant on zoom UI it will be successful.
4. ideally it should not allow from zoom UI also.

**Screenshots**  
If applicable, add screenshots to help explain your problem.

**Smartphone (please complete the following information):**

- Device: Desktop
- OS: MacOS
- Version 10.14.3

**Additional context**  
Add any other context about the problem here.

---

<div class="post-metadata">

**Author:** ![michael\_p.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_p.zoom/32/18105_2.png) [@michael\_p.zoom](https://devforum.zoom.us/u/michael_p.zoom)\
**Post date:** [May 22, 2019, 9:48pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/2 "2019-05-22T21:48:35Z")

</div>

Hi @suchita,

Just for clarification, you’re looking to change the participant name found here correct?

![35%20PM](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/1X/4fdf3ce9449d99ba9160b239cb8d8b6846a1965c.png)

Thanks

---

<div class="post-metadata">

**Author:** ![suchita](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/suchita/32/925_2.png) [@suchita](https://devforum.zoom.us/u/suchita)\
**Post date:** [May 23, 2019, 7:19am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/3 "2019-05-23T07:19:32Z")

</div>

Hi @michael_p.zoom,

No I am looking for change of name under participants name where on hover we have rename option

 ![51%20PM](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/1X/735147eef0504ece1d1ff7a1852d8a5de3aefa28.png)

Thanks

---

<div class="post-metadata">

**Author:** ![JackYang](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/jackyang/32/1135_2.png) [@JackYang](https://devforum.zoom.us/u/JackYang)\
**Post date:** [May 24, 2019, 2:58am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/4 "2019-05-24T02:58:01Z")

</div>

3003 is ERROR\_NOT\_HOST  
only host can use this api and change name,

---

<div class="post-metadata">

**Author:** ![suchita](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/suchita/32/925_2.png) [@suchita](https://devforum.zoom.us/u/suchita)\
**Post date:** [May 24, 2019, 11:33am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/5 "2019-05-24T11:33:45Z")

</div>

Hello @JackYang,

Yes I am getting that error, but i am using sample-webapp of zoom-sdk where user joins the meeting with role 0 then how am I able to rename the participants name on the UI instantiated using sample-webapp.

---

<div class="post-metadata">

**Author:** ![michael\_p.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/michael_p.zoom/32/18105_2.png) [@michael\_p.zoom](https://devforum.zoom.us/u/michael_p.zoom)\
**Post date:** [May 24, 2019, 3:59pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/6 "2019-05-24T15:59:44Z")

</div>

Hi @suchita,

If you’re the guest attendee using the WebSDK, then you’re allowed to change your name within the UI.

Thanks

---

<div class="post-metadata">

**Author:** ![suchita](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/suchita/32/925_2.png) [@suchita](https://devforum.zoom.us/u/suchita)\
**Post date:** [May 27, 2019, 4:00am UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/7 "2019-05-27T04:00:26Z")

</div>

Thanks @michael_p.zoom

---

<div class="post-metadata">

**Author:** ![daniel2](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/daniel2/32/8619_2.png) [@daniel2](https://devforum.zoom.us/u/daniel2)\
**Post date:** [September 26, 2020, 7:10pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/8 "2020-09-26T19:10:17Z")

</div>

I checked just now in version 1.8.0. Seems like you **actually can** rename yourself via the `ZoomMtg.rename()` function. **But it still throws** the error code 3003, [meaning `ERROR_NOT_HOST`](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/4).

So, it **does** actually rename the user (using the user’s own `userId` via `ZoomMtg.getCurrentUser()`), but since it throws (falsely?) the logic flow needs to have this in consideration.

Being able to rename **yourself** via the Web SDK is something **desirable** , so please keep allowing this.  
_But don’t throw error 3003 when renaming yourself, only when trying to rename a different user._

---

<div class="post-metadata">

**Author:** ![tommy](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/tommy/32/72769_2.png) [@tommy](https://devforum.zoom.us/u/tommy)\
**Post date:** [September 29, 2020, 5:26pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/9 "2020-09-29T17:26:33Z")

</div>

Hey @daniel2,

Do you have the “Allow participants to rename themselves” [setting](https://zoom.us/profile/setting) turned on?

 ![Screen Shot 2020-09-29 at 10.06.36 AM](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/3X/1/8/1824b51f697661839fc4797fe4b08004d1bcc301.png)

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![daniel2](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/daniel2/32/8619_2.png) [@daniel2](https://devforum.zoom.us/u/daniel2)\
**Post date:** [March 24, 2021, 8:36pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/10 "2021-03-24T20:36:52Z")

</div>

Yes, the meeting settings allow users to rename themselves.

But now in version 1.9.1 of the Web SDK, the `ZoomMtg.rename()` function only works like one time, and then it stops working.

It still throws the same error as before, that the user is not Host nor Co-Host.

I first get an error callback, but if it works I **also** get a success callback. So yes, I receive both an error and success callback at the same time…

I can’t figure out how this could be! The SDK has a working under-the-hood API to rename the user via the participants list UI. Why does the SDK not use the same internal API as the UI?

---

<div class="post-metadata">

**Author:** ![MaxM](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/maxm/32/42303_2.png) [@MaxM](https://devforum.zoom.us/u/MaxM)\
**Post date:** [March 25, 2021, 6:37pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/11 "2021-03-25T18:37:36Z")

</div>

Hey @daniel2,

Thank you for reaching out to the Zoom Developer Forum. Just to confirm, are you seeing this issue when testing with the [Sample Web App](https://github.com/zoom/sample-app-web)? If so, please submit a new forum post with steps to reproduce the issue and we’ll investigate the issue further.

Thanks,  
Max

---

<div class="post-metadata">

**Author:** ![daniel2](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/daniel2/32/8619_2.png) [@daniel2](https://devforum.zoom.us/u/daniel2)\
**Post date:** [March 25, 2021, 9:59pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/12 "2021-03-25T21:59:36Z")

</div>

I confirmed just now that yes, this bug appears in the Sample Web App. That is, the bug in which **I retrieve both an error and a success callback** , but the _renaming actually works_.

Just setup the Sample Web App according to the instructions, and run this code in the browser’s console:

```auto
ZoomMtg.getCurrentUser({
  success (res) {
    console.log('Retrieved the current user.', res)
    ZoomMtg.rename({
      userId: res.result.currentUser.userId,
      oldName: res.result.currentUser.userName,
      newName: 'The New User Name',
      success (res) {
        console.log('Renamed the user.', res)
      },
      error (err) {
        console.error('Failed to rename the user!', err)
      }
    })
  },
  error (err) {
    console.error('Failed to get current user!', err)
  }
})

```

Should I create a new post about it? Here’s [a video of it in action](https://vimeo.com/529071415) as well:  
https://player.vimeo.com/video/529071415?byline=0&portrait=0&speed=0&badge=0&autopause=0&player_id=0&app_id=122963

---

<div class="post-metadata">

**Author:** ![MaxM](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/maxm/32/42303_2.png) [@MaxM](https://devforum.zoom.us/u/MaxM)\
**Post date:** [March 26, 2021, 8:04pm UTC](https://devforum.zoom.us/t/zoom-web-sdk-rename-api-usage/4344/13 "2021-03-26T20:04:17Z")

</div>

Hey @daniel2,

Thank you for providing that information as well as steps to reproduce the issue! That was very helpful. I’ve since reproduced your issue an saw that it is only present when using the Safari browser.

I’ve since reached out to our engineering team to see if they are able to provide a fix. I’ll update you here when I have more information. (CS-3216)

Thanks,  
Max
