| .. | .. |
|---|
| 38 | 38 | - [ ] **L6: Version number** — Default 1.0.0+1, set correctly before submission |
|---|
| 39 | 39 | - [ ] **L7: App icon** — Verify meets Apple guidelines (no alpha channel, correct sizes) |
|---|
| 40 | 40 | |
|---|
| 41 | +## APNs Push Notifications (implemented 2026-04-01) |
|---|
| 42 | + |
|---|
| 43 | +- [x] **APNs server side** — `src/apns/client.ts` in AIBroker: ApnsClient initialised from APNS_KEY_PATH/APNS_KEY_ID/APNS_TEAM_ID env vars, sandbox by default. Token storage in `~/.aibroker/apns-tokens.json`. `sendPush()` fires when `getMqttClientCount() == 0`. |
|---|
| 44 | +- [x] **APNs Flutter side** — `lib/services/push_service.dart`: `push` package (3.3.3, no Firebase). Requests permission on app start, publishes token to `pailot/device/token` MQTT topic. Re-registers on reconnect. |
|---|
| 45 | +- [x] **Entitlements** — `ios/Runner/Runner.entitlements` with `aps-environment=development`. All three build configs have `CODE_SIGN_ENTITLEMENTS` set. |
|---|
| 46 | +- [x] **UIBackgroundModes** — `remote-notification` added to Info.plist. |
|---|
| 47 | +- [x] **AppDelegate** — forwards UNUserNotificationCenter delegate methods to push plugin. |
|---|
| 48 | +- [ ] **Provisioning profile** — APNs requires an explicit provisioning profile from Apple Developer portal that includes Push Notifications capability. Must update in Xcode before deployment. Switch `aps-environment` to `production` in entitlements for App Store builds. |
|---|
| 49 | + |
|---|
| 41 | 50 | ## App Store Requirements |
|---|
| 42 | 51 | |
|---|
| 43 | 52 | | Requirement | Status | Action | |
|---|
| .. | .. |
|---|
| 49 | 58 | | NSBonjourServices | PASS | Fixed - removed _http._tcp | |
|---|
| 50 | 59 | | NSAppTransportSecurity | PASS | Fixed - removed NSAllowsArbitraryLoads | |
|---|
| 51 | 60 | | UIBackgroundModes: audio | PASS | - | |
|---|
| 61 | +| UIBackgroundModes: remote-notification | PASS | Added 2026-04-01 | |
|---|
| 62 | +| Push Notifications entitlement | PASS | Added Runner.entitlements 2026-04-01 | |
|---|
| 63 | +| APNs provisioning profile | FAIL | Must update in Xcode / Developer Portal | |
|---|
| 52 | 64 | | Privacy Policy | FAIL | Fix L2 | |
|---|
| 53 | 65 | | PrivacyInfo.xcprivacy | FAIL | Fix L1 | |
|---|
| 54 | 66 | | TLS for network | PASS | Fixed C2 - self-signed cert, onBadCertificate=true | |
|---|