Post

Replies

Boosts

Views

Activity

Reply to Guidance on implementing Declared Age Range API in response to Texas SB2420
Many thanks.   Having thought about all this for another day, my new plan is to drop the App Store age rating check (for now), and use age 18 for the age gate parameter. That may be the safe and simplest way. It will hurt some Texas users, but not the rest of the world, which is very important.   If requestAgeRange throws, I will assume the user is a child and restrict access. That raises another question. If the whole app is OK for 4+, what should be blocked ? Should we terminate the app ?
Dec ’25
Reply to Guidance on implementing Declared Age Range API in response to Texas SB2420
@jwcarr thanks for this detailed analysis. That's the type of advice we would have expected from Apple… I think they have ways to avoid the legal issues. A few more points: There should likely be a step (0) (0) check if iOS is 26+. Otherwise, proceed without any test (because we cannot do them) (1) get the App Store age rating with let appStoreAgeRating = await AppStore.ageRatingCode ?? 18, (2) request the user's age with let ageRangeResponse = try await AgeRangeService.shared.requestAgeRange(ageGates: appStoreAgeRating), (3) check that the user has agreed to share their age, (4) check that lowerBound >= appStoreAgeRating, and (5) check that the verification method is not one of the self-declared methods. If this procedure fails, I should block access to the app and provide a link to Apple's support page A few more questions: in (1), which import to use AppStore.ageRatingCode ? in (2), if UIKit and not SwiftUI, need the in parameter let ageRangeResponse = try await AgeRangeService.shared.requestAgeRange(ageGates: appStoreAgeRating, in: self) where should parental control be tested ? In step (5) ? where to deal with change in user's age or repudiation (as required by law if I read properly) what happens if the requests in await do not respond ? Is there some type of timeout, to avoid user being locked in waiting ? It is a serious issue not be able to test on simulator. We may be forced to publish an app without thoroughly testing it works OK for so in Texas.
Dec ’25
Reply to Where to find sample code for SB2420 compliance and questions
isEligibleForAgeFeatures issue solved with forum help. func testAgeRange() async -> Bool { do { let isEligible = try await AgeRangeService.shared.isEligibleForAgeFeatures if !isEligible { return true // Not in Texas } } catch { // AgeRangeService.Error.notAvailable { // No age range provided. return false } But cannot be tested on simulator, that's a major issue.
Topic: UI Frameworks SubTopic: UIKit Tags:
Dec ’25
Reply to Inquiry Regarding the Scope of DeclaredAgeRange Acquisition​
@jarrodlombardo-eventbase That's an important var. However, when calling it (in UIKit environment), I get an error "Cannot find 'isEligibleForAgeFeatures' in scope". What is the framework to import ? Note: I also asked the question in the other thread: https://developer.apple.com/forums/thread/809829 Would be really great to get Apple answers to clarify all this. It is really messy.
Topic: App & System Services SubTopic: General Tags:
Dec ’25
Reply to Where to find sample code for SB2420 compliance and questions
line 19: I used the documentation sample for AgeRangeService, but get a Compiler Error: Missing argument for parameter 'in' in call That was for SwiftUI. For UIKit, require in parameter. So code reformatted. Removes all errors except unknown isEligibleForAgeFeatures. All other questions remain. func testAgeRange() async -> Bool { if !isEligibleForAgeFeatures { // Which import needed ? return true // Not called from Texas } do { let response = try await AgeRangeService.shared.requestAgeRange(ageGates: 13, 15, 18, in: self) // Can I use the 4 gate instead ? ageGates: 4, 13, 18 // guard let lowerBound = response.lowerBound else { // // Allow access to under 13 features. // return false // } var lowerBound = 4 switch response { case .declinedSharing: print("User declined to share age.") return false case .sharing(let range): lowerBound = range.lowerBound ?? 4 print("User age range: \(range.lowerBound ?? 0)-\(range.upperBound ?? 99)") @unknown default: print( "fatalError()") return false } var ok = false if lowerBound >= 18 { // Not needed ? // Allow access to 18+ features. ok = true } else if lowerBound >= 15 { // Not needed ? // Allow access to 15+ features. ok = true } else if lowerBound >= 13 { // Not needed ? // Require parental consent ? // Allow access to 13+ features. ok = true // if consent OK } else { // Require parental consent ? // Show age-appropriate content ok = true // if consent OK } return ok // Authorized for all 4+ } catch { // AgeRangeService.Error.notAvailable { // No age range provided. return false } } func executeStart() { welcomeLabel.isHidden = false } @IBAction func start(_ sender: UIButton) { Task { @MainActor in if #available(iOS 26.0, *) { if await testAgeRange() { // Need to test for parental control here ? } else { // Alert and exit the app ? } } else { // do nothing ? Can we run the app ? } executeStart() } }
Topic: UI Frameworks SubTopic: UIKit Tags:
Dec ’25
Reply to [Texas SB 2420] How to Retrieve Parental Consent Status
@ jarrodlombardo-eventbase Thanks for the comment. Yes it is creating a real mess. @Paris X Pinkney Apple: describing what the API can do is useful but not enough. As expressed elsewhere, a detailed workflow is really needed, with an implementation example also. As well as explaining what to do if run on iOS < 26 ? In addition, after Determining whether a person using your app is in an applicable region that requires additional age-related obligations. can we just terminate the app to prevent its use ? Or would that cause a rejection on Appstore ?
Topic: App & System Services SubTopic: General Tags:
Dec ’25
Reply to Texas's SB 2420: obligations depending on app rating ?
@jarrodlombardo-eventbase Thanks for the reply. That seems at least a safe interpretation. But now the question is: if; from answers to questions on age rating, app is evaluated as suited for all public (4+), any verification will succeed, by construction. So what would be the purpose of asking for a verification that would always succeed ? Or is the law intended to allow parents to refuse consent in any case ? Question to Apple: Is it correct analysis ? Otherwise, how to exclude Texas from the available "countries", without excluding all US states ?
Dec ’25