Expose user profiles stored in your Redis instance over an API.
6 minute read
With RudderStack’s Activation API, you can fetch enriched user traits stored in your Redis instance and use them for near real-time personalization for your target audience.
You can sync all your customer 360 data from Profiles project to your Redis store. Then, use the Activation API endpoints to retrieve and use the enriched user data for personalization.
Prerequisites
You must have a working Redis instance in place to use this API.
Use Activation API
For the warehouse used for your Profiles project, create the RudderStack schema and grant permissions to it. Refer to the detailed steps for each warehouse:
{"entity":<entity_type>,// User, project, account, etc.
"destinationId":<redis_destination_id>,// Redis destination ID
"id":{"type":<id_type>,"value":<id_value>}}
Sample request
POST/v2/activationHTTP/1.1Host:profiles.rudderstack.comContent-Type:application/jsonAuthorization:Bearer <personal_access_token>Content-Length:90{"entity":<entity_type>,"destinationId":<redis_destination_id>,// Redis destination ID
"id":{"type":<id_type>,"value":<id_value>}}
statusCode:400Response:{"message":"id should have at least one item"}
statusCode:200Response:{"message":"Internal server error"}
Use case
You can use the Activation API for real-time personalization. Once you fetch the user traits from your Redis instance via the API, you can pull them into your client application to alter the application behavior in real-time based on user interactions.
You can respond immediately with triggered, user-focused messaging based on actions like page views or app clicks and provide a better customer experience.
Redis configuration
You must have a working Redis instance in place before setting up the connection.
Address: Enter the public endpoint of your Redis database. If you are using Redis Cloud, you can find this endpoint by going to your Redis database and navigating to Configuration tab > General.
Password: Enter the database password. You can find it in the Security section of the Configuration tab:
Cluster Mode: Turn on this setting if you’re connecting to a Redis cluster.
Secure: Enable this setting to secure the TLS communication between RudderStack Redis client and your Redis server.
Data mapping
RudderStack creates multiple Reverse ETL sources automatically based on your Profiles project. You will see separate sources connected to the same Redis destination.
The following pb_project.yaml snippet shows the sources to be created:
entities:- name:userid_types:- main_id- user_id- email- salesforce_idfeature_views:using_ids:- id:emailname:features_by_email# Optional. Takes default view name, if not specified.- id:salesforce_idname:salesforce_id_stitched_features
FAQ
How do I generate a personal access token to use the Activation API?
Does RudderStack perform a full sync if I add a new feature to my project?
Yes, RudderStack updates the mappings and automatically sends all columns from the customer 360 view by triggering a full sync.
Suppose I’m running a full sync and the Profiles job is running in parallel and finishes eventually. What happens to the scheduled sync? Does it get queued?
RudderStack first creates a temporary snapshot copy of any sync when it starts. So its syncing the created copy. Even if a Profiles job is running in parallel, the sync - if started - is not impacted by it.
This site uses cookies to improve your experience while you navigate through the website. Out of
these
cookies, the cookies that are categorized as necessary are stored on your browser as they are as
essential
for the working of basic functionalities of the website. We also use third-party cookies that
help
us
analyze and understand how you use this website. These cookies will be stored in your browser
only
with
your
consent. You also have the option to opt-out of these cookies. But opting out of some of these
cookies
may
have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This
category only includes cookies that ensures basic functionalities and security
features of the website. These cookies do not store any personal information.
This site uses cookies to improve your experience. If you want to
learn more about cookies and why we use them, visit our cookie
policy. We'll assume you're ok with this, but you can opt-out if you wish Cookie Settings.