# How to setup a waiting room using Video SDK?

**URL:** <https://devforum.zoom.us/t/how-to-setup-a-waiting-room-using-video-sdk/110645>\
**Category:** Video SDK\
**Tags:** video-sdk\
**Created:** [May 24, 2024, 2:35pm UTC](https://devforum.zoom.us/t/how-to-setup-a-waiting-room-using-video-sdk/110645 "2024-05-24T14:35:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![hamilton](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/hamilton/32/59998_2.png) [@hamilton](https://devforum.zoom.us/u/hamilton)\
**Post date:** [May 24, 2024, 2:35pm UTC](https://devforum.zoom.us/t/how-to-setup-a-waiting-room-using-video-sdk/110645/1 "2024-05-24T14:35:57Z")

</div>

I aim to ensure that every participant who is not a host gets approved by the host before joining the video session. I couldn’t find information in the documentation on setting up a waiting room. Below are the steps I used to create the video session.

thanks!

## Create JWT token on the API side

```auto
    const iat = Math.round(new Date().getTime() / 1000) - 30
    const exp = iat + 60 * 60 * 2
    const oHeader = { alg: 'HS256', typ: 'JWT' }

    let role = ZOOM_ROLE.PARTICIPANT
    let identity = 'Participant'

    if (this.isModerator(context)) {
      role = ZOOM_ROLE.HOST
    }

if (context.userID) {
      identity = `${context.firstName} ${context.lastName}`;
    }

    const oPayload = {
      app_key: this.zoomSDKKey,
      tpc: roomID,
      role_type: role,
      user_identity: identity,
      version: 1,
      iat: iat,
      exp: exp
    }
    this.logger.log(`Zoom Token Content ${redact(oPayload)}`);

    const jwt = jsonwebtoken.sign(oPayload, this.zoomSDKSecret, {
      algorithm: 'HS256',
      header: oHeader,
    });

```

## Join the session on the client side

```auto
    this.client = ZoomVideoSDK.createClient()
    this.client.init('en-US', 'CDN');

    const config = {
      videoSDKJWT: videoSession.token,
      sessionName: videoSession.roomID,
      userName: videoSession.userID,
      features: ['video', 'audio', 'share', 'users', 'settings']
    }

    const sessionContainer: HTMLElement | null = document.querySelector(htmlElementID)
    console.log('[video-session] config', config, sessionContainer)
    if (sessionContainer) {
      console.log('uitoolkit start')
      uitoolkit.joinSession(sessionContainer, config)
    }

```

---

<div class="post-metadata">

**Author:** ![hamilton](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/hamilton/32/59998_2.png) [@hamilton](https://devforum.zoom.us/u/hamilton)\
**Post date:** [May 24, 2024, 6:09pm UTC](https://devforum.zoom.us/t/how-to-setup-a-waiting-room-using-video-sdk/110645/2 "2024-05-24T18:09:19Z")

</div>

No mentions of a waiting room setting:

- at JWT Token documentation: [Video SDK - Authorize](https://developers.zoom.us/docs/video-sdk/auth/#payload)
- at join parameters [Video SDK - Authorize](https://developers.zoom.us/docs/video-sdk/auth/)

I am starting to think that this feature does not exist ☹

---

<div class="post-metadata">

**Author:** ![vic.yang](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/vic.yang/32/24656_2.png) [@vic.yang](https://devforum.zoom.us/u/vic.yang)\
**Post date:** [May 27, 2024, 2:48am UTC](https://devforum.zoom.us/t/how-to-setup-a-waiting-room-using-video-sdk/110645/3 "2024-05-27T02:48:08Z")

</div>

Hey @hamilton

Thanks for your feedback.

The Video SDK does not currently have a straightforward waiting room feature, but this capability can be achieved using subsessions.

Here is a brief guideline article on how to do it…

> **[Building a telehealth waiting room with Zoom Video SDK](https://developers.zoom.us/blog/building-telehealth-waiting-room-video-sdk/)**
>
> 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.

Thanks  
Vic
