# Start Meeting With ZAK - Ionic - iOS

**URL:** <https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435>\
**Category:** Meeting SDK\
**Created:** [May 29, 2019, 1:42pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435 "2019-05-29T13:42:49Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [May 29, 2019, 1:42pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/1 "2019-05-29T13:42:49Z")

</div>

**Description**  
Start Meeting With ZAK method doesn’t work on iOS (Ionic App).

**Which version?**  
4.3.94401.0325

**Smartphone:**

- Device: iPhone 6
- OS: iOS 12.1

**Additional context**

I’m developing an hybrid app (Android and iOS) in Ionic Framework. Then, I implemented a method that executes in sequence:

1. Delete last user created on API (if exists);
2. Create a new API user;
3. Get Zoom token;
4. Get Zoom acces token (ZAK);
5. Create a new meeting, and;
6. Start the API user meeting with ZAK.

This method work as well in Android devices but stop on #6 item in iOS. I get this message error: _ **Your zoom token, zoom access token, and userId are not valid** _.

What can I do?  
_Thank’s in advance._

**Method**

```nohighlight
	return new Promise((_resolve, _reject) => {

			let body: ZoomMeetingCreateOptions = {
				topic: meetingTitle,
				type: 1,
				agenda: meetingDescription,
				start_time: startTime,
				timezone: 'America/Sao_Paulo',
				duration: 120,
				settings: {
					host_video: true,
					participant_video: false,
					registrants_confirmation_email: false,
					cn_meeting: false,
					in_meeting: false,
					join_before_host: true,
					mute_upon_entry: true,
					watermark: false,
					use_pmi: false,
					approval_type: 0,
					registration_type: 2,
					audio: 'both',
					enforce_login: false,
					waiting_room: false,
					close_registration: false
				}
			};

			let options = (this.platform.is('android')) ? {
				'no_driving_mode': true,
				'no_invite': true,
				'no_meeting_end_message': true,
				'no_titlebar': false,
				'no_bottom_toolbar': false,
				'no_dial_in_via_phone': true,
				'no_dial_out_to_phone': true,
				'no_disconnect_audio': true,
				'no_share': false,
				'no_audio': false,
				'no_video': false,
				'no_meeting_error_message': true
			} : null;

			new Promise((resolve) => {
				this.deleteUser();
				resolve(true);
			}).then((res) => {
				return new Promise((resolve, reject) => {
					this.createUser().then(res => {
						resolve(res);
					}).catch(err => {
						reject(err);
					});
				});
			}).then((res) => {
				return new Promise((resolve, reject) => {
					this.getZoomToken().then(res => {
						resolve(res);
					}).catch(err => {
						reject(err);
					});
				});
			}).then((res) => {
				return new Promise((resolve, reject) => {
					this.getZoomAccessToken().then(res => {
						resolve(res);
					}).catch(err => {
						reject(err);
					});
				});
			}).then((res) => {
				return new Promise((resolve, reject) => {
					let url = `${this.apiUrl}/users/${this.userId}/meetings`;
					this.http.post(url, body, {}).then((res) => {
						resolve(res);
					}).catch(err => {
						reject(err);
					});
				});
			}).then((res) => {
				return new Promise((resolve, reject) => {
					let meetingData: ZoomMeeting = JSON.parse(res['data']);
					console.log('meetingData', meetingData);
                    // PROMISE REJECTION HERE.
					this.zoomService.startMeetingWithZAK(meetingData['id'].toString(), userName, this.zoomToken, this.zoomAccessToken, this.userId, options).then((res) => {
						_resolve(res);
					}).catch(err => {
						_reject(err); // Your zoom token, zoom access token, and userId are not valid.
					});
				});
			});
		});

```

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [May 29, 2019, 6:33pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/2 "2019-05-29T18:33:27Z")

</div>

Hi rodrigowbt,  
Thanks for using Zoom SDK. Can you also provide your Ionic info provided by `ionic info` as well?

Thanks!

---

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [May 29, 2019, 6:42pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/3 "2019-05-29T18:42:55Z")

</div>

Thanks Carson\_Chen.

This is my Ionic info.

```auto
cli packages: (/usr/local/lib/node_modules)

    @ionic/cli-utils : 1.19.3
    ionic (Ionic CLI) : 3.20.1

global packages:

    cordova (Cordova CLI) : 9.0.0 (cordova-lib@9.0.1) 

local packages:

    @ionic/app-scripts : 3.2.3
    Cordova Platforms : ios 5.0.1
    Ionic Framework : ionic-angular 3.9.2

System:

    ios-deploy : 1.9.4 
    ios-sim : 8.0.1 
    Node : v8.11.3
    npm : 6.9.0 
    OS : macOS High Sierra
    Xcode : Xcode 10.1 Build version 10B61 

Environment Variables:

    ANDROID_HOME : not set

Misc:

    backend : pro

```

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [May 30, 2019, 5:03pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/4 "2019-05-30T17:03:44Z")

</div>

Hi rodrigowbt,

Thanks for the information. I have forwarded this info to the engineer and I will get back to you asap. Thanks!

---

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [May 30, 2019, 5:30pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/5 "2019-05-30T17:30:36Z")

</div>

Thanks Carson\_Chen. I’m waiting for it. Good job!

---

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [June 5, 2019, 8:39pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/6 "2019-06-05T20:39:03Z")

</div>

Hello @carson.zoom!

I have a temporary solution to my problem.

I opened a file `<plugins/cordova.plugin.zoom/src/ios/Zoom.m>` and comment these lines (192-198) in the function `< - (void)startMeeting:(CDVInvokedUrlCommand*)command>`

```auto
if (zoomToken != nil || ![zoomToken isKindOfClass:[NSString class]] || [zoomToken length] == 0 ||
		zoomAccessToken != nil || ![zoomAccessToken isKindOfClass:[NSString class]] || [zoomAccessToken length] == 0 ||
		userId != nil || ![userId isKindOfClass:[NSString class]] || [userId length] == 0) {
		pluginResult = [CDVPluginResult resultWithStatus:CDVCommandStatus_ERROR messageAsString:@"Your zoom token, zoom access token, and userId are not valid"];
	[self.commandDelegate sendPluginResult:pluginResult callbackId:callbackId];
	return;
}

```

I do not know Objective-C language, so I guess that might not be a good solution.

Thanks!

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [June 6, 2019, 7:30am UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/7 "2019-06-06T07:30:07Z")

</div>

Hi,

Thanks for the reply. The code snippet you are mentioning is to check the required parameters that need to start a meeting with ZAK. The following parameters are required:

- zoomToken
- ZAK
- userId

Are you passing any of the above parameters and then did not pass the parameter check? If you commented this code block out, is everything work as expected?

Thanks!

---

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [June 6, 2019, 11:18am UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/8 "2019-06-06T11:18:29Z")

</div>

Hello Carson\_Chen.

That’s it. I’m passing all parameters and the code snippet doesn’t recognized them. Then, Zoom meeting not start.

I comment the code snippet and my app start a new Zoom meeting perfectly!

Thanks!

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [June 6, 2019, 9:13pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/9 "2019-06-06T21:13:47Z")

</div>

Hi,

Thanks for the info. I will pass this info to the engineer and ensure we double check the condition checker. Pardon the inconvenience caused by this.

Thanks!

---

<div class="post-metadata">

**Author:** ![rodrigowbt](https://avatars.discourse-cdn.com/v4/letter/r/439d5e/32.png) [@rodrigowbt](https://devforum.zoom.us/u/rodrigowbt)\
**Post date:** [June 7, 2019, 12:38pm UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/10 "2019-06-07T12:38:31Z")

</div>

Hello Carson\_Chen!

Don’t worry!  
Thank you for help me!

---

<div class="post-metadata">

**Author:** ![neerajs](https://avatars.discourse-cdn.com/v4/letter/n/9fc348/32.png) [@neerajs](https://devforum.zoom.us/u/neerajs)\
**Post date:** [May 25, 2020, 5:56am UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/11 "2020-05-25T05:56:22Z")

</div>

Hi @rodrigowbt, Can you post your code for the http request you make to get zoom token and zoom access token? I’ve been trying, but unable to make it work.

---

<div class="post-metadata">

**Author:** ![carson.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/carson.zoom/32/785_2.png) [@carson.zoom](https://devforum.zoom.us/u/carson.zoom)\
**Post date:** [June 17, 2020, 6:48am UTC](https://devforum.zoom.us/t/start-meeting-with-zak-ionic-ios/4435/12 "2020-06-17T06:48:30Z")

</div>

Closed on June 17, 2020, 6:48am UTC


