# Error when starting meeting for the first time

**URL:** <https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530>\
**Category:** macOS\
**Created:** [August 3, 2022, 4:32pm UTC](https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530 "2022-08-03T16:32:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymousedge03](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/anonymousedge03/32/18582_2.png) [@anonymousedge03](https://devforum.zoom.us/u/anonymousedge03)\
**Post date:** [August 3, 2022, 4:32pm UTC](https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530/1 "2022-08-03T16:32:11Z")

</div>

**Description**  
Whenever I initialize the Mac SDK and then start the meeting, the first meeting always fails with the error value 5. Then the subsequent meetings are started successfully. The code I am using to start meeting is given below.

```
   if let meetingService = self.zoomSdk?.getMeetingService() {
        zoomSdk?.getMeetingService()?.getMeetingUIController()?.delegate = self
        meetingService.delegate = self;
        
        let joinParams = ZoomSDKJoinMeetingElements()
        
        joinParams.displayName = "ABC"
        joinParams.meetingNumber = 92676282725
        joinParams.userType = ZoomSDKUserType_WithoutLogin
        joinParams.password = "109140"
        joinParams.zak = "eyJ0eXAiOiJKV1QiLCJzdiI6IjAwMDAwMSIsInctX3NrbSI6InptX28ybSIsImFsZyI6IkhTMjU2In0.eyJhdWQiOiJjbGllbnRzbSIsInVpZCI6ImRoWHNtWXNxVHdLck5PLS1IRjJOLVEiLCJpc3MiOiJ3ZWIiLCJzayI6IjAiLCJzdHkiOjk5LCJ3Y2QiOiJhdzEiLCJjbHQiOjAsIm1udW0iOiI5MjY3NjI4MjcyNSIsImV4cCI6MTY2NzMyMDE1NCwiaWF0IjoxNjU5NTQ0MTU0LCJhaWQiOiJtZV9CVjB3d1RkLWZmZ3ctakZGZml3IiwiY2lkIjoiIn0.eJ7yxEanBSo_P4z3RtkMZ3TW99EKYZkSdGIhRoaKWfI"
        
        let joinMeetingResult: ZoomSDKError = meetingService.joinMeeting(joinParams)
        print(joinMeetingResult)
    }

```

**Which macOS Meeting SDK version?**  
zoom-sdk-macos-5.11.3.9091

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

- Device: [e.g. Apple M1 Pro (14-inch, 2021)]
- OS: [e.g. macOS Monterey 12.5]

---

<div class="post-metadata">

**Author:** ![chunsiong.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/chunsiong.zoom/32/35488_2.png) [@chunsiong.zoom](https://devforum.zoom.us/u/chunsiong.zoom)\
**Post date:** [August 5, 2022, 1:35pm UTC](https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530/2 "2022-08-05T13:35:34Z")

</div>

@anonymousedge03 ,could you try the same, but with a shorter expiry on your JWT token?

> **[SDK Authentication](https://marketplace.zoom.us/docs/sdk/native-sdks/auth/)**
>
> 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.

The expiry of your JWT token should not be more than 48 hours from your current timestamp

---

<div class="post-metadata">

**Author:** ![anonymousedge03](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/anonymousedge03/32/18582_2.png) [@anonymousedge03](https://devforum.zoom.us/u/anonymousedge03)\
**Post date:** [August 8, 2022, 9:03am UTC](https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530/3 "2022-08-08T09:03:17Z")

</div>

@chunsiong.zoom I am still facing this issue. I tried using a JWT token with an expiry time of 24 hours. Still, the meeting doesn’t start for the first time. The second time it works.

---

<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:** [September 7, 2022, 7:04pm UTC](https://devforum.zoom.us/t/error-when-starting-meeting-for-the-first-time/73530/4 "2022-09-07T19:04:17Z")

</div>

Closed on September 7, 2022, 7:04pm UTC

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