You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling GetPurchasesAsync(ItemType.Subscription) on iOS, the system prompts for Apple ID credentials. This does not happen in other apps, and I would like to understand if this is expected behavior or if there is a way to avoid it.
var billing = CrossInAppBilling.Current;
try
{
//You must connect
var connected = await billing.ConnectAsync().ConfigureAwait(false);
if (!connected)
{
//Couldn't connect
return [];
}
var myPuschaes = await billing.GetPurchasesAsync(ItemType.Subscription).ConfigureAwait(false);
var myProducts = await billing.GetProductInfoAsync(ItemType.Subscription, _productIds).ConfigureAwait(false);
return myProducts.Select(x => new SubscriptionItem()
{
Product = x,
IsSubscribed = myPuschaes.Where(y => y.ProductId == x.ProductId).Any(),
});
Is this the correct way to check for active subscriptions?
Should I rely on my own database instead to avoid triggering this prompt?
Is there a way to prevent iOS from requesting credentials?
Would appreciate any insights on whether this is expected behavior or if there’s a workaround.
Thanks!
The text was updated successfully, but these errors were encountered:
When calling GetPurchasesAsync(ItemType.Subscription) on iOS, the system prompts for Apple ID credentials. This does not happen in other apps, and I would like to understand if this is expected behavior or if there is a way to avoid it.
Is this the correct way to check for active subscriptions?
Should I rely on my own database instead to avoid triggering this prompt?
Is there a way to prevent iOS from requesting credentials?
Would appreciate any insights on whether this is expected behavior or if there’s a workaround.
Thanks!
The text was updated successfully, but these errors were encountered: