Skip to main content

Fetching Entitlements

When you want to bring the entitlements defined to the user's products, you can bring it with SDK's getEntitlements method. Entitlements allow app owners to determine what rights the app user has acquired through product purchases. Entitlements are returned only for purchased products. All purchased consumable, non-consumable and subscription entitlements defined for your products from this API It returns the response.

note

The aim of this feature is to create a mapping scheme that will developers to define their paid features with Appmate. This will allow them to map their products to their paid features, effectively allowing product management without additional development effort.

Request#

Parameter NameType
completion[String]?, GenericError?) -> Void

Response#

Parameter NameType
entilements[String]
errorGenericError?
PurchaseClient.shared.getProducts { products, error in    PurchaseClient.shared.getEntitlements { entilements, error in            if let entilements = entilements {                print(entilements)            } else {                print(error?.description)            }      }}
[[PurchaseClient shared] getEntitlementsWithCompletion:^(NSArray<NSString *> * entilements, GenericError * error) {        if (entilements != nil) {            NSLog(@"%@", entilements);        } else {            NSLog(@"%@", error.description);        }    }];