In this article
We will cover the prerequisites and steps to send hashed-emails into Permutive for user matching in our Vaults.
Overview
You have the ability to import SHA256 Hashes email addresses to Permutive for the purpose of user matching in Vaults. Described below are the several ways to share these emails with Permutive.
Prerequisites
- You are currently collecting email addresses on your site. This can be an email collected for a newsletter, for registration purposes, etc.
- Permutive’s SDK is actively running on the location where the emails are being collected.
- Your technical teams have the ability to interact with the Permutive SDK
- Your technical teams have the ability to clean and transform an email address into a secure SHA256 hashed version.
Sending Hashed Emails Client-Side
- You will need to make a modification to your deployment to capture the email submission and share this with Permutive.
- When a user provides an email address on your page, you should call the following snippet:
window.permutive.identify([
{ "id": "<HASHED EMAIL>",
"tag": "email_sha256" }
]);
- You will need to replace
<HASHED EMAIL>
with the user's hashed email address. - The email address has to be hashed with a SHA256 algorithm.
- Please make sure to trim and lowercase the email address before hashing it. If an email hash is not available for the current user, you should omit the
permutive.identify()
call. - This will create a mapping of the user's hashed email to a Permutive ID.
Sending Hashed Emails Server-Side
If you do not have the ability to make hashed email addresses available client-side, you will have the ability to send it server-side via an API call.
Prerequisites
- You have access to the email addresses shared by the user.
- You have access to the Permutive ID server-side.
- You have the ability to clean and transform an email address into a secure SHA256 hashed version.
- You have the ability to make a server-side API call with the above-described information.
- You can use the following API call to share this information server-side.
To link a hashed email to a Permutive ID, you need to make an API request like the following:
curl -XPOST https://api.permutive.com/v2.0/identify \
-H 'X-API-Key: <PRIVATE API KEY>' \
-H 'Content-Type: application/json' \
-d '{
"user_id": "<PERMUTIVE USER ID>",
"aliases": [
{
"id": "<HASHED EMAIL>",
"tag": "email_sha256",
"priority":0 }
]
}'
- <Private_API_Key>: You must use a private API key, which you can find/create here: https://dash.permutive.com/settings/keys/
- <HASHED EMAIL>: This should be replaced with your hashed email.
- The email address has to be hashed with a SHA256 algorithm
- Please make sure to trim and lowercase the email address before hashing it. If an email hash is not available for the current user, omit the permutive.identify function call.
- <PERMUTIVE USER ID>: Please replace
<PERMUTIVE USER ID>
with your Permutive User ID.- You should read your Permutive user ID from the first-party cookie called 'permutive-id' at the point your server receives the page request.
This API call will respond with the user's Permutive ID Eg.
{ "user_id": "682511a8-2ef4-4e84-b8b2-d7d9c0023477" }
Please find more details on this endpoint here. You will be able to find your password in the Permutive UI.
Please let Permutive know when you have completed the above steps so we can verify the deployment.
Important: For privacy reasons, we do not use hashed emails for cross-site identification.
Comments
0 comments
Article is closed for comments.