Effortless Notifications and Permissions with Kotlin-friendly APIs
summary
NotificationCompat ballooned to 25× larger (now ~10,000 lines) with over 86 public methods on the builder and 500+ symbols, which makes posting a notification error-prone; posting requires a channel ID and a small icon and since Android 13 it also requires a runtime permission. A Kotlin-first solution is presented: a concise notification DSL, inline ChannelId typing, coroutines-based ensurePermission that handles rationale, settings flow and edge cases, and a Compose-friendly rememberPermissionRequestState — prototypes compile and demo successfully.
AI-written summary · about
chapters (15)
- 0:00Introduction and poll
- 3:02Speaker introduction
- 4:08Notifications API challenges
- 7:30Kotlin-friendly notification API
- 11:09Notification requirements on API 30
- 13:35Live demo of Kotlin API
- 17:58Runtime permissions overview
- 20:47Permission request as a function
- 23:16Ensure permission function
- 29:20Activity result contracts
- 31:09Live demo of permission API
- 34:24Compose permission request state
- 39:02Q&A session
- 41:30Where to find the APIs
- 43:56Future of split libraries
related talks
19mModern Android notifications
01h 12mThe Entertaining Life in the Notification Panel
46mRespecting User Attention: Notification Best Practices
37mEmpathetic UX with progress-centric notifications
31mThe History of Notifications Every Developer Should Know
28mSupporting Notification Channels
36mStreamlining Permission Request in Jetpack Compose
51mModern Android Development
