The Cello Referral Component contains sensitive data such as the identity of the referee, amounts of payouts and details regarding your user’s referral flow e.g. notifications.
We use JWT (JSON Web token) to authenticate the user and authorize access to the data in the Referral Component.The expected flow is as follows:
User logs into your system.
Your backend provides your frontend code with a Cello JWT token.
Your frontend code initializes the Referral Component with the token.
Cello requires a productUserId - a unique user identifier to be passed when initializing the Referral Component.This can be a user id that you already use to identify users in your product.
It can also be any other new unique identifier you generate - the main requirement is that it is unique per user accross your application.
It is important that this ID is unique per user, rather than organisation.