# OAuth token refresh response is sometimes slow (up to 95 seconds!)

**URL:** <https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667>\
**Category:** API and Webhooks\
**Created:** [July 20, 2020, 8:02pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667 "2020-07-20T20:02:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![smurray](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/smurray/32/19830_2.png) [@smurray](https://devforum.zoom.us/u/smurray)\
**Post date:** [July 20, 2020, 8:02pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667/1 "2020-07-20T20:02:34Z")

</div>

**Description**  
We’re seeing instances of calls to refresh OAuth tokens that are taking longer to process. The worst one looks to be around 95 seconds to get a response back from the server. According to our metrics this started around 7/14 and has been continuing to be slow over the last week.

Is this a known issue? Can this be addressed?

**Error**  
Long response times for OAuth refresh requests.

**Which App Type (OAuth / Chatbot / JWT / Webhook)?**  
OAuth App

**Which Endpoint/s?**  
[https://zoom.us/oauth/token?grant\_type=refresh\_token](https://zoom.us/oauth/token?grant_type=refresh_token)

> **[OAuth 2.0 - Authorization - Documentation](https://marketplace.zoom.us/docs/guides/auth/oauth)**
>
> OAuth with Zoom
> 
> The Zoom API uses OAuth 2.0 to authenticate and authorize users to make requests. To setup access credentials and request scopes for yo...

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

1. Create OAuth app
2. Get OAuth token
3. Attempt to refresh the token
4. Observe occasional response times that are seconds to tens of seconds long.

**Screenshots (If applicable)**  
p95 Response Times times for calls to OAuth refresh

 ![image](https://us1.discourse-cdn.com/flex016/uploads/zoomdeveloper/original/2X/b/b18ae9a6f9c3dcf71d9e01ec802aee45d33c66af.png)

**Additional context**  
We could add in a timeout to these requests but is that going to mess up the token refresh process? The API only seems to support using a refresh token a single time so I am wary about putting in any sort of short-circuit that will timeout requests to try again as it may blow up the token and I will need customer user intervention to get a new one.

---

<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:** [July 20, 2020, 8:29pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667/3 "2020-07-20T20:29:21Z")

</div>

Hey @smurray,

Thanks for letting us know, we are looking into the issue. (ZOOM-178700)

I will provide updates as soon as I get them.

-Tommy

---

<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:** [August 4, 2020, 4:24pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667/4 "2020-08-04T16:24:37Z")

</div>

Hey @smurray,

After our engineers looked into the issue, the believe it is due to slow network connection on your end.

Are you still seeing this issue? If so, can you check your network connection?

Thanks,  
Tommy

---

<div class="post-metadata">

**Author:** ![smurray](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/smurray/32/19830_2.png) [@smurray](https://devforum.zoom.us/u/smurray)\
**Post date:** [September 1, 2020, 6:26pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667/5 "2020-09-01T18:26:56Z")

</div>

@tommy

Circling back on this. The refresh times we were seeing were on AWS EC2 instances. I didn’t see anything else in the logs that would have signified a slow network connection or network throttling.

I have not seen this long of delays but we do see occasional OAuth refresh responses that take multiple seconds to return.

---

<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 3, 2020, 9:48pm UTC](https://devforum.zoom.us/t/oauth-token-refresh-response-is-sometimes-slow-up-to-95-seconds/24667/6 "2020-09-03T21:48:13Z")

</div>

Hey @smurray,

Thanks for the additional info. During peak usage it is possible the API could respond in a couple seconds. Please let us know if you see long response times in the future. 🙂

-Tommy
