> For the complete documentation index, see [llms.txt](https://assetstore.essentialkit.voxelbusters.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://assetstore.essentialkit.voxelbusters.com/features/app-updater/playmaker/use-cases/use-case-2-silent-policy-check.md).

# Silent Policy Check

## Goal

Check for updates silently without blocking UI, and conditionally show update prompt based on policy.

## Actions Required

| Action                                      | Purpose                                |
| ------------------------------------------- | -------------------------------------- |
| AppUpdaterRequestUpdateInfo                 | Query store for update status (cached) |
| AppUpdaterGetRequestUpdateInfoSuccessResult | Read updateStatus after SUCCESS        |

## Variables Needed

* updateStatus (Enum: AppUpdaterUpdateStatus)
* lastCheckTime (DateTime)
* checkInterval (Int) - hours between checks

## Implementation Steps

### 1. CheckIfTimeToCheck (Entry State)

Calculate time since lastCheckTime:

* If >= checkInterval → PerformCheck
* If < checkInterval → Skip

### 2. PerformCheck

**Action:** AppUpdaterRequestUpdateInfo

* Run asynchronously in background
* **Events:**
  * successEvent → GetStatus
  * failureEvent → Skip

### 3. GetStatus

**Action:** AppUpdaterGetRequestUpdateInfoSuccessResult

* **Outputs:**
  * updateStatus → updateStatus

### 4. ProcessResult

Save current time to lastCheckTime.

* If updateStatus == Available or Downloaded → ApplyUpdatePolicy
* Else → Skip

### 5. ApplyUpdatePolicy

Apply business logic:

* Critical update → Show immediate alert
* Major version → Show on next launch
* Minor version → Show badge/banner (non-intrusive)
* Patch version → Log only, no UI

### 6. Skip

Continue normal app flow without interruption

## Common Issues

* **Check frequency**: Don't check too often (recommend: 24 hours)
* **Battery/data**: Avoid checks on cellular if large metadata
* **Persistence**: Save lastCheckTime to PlayerPrefs
* **Background limits**: iOS/Android may throttle background checks

## Best Practices

* Check once per day maximum
* Use PlayerPrefs to track last check time
* Show update UI only for significant versions
* Respect user's "Don't show again" preference

## Flow Diagram

```
CheckIfTimeToCheck
├─ Time elapsed → PerformCheck
│                 ├─ SUCCESS → GetStatus → ProcessResult
│                 │                         ├─ Available/Downloaded → ApplyUpdatePolicy → [UI based on severity]
│                 │                         └─ NotAvailable → Skip
│                 └─ FAILURE → Skip
└─ Too soon → Skip
```

## Use When

* Daily app launch checks
* Non-intrusive version monitoring
* Gradual rollout strategies
* A/B testing update prompts


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://assetstore.essentialkit.voxelbusters.com/features/app-updater/playmaker/use-cases/use-case-2-silent-policy-check.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
