Environment:
- SDK:
react-native-purchases^9.8.0 - Platform: iOS (Expo SDK 54, React Native 0.81.5)
- Testing on: TestFlight (physical iPhone + iPad)
- Bundle ID:
com.withim.app - API key prefix:
appl_
Products:
com.withim.app.grace_monthly1(Auto-Renewable, 1 month, 7-day free trial)com.withim.app.grace_annual1(Auto-Renewable, 1 year, 7-day free trial)com.withim.app.grace_lifetime1(Non-Consumable)- All 3 products are "Waiting for Review" in App Store Connect
- RevenueCat offerings configured:
$rc_monthly,$rc_annual,$rc_lifetime
Problem: When calling purchasePackage(), it immediately throws error code 16 (UNKNOWN_BACKEND_ERROR) with no readableErrorCode or underlyingErrorMessage. The native Apple payment sheet never appears.
What works:
getOfferings()returns correct products with real prices from Apple (e.g., $3.99/month displays correctly)Purchases.configure()succeedsPurchases.getCustomerInfo()works- Purchases work when running via Xcode debug build on physical device
What doesn't work:
- Any purchase attempt on TestFlight build — error 16, no payment sheet
- Tried all 3 products (monthly, annual, lifetime) — same error
Configuration verified:
- Paid Apps Agreement: Active
- App-Specific Shared Secret: Set in RevenueCat
- App Store Connect API Key (.p8): Configured in RevenueCat with correct Issuer ID and Key ID
- App Store Server Notifications v2: Configured (both production and sandbox URLs)
- Subscription group exists with localized display name
- All product metadata complete (names, descriptions, pricing, screenshots)
- Bundle ID matches across app.json, ASC, and RevenueCat
Attempted fixes (none worked):
- Added
usesStoreKit2IfAvailable: falsetoPurchases.configure()— same error - Added App-Specific Shared Secret to RevenueCat — same error
- Configured App Store Server Notifications v2 — same error
- Fresh native build via EAS Build (not just OTA update) — same error
Key diagnostic: RevenueCat dashboard > Customers > Sandbox shows 0 customers. The purchase request never reaches RevenueCat's backend. The error appears to be at the client SDK / StoreKit level before any server communication.
Question: What could cause error 16 with no payment sheet specifically on TestFlight builds, while Xcode debug builds work fine? Is there a known issue with StoreKit sandbox + TestFlight in react-native-purchases v9?
