-
Notifications
You must be signed in to change notification settings - Fork 980
Description
Feature Request
Motivation
Kotlin Multiplatform (KMP) is increasingly adopted to share authentication, networking, and business logic across Android, iOS, and desktop. AppAuth is a critical OAuth2/OIDC library in the Android ecosystem, and having it available as a multiplatform library would eliminate duplicated implementations and reduce maintenance costs for teams building cross-platform apps. KMP support would allow developers to reuse the same authentication logic across platforms while still integrating with platform-specific UX flows.
Description
I would like to request adding official Kotlin Multiplatform (KMP) support to AppAuth.
What would be valuable:
A shared KMP module for the core OAuth and OIDC logic (token requests, auth state, configuration parsing, etc.).
expect/actual declarations for platform-specific behavior.
Optional Android-specific features such as Custom Tabs kept in an Android source set.
Keeping existing Android API stable so current users are not affected.
This enables teams to build unified authentication flows across Android and iOS without rewriting the entire OAuth stack for each platform.
No breaking changes are expected if KMP is introduced as an additional module while preserving the current Android implementation.
Alternatives or Workarounds
Currently, developers must:
Maintain two separate authentication implementations for Android and iOS, or
Use third-party KMP OIDC libraries that do not fully match AppAuth’s reliability or spec coverage.
These workarounds increase complexity and risk platform-specific inconsistencies.