> ## Documentation Index
> Fetch the complete documentation index at: https://docs.learnway.xyz/llms.txt
> Use this file to discover all available pages before exploring further.

# App Version Control & Feature Flags

> Managing minimum supported app versions, force-update prompts, and maintenance mode.

# App Version Control & Feature Flags

LearnWay enables remote enforcement of mobile client version requirements and maintenance flags without requiring immediate app store rebuilds.

***

## 1. Client Version Check Endpoint

On mobile app initialization, clients invoke:

```http theme={null}
GET /api/v2/app-version/check?platform=ios&version=2.1.0
```

### Response Schema

```json theme={null}
{
  "updateRequired": false,
  "updateAvailable": true,
  "minimumVersion": "2.0.0",
  "latestVersion": "2.2.0",
  "releaseNotes": "Bug fixes and new Quiz Battle mode!",
  "storeUrl": "https://apps.apple.com/app/learnway/id123456789",
  "inMaintenance": false,
  "maintenanceMessage": null
}
```

***

## 2. Admin Management

Admins configure target versions via `POST /api/v2/admin/app-version`:

* Specify `minVersion` (below which clients are blocked with force-update modal).
* Specify `latestVersion` (optional prompt to update).
* Toggle emergency `maintenanceMode` per platform (`ios`, `android`, `web`).
