User identifiers association

This document import allows you to merge user points by associating their user identifiers. Each line in the document represents a different user identifiers association

This is only supported for datamarts using a user point system version of v201812 or later.


  1. Use the bulk import endpoints to create a document import with theUSER_IDENTIFIERS_ASSOCIATION_DECLARATIONSdocument type and APPLICATION_X_NDJSON mime type. Only ndjson data is supported for user activities.

  2. Create an execution with your commands formatted in ndjson .

User identifiers association command

Each line will create/merge a user point that has all the specified identifiers

User identifier resource can be of three shapes. Either email or user agent or user account id. They correspond with the different types of user identifiers.


User Agent

User Account


# Create the document import
curl -X POST \<DATAMART_ID>/document_imports \
  -H 'Authorization: <YOUR_API_TOKEN>' \
  -H 'Content-Type: application/json' \
  -d '{
	"mime_type": "APPLICATION_X_NDJSON",
	"encoding": "utf-8",
# Create the execution
curl -X POST \<DOCUMENT_IMPORT_ID>/executions \
  -H 'Authorization: <API_TOKEN>' \
  -H 'Content-Type: application/x-ndjson' \
  -d '
        { "type": "USER_EMAIL", "hash":"<EMAIL_HASH>" }, 
        { "type": "USER_AGENT", "user_agent_id": "<USER_AGENT_ID>" }, 
        { "type": "USER_ACCOUNT", "user_account_id": "<USER_ACCOUNT_ID>",  "compartment_id": "<COMPARTMENT_ID>" }

You can, of course, add different identifier types at the same time. Please note that the uploaded data is in ndjson and not json. That means the different additions are not separated by commas, but by a line separator \n

Last updated