Error: RevenueCat SDK cannot fetch products from StoreKit Configuration file, even though the file is properly configured and set in Xcode scheme.
Current Setup
- Platform: iOS (Flutter app)
- RevenueCat SDK: `purchases_flutter: ^8.11.0`
- API Key: Test Store API key (`test_###`)
- StoreKit Configuration: `Products.storekit` file exists with products `premium_monthly_1` and `premium_yearly_1`
- RevenueCat Configuration:
- Offering: `default`
- Products: `premium_monthly_1`, `premium_yearly_1`
- Entitlement: `premium`
- Package identifiers: `$rc_annual`, `$rc_monthly`
Error Message
ERROR: 🍎‼️ Error fetching offerings - The operation couldn't be completed. (RevenueCat.OfferingsManager.Error error 1.)
There's a problem with your configuration. None of the products registered in the RevenueCat dashboard could be fetched from App Store Connect (or the StoreKit Configuration file if one is being used).
Debug logs show:
DEBUG: ℹ️ No existing products cached, starting store products request for: ["premium_monthly_1", "premium_yearly_1"]
DEBUG: 😻 Store products request received response
DEBUG: ℹ️ Store products request finished
ERROR: 🍎‼️ Error fetching offerings
What We've Verified
✅ StoreKit Configuration file (`Products.storekit`) exists and is valid JSON
✅ Products in file match RevenueCat dashboard: `premium_monthly_1`, `premium_yearly_1`
✅ File is added to Xcode project (visible in Project Navigator)
✅ File is set in Xcode scheme: Product → Scheme → Edit Scheme → Run → Options → StoreKit Configuration = `Products.storekit`
✅ Running in Debug mode (not Release)
✅ CocoaPods dependencies are synced (`pod install` completed)
✅ Clean builds performed multiple times
✅ Test products exist in RevenueCat Test Store dashboard
StoreKit Configuration File
json
{
"identifier": "Products",
"products": [
{
"identifier": "premium_monthly_1",
"productID": "premium_monthly_1",
"type": "SUBSCRIPTION",
"displayPrice": "4.99",
"localizations": [{
"locale": "en_US",
"displayName": "ContentGenius Premium Monthly",
"description": "Monthly subscription to ContentGenius Premium"
}]
},
{
"identifier": "premium_yearly_1",
"productID": "premium_yearly_1",
"type": "SUBSCRIPTION",
"displayPrice": "49.99",
"localizations": [{
"locale": "en_US",
"displayName": "ContentGenius Premium Yearly",
"description": "Yearly subscription to ContentGenius Premium"
}]
}
],
"subscriptionGroups": [{
"id": "21482014",
"name": "Premium",
"subscriptions": ["premium_monthly_1", "premium_yearly_1"]
}]
}
Question
Is it possible to use RevenueCat Test Store API key (`test_` prefix) with StoreKit Configuration files?
The error suggests StoreKit is trying to fetch products but returning empty. We suspect:
1. Test Store API key might not work with StoreKit Configuration files
2. StoreKit Configuration might require iOS public API key (`appl_` prefix) instead
Should we:
- Use Test Store API key WITHOUT StoreKit Configuration (set to "None" in scheme)?
- OR use StoreKit Configuration WITH iOS public API key (`appl_`)?
