age_verification 0.2.4 copy "age_verification: ^0.2.4" to clipboard
age_verification: ^0.2.4 copied to clipboard

A Flutter plugin for querying platform age signals via Google Play Age Signals on Android and Apple DeclaredAgeRange on iOS, for regional age verification compliance.

0.2.4 #

iOS #

  • Added skipEligibilityCheck parameter to verifyAge — when true, the isEligibleForAgeFeatures check on iOS 26.2+ is bypassed and requestAgeRange is called directly; useful if isEligibleForAgeFeatures hangs or is unreliable in your region. Has no effect on Android. Defaults to false (existing behavior).

0.2.3 #

Updated Readme, No Code Changes

0.2.2 #

iOS #

  • Replaced deprecated UIApplication.keyWindow and UIWindowScene.windows usage in presentationViewController() with UIWindowScene.keyWindow (available since iOS 15); primary path targets the foreground-active scene, fallback searches all connected scenes

Breaking changes #

  • verifyAge parameter ageGates is now named instead of positional — call sites must be updated to verifyAge(ageGates: [...]) or verifyAge()
  • AgeVerification is now a singleton — use AgeVerification.instance instead of constructing instances directly

Housekeeping #

  • Added topics to pubspec.yaml for pub.dev discoverability
  • Reformatted Android and iOS source files to consistent 4-space indentation (no logic changes)

0.2.1 #

iOS #

  • Added CocoaPods podspec (ios/age_verification.podspec) for compatibility with older Flutter tooling that does not support Swift Package Manager

Example #

  • Fixed example iOS Xcode project to correctly reference the age_verification Swift Package Manager package

0.2.0 #

Breaking changes #

  • Renamed AgeSignalsStatusAgeVerificationStatus for naming consistency across the public API

0.1.0 #

Initial working release.

Android #

  • Integrated Google Play Age Signals API (com.google.android.play:age-signals:0.0.3)
  • Implements AgeSignalsManagerFactory, AgeSignalsManager.checkAgeSignals(), and full AgeSignalsVerificationStatus mapping
  • Reports ageLower, ageUpper, and installId from AgeSignalsResult
  • Maps all AgeSignalsException error codes to typed AgeVerificationErrorCode values
  • Mock mode uses Google's official FakeAgeSignalsManager for accurate simulation

iOS #

  • Integrated Apple DeclaredAgeRange framework (iOS 26.0+)
  • Calls AgeRangeService.shared.requestAgeRange(ageGates:in:) with 1–3 age gates
  • Checks isEligibleForAgeFeatures on iOS 26.2+ to skip prompt for non-applicable regions
  • Maps AgeRangeDeclaration (.selfDeclared, .guardianDeclared) to AgeDeclarationSource
  • Catches AgeRangeService.Error.notAvailable and .invalidRequest as typed errors
  • Returns apiNotAvailable on iOS < 26.0 or when DeclaredAgeRange is not linked
  • Uses Swift Package Manager (CocoaPods podspec added in 0.2.1)

Dart #

  • Type-safe pigeon channel: AgeVerificationApi, AgeVerificationResult, AgeVerificationStatus, AgeDeclarationSource, AgeVerificationErrorCode
  • Public API: AgeVerification.init({mockConfig}) and AgeVerification.verifyAge(ageGates)
  • AgeVerificationMockConfig — pass to init() to bypass native APIs on both platforms for testing

0.0.1 #

  • Initial plugin scaffold.
0
likes
160
points
257
downloads

Documentation

API reference

Publisher

verified publishergtirkha.com

Weekly Downloads

A Flutter plugin for querying platform age signals via Google Play Age Signals on Android and Apple DeclaredAgeRange on iOS, for regional age verification compliance.

Repository (GitHub)
View/report issues

Topics

#age-verification #age-range #age-signals #declared-age-range

License

MIT (license)

Dependencies

flutter, meta

More

Packages that depend on age_verification

Packages that implement age_verification