UID2 Endpoints
All UID2 endpoints require a client secret for encrypting API requests (except POST /token/refresh requests) and decrypting responses. For details and Python script examples, see Encrypting Requests and Decrypting Responses.
UID2 Tokens
The following endpoints are for retrieving and managing UID2 tokens (identity tokens, advertising tokens), and are used mainly by publishers.
Endpoint | Description | Request Encryption | Response Decryption |
---|---|---|---|
POST /token/generate | Requests a UID2 token from an email address or phone number provided by a user with their authorization for UID2-based targeted advertising. If the DII is valid, and the user has not opted out of UID2, this operation returns a UID2 token and associated values. | Required | Required |
POST /token/validate | Used for testing, to validate that an advertising token (UID2) matches the specified email address, phone number, or the respective hash. | Required | Required |
POST /token/refresh | Generate a new token for a user for their refresh token from the POST /token/generate response. | N/A | Required |
Identity Maps
The following endpoints are used by advertisers and third-party data providers. Publishers do not need to use these endpoints.
Endpoint | Description | Request Encryption | Response Decryption |
---|---|---|---|
POST /identity/buckets | Monitor rotated salt buckets using their last updated timestamp. | Required | Required |
POST /identity/map | Retrieve UID2s and salt bucket IDs for one or more email addresses, phone numbers, or their respective hashes. | Required | Required |