# Mobile Payments SDK save authorization

**URL:** <https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306>\
**Category:** Questions\
**Tags:** mobile-payments-sdk\
**Created:** [May 13, 2025, 10:47pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306 "2025-05-13T22:47:09Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mauliks](https://avatars.discourse-cdn.com/v4/letter/m/96bed5/32.png) [@Mauliks](https://developer.squareup.com/forums/u/Mauliks)\
**Post date:** [May 13, 2025, 10:47pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/1 "2025-05-13T22:47:09Z")

</div>

Hello,

For Reader SDK once initialized and authorized, the SDK stores authorization, and when a user opens the app next time no authorization is needed. We can use `[SQRDReaderSDK sharedSDK].isAuthorized` to confirm.

Is there anything similar available in `SQMPMobilePaymentsSDK`? It seems every time the app opens it requires authorization before using the SDK.

---

<div class="post-metadata">

**Author:** ![Square-Dev-AI](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/square-dev-ai/32/2513_2.png) [@Square-Dev-AI](https://developer.squareup.com/forums/u/Square-Dev-AI)\
**Post date:** [May 13, 2025, 10:47pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/2 "2025-05-13T22:47:21Z")

</div>

👋 I’m Square Dev AI, here to help answer your question!  
Based on the information you’ve provided, the following documentation will help answer your question:

> **[Mobile Authorization API: How It Works](https://developer.squareup.com/docs/mobile-authz/how-it-works)**
>
> Use the Mobile Authorization API to request authorization tokens to initialize Square mobile solutions like the Reader SDK.

> **[Mobile Authorization API](https://developer.squareup.com/docs/mobile-authz/what-it-does)**
>
> Get an overview of the Square Mobile Authorization API for solutions like the Reader SDK.

> **Additional Documentation**
>
> [Build with the Mobile Authorization API](https://developer.squareup.com/docs/mobile-authz/build-with-mobile-authz)  
> [Reader SDK Requirements](https://developer.squareup.com/docs/app-marketplace/requirements/reader-sdk)  
> [Reader SDK](https://developer.squareup.com/docs/reader-sdk/what-it-does)

If this documentation helped you find a solution, please check the box indicating that this reply solves the problem.  
Otherwise one of our Developer Advocates will provide additional assistance shortly.

---

<div class="post-metadata">

**Author:** ![Bryan-Square](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/bryan-square/32/38_2.png) [@Bryan-Square](https://developer.squareup.com/forums/u/Bryan-Square)\
**Post date:** [May 13, 2025, 11:03pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/3 "2025-05-13T23:03:23Z")

</div>

You can check whether a user of your application is `authorized`, `notAuthorized`, or (in the process of) `authorizing` by checking `AuthorizationManager.state` prior to beginning authorization.

To track changes in the authorization state, add an `AuthorizationStateObserver` to your `viewController` to receive updates to the authorization `state` whenever the Mobile Payments SDK is authorized or deauthorized. 🙂

---

<div class="post-metadata">

**Author:** ![Mauliks](https://avatars.discourse-cdn.com/v4/letter/m/96bed5/32.png) [@Mauliks](https://developer.squareup.com/forums/u/Mauliks)\
**Post date:** [May 14, 2025, 2:58am UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/4 "2025-05-14T02:58:46Z")

</div>

Hi Bryan,

I am checking like below:

```auto
- (BOOL)isSquareSDKAuthorized
{
    if (_isInitialized)
    {
        if (SQMPMobilePaymentsSDK.shared.authorizationManager.state == SQMPAuthorizationStateAuthorized)
            return YES;
        else
            return NO;
    }
    return NO;
}

```

It returns always false because the SDK is not authorized because I am authorizing the SDK later in the app. But previously I had authorized the SDK and I am just opening the app again.

So is there a way that SDK remembers that it was authorized previously like `[SQRDReaderSDK sharedSDK].isAuthorized`? Otherwise, I need to call APIs to get access tokens every time I open the app. My app just checks authorization at start-up to display the Location name on the screen.

Is it possible?

---

<div class="post-metadata">

**Author:** ![Bryan-Square](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/bryan-square/32/38_2.png) [@Bryan-Square](https://developer.squareup.com/forums/u/Bryan-Square)\
**Post date:** [May 14, 2025, 5:17pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/5 "2025-05-14T17:17:20Z")

</div>

Access tokens are good for 30 day’s and we recommend refreshing them every 7 days. You can use the same access token over and over agian to call the `authorize()` method with an [OAuth access token](https://developer.squareup.com/docs/oauth-api/overview) and location ID. 🙂

---

<div class="post-metadata">

**Author:** ![Mauliks](https://avatars.discourse-cdn.com/v4/letter/m/96bed5/32.png) [@Mauliks](https://developer.squareup.com/forums/u/Mauliks)\
**Post date:** [May 14, 2025, 7:16pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/7 "2025-05-14T19:16:12Z")

</div>

Hi Bryan,

Ok understood. Thanks for the info.

> Tokens are good for 30 day’s

This applies to the below token, right?

 ![image](https://global.discourse-cdn.com/square/original/2X/1/1176c1b7155d4a22274c82cdd664eb725d6859cd.png)

---

<div class="post-metadata">

**Author:** ![Bryan-Square](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/bryan-square/32/38_2.png) [@Bryan-Square](https://developer.squareup.com/forums/u/Bryan-Square)\
**Post date:** [May 14, 2025, 7:48pm UTC](https://developer.squareup.com/forums/t/mobile-payments-sdk-save-authorization/22306/8 "2025-05-14T19:48:36Z")

</div>

No, that token will never expire. Only OAuth tokens expire. 🙂
