#21 Usage events quality:
- Replace event type when-expression with comprehensive lookup table
covering all 30 documented UsageEvents constants (was showing "unknown(11)")
- Format timestamps as ISO-8601 instead of raw epoch millis
- Filter out com.rousecontext and Android system intelligence packages
by default; add include_system parameter to opt back in
#44 Generate new address cooldown text:
- Change misleading "(once per 30 days)" to "Changes take effect immediately"
since secret rotation has no cooldown
#36 Notification history empty:
- Seed active notifications into Room when NotificationCaptureService
first connects via onListenerConnected, so pre-existing notifications
appear in history queries
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
UsageStatsManager returns multiple UsageStats entries per package for
different internal time buckets. All usage tools (summary, per-app,
compare) now merge entries by package name, summing foreground time
before returning results. The daily breakdown in get_app_usage also
merges by date to avoid duplicate day entries.
Adds a test verifying deduplication produces one entry per package
with correctly summed time.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Enable core library desugaring for java.time and java.util.Base64 usage
in app, core:mcp, health, and notifications modules
- Guard NotificationChannel creation (API 26+) in NotificationChannels
and OutreachMcpProvider
- Guard FOREGROUND_SERVICE_TYPE_DATA_SYNC (API 29+) in
TunnelForegroundService, fall back to type-less startForeground
- Use ContextCompat.startForegroundService() in FcmReceiver and
TestWakeReceiver for pre-API-26 compatibility
- Guard Health Connect availability check for API 28+ in
HealthConnectIntegration
- Add tools:overrideLibrary for Health Connect in health manifest
- Pin Robolectric to SDK 33 in outreach, work, and notifications test
resources to match app module
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Claude's client sends protocolVersion "2025-11-25" in its initialize
request. SDK 0.4.0 only supported 2024-11-05 and fell back to that
version, which modern clients may reject. SDK 0.10.0 advertises
2025-11-25 and negotiates down to 2025-06-18 / 2025-03-26 / 2024-11-05.
Breaking changes from the SDK upgrade:
- Types moved from io.modelcontextprotocol.kotlin.sdk to .sdk.types
- Tool.Input renamed to ToolSchema
- CallToolRequest.arguments moved to CallToolRequest.params.arguments
(now nullable JsonObject?)
- Transport.send gains TransportSendOptions? parameter
- Server.connect() renamed to Server.createSession()
- addTool/addResource handlers receive ClientConnection receiver
Also bumps Kotlin 2.1.10 -> 2.2.21, AGP 8.8.2 -> 8.10.0, and
KSP 2.1.10-1.0.31 -> 2.2.21-2.0.5 to satisfy SDK metadata version
requirements.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
New :usage module exposes UsageStatsManager data as MCP tools:
- get_usage_summary: per-app screen time breakdown for a period
- get_app_usage: detailed single-app usage with daily breakdown
- get_usage_events: raw usage events (app open/close)
- compare_usage: compare two periods, show biggest changes
Wired into app via UsageIntegration with AppOpsManager permission check.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>