iOS App
The iOS companion app is a thin SwiftUI wrapper that hosts the PWA in a WKWebView and adds native push notifications with interactive actions.
What It Adds
- Real push notifications — Not web push; actual APNs notifications that wake your phone
- Interactive snooze grid — Long-press a notification for a 3x4 grid of snooze options
- Lock screen actions — Done, +1hr, and All +1hr buttons directly on the notification
- Apple Watch support — Handle notification actions on your wrist without reaching for your phone
- Cross-device sync — Snoozed or completed tasks automatically dismiss notifications on other devices
Prerequisites
- Apple Developer Program membership ($99/year)
- APNs configuration on the server (see Notifications)
- Xcode (for building the app)
Building
The iOS project uses xcodegen to generate the Xcode project from project.yml:
bash
cd ios
xcodegen
open OpenTask.xcodeprojTargets
| Target | Description |
|---|---|
OpenTask | Main app: WKWebView host, first-launch setup, APNs registration |
OpenTaskNotification | Content extension: interactive snooze grid on notification long-press |
OpenTaskWatch | watchOS companion: handles notification actions on Apple Watch |
First-Run Setup
When the app launches for the first time:
- Enter your server URL (e.g.,
https://tasks.example.com) - Enter a Bearer token (create one with
npm run db:create-token) - The app validates the connection and stores credentials in the shared Keychain
Credentials are shared via App Group Keychain between the main app, notification extension, and Watch app.
Server Endpoints Used
| Endpoint | Purpose |
|---|---|
POST /api/push/apns/register | Device token registration |
POST /api/notifications/actions | Done/snooze from notification actions |
PATCH /api/tasks/{id} | Snooze to specific time (content extension) |
POST /api/tasks/bulk/snooze-overdue | Bulk snooze from notification action |
DELETE /api/push/apns/register | Device token unregistration |
GET /api/user/preferences | Connection validation during setup |
