According to Apple's documentation at https://developer.apple.com/documentation/storekit/testing-age-assurance-in-sandbox?language=objc, the testing steps and expected responses are outlined as follows:
Test app consent revocation
To test the notification when a parent or guardian revokes access to your app on behalf of their child, follow these steps:
Start with a Sandbox account.
From the Age Assurance settings, tap Revoke App Consent.
Enter your app’s Bundle ID (for example, com.example.bundle).
Tap Revoke Consent to simulate the revocation.
Confirm that the system displays “Notification Triggered” with the message “A notification will be sent to the developer server soon.”
I followed the steps exactly as described above, but during the fifth step, instead of seeing the prompt "A notification will be sent to the developer server soon," a pop-up dialog with only a confirmation button appeared. After clicking it, there was no further response, and our server did not receive any notification (neither from the Sandbox nor the Production environment).
Declared Age Range
RSS for tagFor creating age-appropriate experiences in your app by asking people to share their age range.
Posts under Declared Age Range tag
24 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
The published "Next steps for apps distributed in Texas" says "A parent or guardian in Texas can withdraw consent for any app, which will block launching of the app on the child or teen’s device."
My question is: will this also block notifications sent to that app from showing up on that device? Or will notifications still be delivered to the notification center, even though the app can't be launched? (Specifically, notifications sent from a server via Firebase topic/token).
If notifications are not blocked automatically, what is the expected flow for this scenario? My app sends notifications from a server like this.
I could implement client-side code to say "if consent is revoked, unsubscribe from notifications", but if the OS blocks launching of the app, this client-side code would never run.
Similarly, I could subscribe to the server notifications for when consent is revoked, but my app is free & accountless, so I'm not aware of any information in the server notification that I could use to identify the specific user whose notifications should be stopped. (For example my users won't have an appAccountToken because they never made a purchase).
Guidance would be much appreciated. I'm trying to comply with the law but I don't know how.
Hi everyone.
I've downloaded the the 26.2 beta 2 and installed it on a device in the settings after i create a new sandbox test account i see the options in Age Assurance.
The problem is i got the popup the first time i opened the application and decided to share, but after that i always get the following error:
DeclaredAgeRange.AgeRangeService.Error.notAvailable
I tried testing with different bundle id and different sandbox test account but still it doesn't work.
How can i test the cases without erasing the device ?
Like any good developer, I try to add tests where I can. The AgeRangeService.AgeRange type does not provide an initializer. I know the routine, create an interface or a simple struct that I control and use that instead. Thanks to extensive time with frameworks like Core Bluetooth or Core Location, this is a well understood practice (looking at you CBPeripheral...).
Great I'll make my own 'AgeRange' struct. Make it Hashable, make it Sendable, use the framework types as properties. Scratch that, most of the properties on AgeRangeService.AgeRange type are not Sendable and many are also not Hashable. This is proving to be challenging.
I hope to open source my little Swift Package wrapper library for DeclaredAgeRange which will add types with full Hashable and Sendable conformance. I hope Apple updates the API and makes this obsolete. I don't see why these simple types can't be Hashable and Sendable. They're structs, enums, and OptionSets (structs).
FB20959748 - DeclaredAgeRange: DeclaredAgeRangeAction is not sendable causing main actor compile errors with default isolation settings
FB20960560 - DeclaredAgeRange: AgeRangeService.AgeRangeDeclaration is not sendable as expected
FB20960574 - DeclaredAgeRange: AgeRangeService.ParentalControls is not sendable as expected
FB20960590 - DeclaredAgeRange: AgeRangeService.ParentalControls is not hashable as expected
On the note of the library and using the types as-is, there are some issues using the new cases in AgeRangeDeclaration and the isEligibelForAgeFeatures property. I started another thread over here: https://developer.apple.com/forums/thread/808144
Topic:
App Store Distribution & Marketing
SubTopic:
General
Tags:
Swift
Beta
Testing
Declared Age Range