anonymous_user_id
for the user. This anonymous_id
remains consistent as long as the user keeps the app on its device.anonymous_user_id
anonymous_user_id
is sent on the webhookanonymous_user_id
and the Product & Plan purchased must be stored in the developer database.anonymous_user_id
from the SDK and check with the database that the user can access the content / service.UserId
has been attached to the user by the app to Purchasely SDK, the user will be treated as an anonymous user.anonymous_user_id
for the user. This anonymous_user_id
is tied to this particular device and remains consistent as long as the app remains installed on the device and will be the key for your backend to authorize the purchase on the device.anonymous_user_id
generated by Purchasely.anonymous_user_id
.anonymous_user_id
. In other words, when a particular event (renewal / cancellation / expiration etc...) happens on an anonymous user subscription, it will carry the same anonymous_user_id
.anonymous_user_id
. The app can retrieve the anonymous_user_id
from the SDK vy using the following method :anonymous_user_id
and user_id
inside your app (e.g. in the section "My Subscriptions", in the settings or in the contact-us mail). This will help you identify the user in the Purchasely Console or in your own logs.appUserId
. If your user had a subscription we will transfer it to the connected user. That implies sending events to your backend and wait for it to confirm before you try to refresh your entitlements. This is why you have a closure that passes a boolean telling you if the entitlements of the logged in user should be refreshed.Purchasely.userLogin("YOUR_USER_ID")
before returning the result to Purchasely to properly update the presentation without the sign-in button.ACTIVATE
for the connected user and a DEACTIVATE
for the anonymous user. The webhook and integratiosn you activated will also receive 2 events, a SUBSCRIPTION_RECEIVED
for the connected user and a SUBSCRIPTION_TRANSFERRED
for the anonymous user.Purchasely.userLogin()
see SDK configuration for more information.isLoggedIn
closure with true
isLoggedIn
closure with false
Purchasely.userLogin("YOUR_USER_ID")
before returning the result to Purchasely to properly update the presentation without the sign-in button.