diff --git a/README.md b/README.md index 9334c49..4c3172c 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,7 @@ Python SDK for integrating Databricks with The Trade Desk Data API. Supports Fir - [SDK Example Usage](#sdk-example-usage) - [Authentication](#authentication) - [Supported Data API Endpoints](#supported-data-api-endpoints) +- [UID2 Support](#uid2-support) - [Error Handling](#error-handling) - [Server Selection](#server-selection) - [Custom HTTP Client](#custom-http-client) @@ -365,6 +366,16 @@ validate_ttd_schema(df=input_df, endpoint=TTDEndpoint.ADVERTISER) --- +## UID2 Support + +The SDK supports both submitting UID2s directly as identifiers as well as automatically resolving raw email addresses and phone numbers (including pre-hashed variants) to UID2s before sending to The Trade Desk Data API. To enable automatic resolution, pass a `uid2_config` to `TtdDatabricksClient.from_params()`. + +Email addresses and phone numbers can be submitted similar to other data types and are resolved to UID2s using the provided UID2 operator before calling The Trade Desk Data API. The Trade Desk Data API only receives resolved UID2s, never raw emails or phone numbers. Resolution happens per row in both `push_data` and `batch_process`, with UID2 mapping returned in a `uid2_resolutions` column on the output. + +To submit email addresses or phone numbers, set the `id_type` column in your input data to `Email`, `Phone`, `HashedEmail`, or `HashedPhone`, with the corresponding value in `id_value`. + +--- + ## Error Handling All SDK exceptions inherit from `TTDError`. diff --git a/pyproject.toml b/pyproject.toml index 15cd74c..7082559 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "ttd-databricks" -version = "0.3.5" +version = "0.3.6" description = "Client implementation and helper functions for integrating with the TTD Databricks services." readme = "README.md" requires-python = ">=3.10"