When taking advantage of the Triple White Label UI, it is necessary to authenticate the end user (customer) with Triple in order for the platform provide adequate targeting & personalization, and to track offer activations.
As a Publisher you will have to implement the following flow to be executed when a customer is passed to the Triple White Label UI.
You will have to request a Triple Partner Token using the specific client_id and client_secret provided by Triple.
You can obtain a Triple Partner Token by making a x-www-form-urlencoded POST request to either:
The complete procedure is detailed in the Getting Started Overview - Step 1: Perform Authentication section.
After obtaining the Triple Partner Token, you will have to create a session token specific to the user.
You can obtain the User Session Token by making a POST request to either:
- Production: https://ui-api.tripleup.dev/initiate-session
- token_expiry_duration: Duration the user session token is valid for. The default and maximum value is 60 minutes
- default_postal_code: The postal code to use for offers localization if location services are unavailable/not granted
The response from /initiate-session contains the property redirectUrl. Using the content of redirectUrl is enough to direct and authenticate the user with the Triple White Label UI.
It is worth noting that the token expiry is based on the token's creation time. If the token is pre-generated with a token_expiry_duration: 20 and embedded within an existing page but the user doesn't interact with the link for 15 minutes, the user session will expire after only 300 seconds/5 minutes. It is recommended to either leave the token_expiry_duration to its default and maximum values of 60 minutes or to generate the token when a user clicks on the redirection to the Triple White Label UI.