# OAuth for Zoom Apps for Digital Signage

<!-- WARNING: THIS FILE WAS AUTOGENERATED! DO NOT EDIT! -->

Consider the following when you use OAuth for authentication in your Zoom apps:

-   Zoom only generates the access token and the refresh token when users add or authorize an app.
-   The OAuth code expires in 5 minutes.

To ensure authenticated users can open Zoom apps in Zoom Room devices, after a user adds or authorizes the app, you must save the access token and the refresh token.

## Getting the access token and the refresh token

Do the following to get the access token and refresh token:

-   Access and refresh tokens bind to the accountId.
-   When you launch the app in Zoom Room devices, there is a context in the header which contains the accountId and roomId. Use app client secret to decrypt the context and search for the mapping access token by accountId.
-   When the access token expires, use the refresh token and clientId/Secret pair for a new access token.

## Resources

-   [In-client OAuth for Zoom Apps](/docs/zoom-apps/authentication/)
-   [Creating Zoom Apps for Digital Signage](/docs/rooms/za/za-digi-sign-enable/)
