# Authentication fails with SDK Key and SDK Secret

**URL:** <https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893>\
**Category:** Meeting SDK\
**Created:** [April 7, 2020, 4:45pm UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893 "2020-04-07T16:45:45Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ar3396](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@ar3396](https://devforum.zoom.us/u/ar3396)\
**Post date:** [April 7, 2020, 4:45pm UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893/1 "2020-04-07T16:45:45Z")

</div>

**Description**  
When authenticating using a valid SDK Key and SDK Secret (acquired from Zoom) after initializing the MobileRTC SDK, for some reason, I get an `MobileRTCAuthError_KeyOrSecretWrong` error.

**Which version?**  
v4.6.15805.0403

**To Reproduce(If applicable)**  
Code:

```nohighlight
let context = MobileRTCSDKInitContext()
context.domain = "https://zoom.us"
context.enableLog = true
context.locale = .default
context.appGroupId = ""
let initSuccess = MobileRTC.shared().initialize(context)
if initSuccess, let authService = MobileRTC.shared().getAuthService() {
    authService.delegate = self
    authService.clientKey = "<MY SDK KEY>"
    authService.clientSecret = "<MY SDK SECRET>"
    authService.sdkAuth()
}

```

```nohighlight
extension AppDelegate: MobileRTCAuthDelegate {
    func onMobileRTCAuthReturn(_ returnValue: MobileRTCAuthError) {
        print("onMobileRTCAuthReturn: \(returnValue) \(MobileRTC.shared().getAuthService()?.isLoggedIn() ?? false)")
    }
}

```

**Screenshots**  
Attached is a screenshot of the Zoom web interface from where I fetch my SDK credentials (blacked out sensitive information)

 ![Screen Shot 2020-04-07 at 11.00.19 AM](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/2X/a/ab4e535cb1c2ee56984deb21a7631b252c723ee6.png)

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

- Device: iPhone 10
- OS: iOS 13.0
- Version 13.0

**Additional context**  
I also tried regenerating the SDK Key as well as using a JWT Token to authenticate but those failed as well.

---

<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:** [April 8, 2020, 6:44am UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893/2 "2020-04-08T06:44:09Z")

</div>

Hi [ar3396](https://devforum.zoom.us/u/ar3396),

Thanks for the post. Your code looks good. Please try to deactivate your SDK app on Marketplace and then re-activate it and see if it helps.

Thanks!

---

<div class="post-metadata">

**Author:** ![ar3396](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@ar3396](https://devforum.zoom.us/u/ar3396)\
**Post date:** [April 8, 2020, 1:21pm UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893/3 "2020-04-08T13:21:50Z")

</div>

Hi Carson, I tried out your suggestion. The issue remains after deactivating and reactivating.

---

<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:** [April 9, 2020, 5:23am UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893/4 "2020-04-09T05:23:30Z")

</div>

Hi [ar3396](https://devforum.zoom.us/u/ar3396),

I have forwarded this to the engineering team and will get back to you shortly. Thanks!

---

<div class="post-metadata">

**Author:** ![DeveloperBot](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/developerbot/32/12632_2.png) [@DeveloperBot](https://devforum.zoom.us/u/DeveloperBot)\
**Post date:** [August 21, 2020, 8:23pm UTC](https://devforum.zoom.us/t/authentication-fails-with-sdk-key-and-sdk-secret/11893/5 "2020-08-21T20:23:12Z")

</div>

Closed on August 21, 2020, 8:23pm UTC


