Appflow.ai
Visit our websitePricingSign up for freeLog in
  • GET STARTED
    • What is Appflow.ai?
    • Quickstart - How to start working with Appflow.ai?
    • FAQ
    • Ownership and other roles
  • SDK Set-up Instructions
    • Android SDK
      • Google Play Store Credentials
        • Google Service Account Key
        • Google real-time developer notifications(RTDN)
        • FCM server key(optional)(to be updated)
      • Events (Custom events)
      • Purchases
      • Visual constructor
      • User info
      • Push notifications
    • iOS SDK
      • Specify Apple Store Keys
      • Purchases and User Info
      • Event tracking (Custom events)
      • Push Notifications Configuration
      • Visual constructor
  • IN-APP PURCHASE
    • SKU adding
  • METRICS & EVENTS
    • Calculations of Analytics
    • Terms and Descriptions
    • Purchase Events
    • In-app Events
    • Events Structure
    • End-users Attributes
    • Users' statuses
  • SUBSCRIPTION ANALYTICS
    • Dashboard
    • Configurator
    • Reports
    • A/B Testing
    • Integrations
    • Create Push-notifications
    • In-app Messages
    • Return of Advertisement
    • Funnels
    • Funnel 2.0 BETA
    • Entitlements
    • Visual Constructor
  • INTEGRATIONS
    • Adjust
    • Appsflyer
    • Mixpanel
    • Webhooks
    • Apple Search Ads Attributions
    • Branch
    • Amplitude
  • OTHERS
    • Pricing plans and important information about your payments
    • Storing your data
    • Privacy Policy
    • Terms of Use
    • Unsubscribe from Appflow.ai
Powered by GitBook
On this page

Was this helpful?

  1. SUBSCRIPTION ANALYTICS

Entitlements

Entitle your users with remote configuration control

PreviousFunnel 2.0 BETANextVisual Constructor

Last updated 1 year ago

Was this helpful?


Appflow.ai only links your entitlements with your SKU, you should know the id of your entitlements yourself

To create entitlement, go to Appflow.ai Settings => Entitlements => Add new

That's it! Your entitlements will be related to your new SKU choice right away!

You can create same entitlements with the same ids but

You can't assign same ids to the same apps'SKUs

Example of how to make entitlements work through Appflow.ai:

If you make an entitlement call 'Remove Ads'

And then you link it to SKU

The value in 'Name / Identifier', will be returned if a user purchases one of the SKU in the 'Linked to SKU' and doesn't expire.

Then you ask your developer/or do yourself: to put to the SDK:

Android:

Appflow.getSubscriberInfo(object : ReceivePurchaserInfoListener {
    override fun onReceived(subscriber: IapIap.Subscriber) {
        var canRemoveAds = false
        for (info in subscriber.entitlementsList) {
            if (info.id == "Remove Ads" && info.isActive) {
                canRemoveAds = true
                break
            }
        }
    }

    override fun onError(error: PurchasesError) {}
})

iOS

Appflow.shared.restorePurchases {[weak self] subscriber, error in  
   var canRemoveAds = false  
   for imEntitlement in subscriber.imEntitlements where (imEntitlement.id == "Remove Ads" && imEntitlement.isActive == true) {  
      canRemoveAds = true  
      break  
   }  
}