You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/endpoints/post-token-generate.md
+7-16Lines changed: 7 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,11 +15,7 @@ Requests a UID2 token generated from a user's <Link href="../ref-info/glossary-u
15
15
16
16
Used by: This endpoint is used mainly by publishers.
17
17
18
-
:::important
19
-
The `optout_check` parameter, required with a value of `1`, checks whether the user has opted out.
20
-
:::
21
-
22
-
<!-- uid2_euid_diff re legal basis for admonition above -->
18
+
<!-- uid2_euid_diff: admonition re legal basis (in EUID not in UID2)-->
23
19
24
20
Rather than calling this endpoint directly, you could use one of the SDKs to manage it for you. For a summary of options, see [SDKs: Summary](../sdks/summary-sdks.md).
25
21
@@ -46,7 +42,7 @@ Here's what you need to know about sending requests to this endpoint:
46
42
### Unencrypted JSON Body Parameters
47
43
48
44
:::important
49
-
You must include only **one** of the following four conditional parameters, plus the required `optout_check` parameter with a value of `1`, as key-value pairs in the JSON body of the request when encrypting it.
45
+
You must include only **one** of the following four conditional parameters as key-value pairs in the JSON body of the request when encrypting it.
50
46
:::
51
47
52
48
| Body Parameter | Data Type | Attribute | Description |
@@ -55,7 +51,6 @@ You must include only **one** of the following four conditional parameters, plus
55
51
|`email_hash`| string | Conditionally Required | The [Base64-encoded SHA-256](../getting-started/gs-normalization-encoding.md#email-address-hash-encoding) hash of a [normalized](../getting-started/gs-normalization-encoding.md#email-address-normalization) email address. |
56
52
|`phone`| string | Conditionally Required | The [normalized](../getting-started/gs-normalization-encoding.md#phone-number-normalization) phone number for which to generate tokens. |
57
53
|`phone_hash`| string | Conditionally Required | The [Base64-encoded SHA-256](../getting-started/gs-normalization-encoding.md#phone-number-hash-encoding) hash of a [normalized](../getting-started/gs-normalization-encoding.md#phone-number-normalization) phone number. |
58
-
|`optout_check`| number | Required | Checks whether the user has opted out. Include this parameter with a value of `1`.|
59
54
60
55
### Request Examples
61
56
@@ -67,33 +62,29 @@ The following are unencrypted JSON request body examples for each parameter, one
For details, and code examples in different programming languages, see [Encrypting Requests and Decrypting Responses](../getting-started/gs-encryption-decryption.md).
Copy file name to clipboardExpand all lines: docs/getting-started/gs-encryption-decryption.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -114,7 +114,7 @@ This section includes encryption and decryption code examples in different progr
114
114
For the [POST /token/refresh](../endpoints/post-token-refresh.md) endpoint, the code takes the values for `refresh_token` and `refresh_response_key` that were obtained from a prior call to [POST /token/generate](../endpoints/post-token-generate.md) or [POST /token/refresh](../endpoints/post-token-refresh.md).
115
115
116
116
:::note
117
-
For Windows, if you're using Windows Command Prompt instead of PowerShell, you must also remove the single quotes surrounding the JSON. For example, use `echo {"email": "test@example.com", "optout_check": 1}`.
117
+
For Windows, if you're using Windows Command Prompt instead of PowerShell, you must also remove the single quotes surrounding the JSON. For example, use `echo {"email": "test@example.com"}`.
echo '<json>' | go run uid2_request.go <url> <api_key> <client_secret>
811
811
812
812
Example:
813
-
echo '{"email": "test@example.com", "optout_check": 1}' | go run uid2_request.go https://prod.uidapi.com/v2/token/generate UID2-C-L-999-fCXrMM.fsR3mDqAXELtWWMS+xG1s7RdgRTMqdOH2qaAo= wJ0hP19QU4hmpB64Y3fV2dAed8t/mupw3sjN5jNRFzg=
814
-
813
+
echo '{"email": "test@example.com"}' | go run uid2_request.go https://prod.uidapi.com/v2/token/generate UID2-C-L-999-fCXrMM.fsR3mDqAXELtWWMS+xG1s7RdgRTMqdOH2qaAo= wJ0hP19QU4hmpB64Y3fV2dAed8t/mupw3sjN5jNRFzg=
814
+
815
815
816
816
Refresh Token Usage:
817
817
go run uid2_request.go <url> --refresh-token <refresh_token> <refresh_response_key>
Copy file name to clipboardExpand all lines: docs/getting-started/gs-faqs.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -92,7 +92,7 @@ No, publishers do not need to decrypt <Link href="../ref-info/glossary-uid#gl-ui
92
92
#### How will I be notified of user opt-out?
93
93
94
94
If the user has opted out, the API response notifies you in either of these cases:
95
-
- When you generate the UID2 token by a call to the [POST /token/generate](../endpoints/post-token-generate.md) endpoint, either directly or via one of the UID2 SDKs, using the required `optout_check` parameter with a value of `1`.
95
+
- When you generate the UID2 token by a call to the [POST /token/generate](../endpoints/post-token-generate.md) endpoint, either directly or via one of the UID2 SDKs.
96
96
- When you refresh the UID2 token by a call to the [POST /token/refresh](../endpoints/post-token-refresh.md) endpoint, either directly or via one of the UID2 SDKs.
97
97
98
98
#### Where should I make token generation calls—from the server side or the client side?
Copy file name to clipboardExpand all lines: docs/getting-started/gs-opt-out.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ The following steps provide a high-level outline of the opt-out workflow intende
48
48
49
49
| Participant | Distribution Method |
50
50
| :--- | :--- |
51
-
| Publishers | A publisher calling [POST /token/generate](../endpoints/post-token-generate.md) with the required `optout_check` parameter set to `1`, or [POST /token/refresh](../endpoints/post-token-refresh.md), receives the opt-out response instead of the UID2 token. |
51
+
| Publishers | A publisher calling [POST /token/generate](../endpoints/post-token-generate.md), or [POST /token/refresh](../endpoints/post-token-refresh.md), receives the opt-out response instead of the UID2 token. |
52
52
| DSPs | The UID2 Operator Service distributes information on all opted-out users to DSPs via a webhook provided for the purpose. For details, see [Honor User Opt-Outs](../guides/dsp-guide#honor-user-opt-outs).<br/>DSPs can also check the opt-out status of raw UID2s using the [POST /optout/status](../endpoints/post-optout-status.md) endpoint. |
53
53
| Advertisers and data providers | The UID2 Operator Service distributes opt-out information to advertisers and data providers via the [POST /identity/map](../endpoints/post-identity-map.md) endpoint. Another option is to check the opt-out status of raw UID2s using the [POST /optout/status](../endpoints/post-optout-status.md) endpoint. |
54
54
| Sharers | UID2 sharers can check the opt-out status of raw UID2s using the [POST /optout/status](../endpoints/post-optout-status.md) endpoint. |
The `optout_check` parameter has been removed from the [POST /token/generate](../endpoints/post-token-generate.md) endpoint. Opt-out checks are now handled automatically so publishers no longer need to include this parameter in their requests.
34
+
35
+
Related SDK functions have also been deprecated and removed from documentation:
Copy file name to clipboardExpand all lines: docs/sdks/sdk-ref-java.md
+4-15Lines changed: 4 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -147,16 +147,10 @@ If you're using the SDK's HTTP implementation, follow these steps.
147
147
148
148
2. Call a function that takes the user's email address or phone number as input and generates a `TokenGenerateResponse` object. The following example uses an email address:
<!-- - Be sure to call the POST /token/generate endpoint only when you have a legal basis to convert the user’s <Link href="../ref-info/glossary-uid#gl-dii">directly identifying information (DII)</Link> to UID2 tokens for targeted advertising.
155
-
156
-
- --> Always apply `doNotGenerateTokensForOptedOut()`. This applies a parameter similar to setting `optout_check=1` in the call to the POST /token/generate endpoint (see [Unencrypted JSON Body Parameters](../endpoints/post-token-generate.md#unencrypted-json-body-parameters)).
157
-
:::
158
-
159
-
<!-- uid2_euid_diff re legal basis for admonition above (first bullet not in UID2) -->
153
+
<!-- uid2_euid_diff: admonition re legal basis (in EUID not in UID2)-->
160
154
161
155
#### Basic Usage, Client-Server Integration
162
156
@@ -224,21 +218,16 @@ If you're using server-side integration (see [Publisher Integration Guide, Serve
224
218
2.Call a function that takes the user's email address or phone number as input and creates a secure request data envelope. See [Encrypting requests](../getting-started/gs-encryption-decryption.md#encrypting-requests). The following example uses an email address:
3. Using an HTTP client library of your choice, post this envelope to the [POST token/generate](../endpoints/post-token-generate.md) endpoint, including headers and body:
230
224
1. Headers: Depending on your HTTP library, this might look something like the following:
<!-- - Be sure to call the POST /token/generate endpoint only when you have a legal basis to convert the user’s <Link href="../ref-info/glossary-uid#gl-dii">directly identifying information (DII)</Link> to UID2 tokens for targeted advertising.
237
-
238
-
- --> Always apply `doNotGenerateTokensForOptedOut()`. This applies a parameter similar to setting `optout_check=1` in the call to the POST /token/generate endpoint (see [Unencrypted JSON Body Parameters](../endpoints/post-token-generate.md#unencrypted-json-body-parameters)).
239
-
:::
240
229
241
-
<!-- uid2_euid_diffre legal basis for admonition above (first bullet not in UID2)-->
230
+
<!-- uid2_euid_diff: admonition re legal basis (in EUID not in UID2)-->
242
231
243
232
4. If the HTTP response status code is _not_ 200, see [Response Status Codes](../endpoints/post-token-generate.md#response-status-codes) to determine next steps. Otherwise, convert the UID2 identity response content into a `TokenGenerateResponse` object:
Copy file name to clipboardExpand all lines: docs/sdks/sdk-ref-python.md
+2-8Lines changed: 2 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -158,16 +158,10 @@ Decryption response codes, and their meanings, are shown in the following table.
158
158
2. Call a function that takes the user's email address or phone number as input and generates a `TokenGenerateResponse` object. The following example uses an email address:
Be sure to call this function only when you have a legal basis to convert the user’s <Link href="../ref-info/glossary-uid#gl-dii">directly identifying information (DII)</Link> to UID2 tokens for targeted advertising.
166
-
:::
167
-
168
-
<!-- uid2_euid_diff re legal basis for admonition above (not in UID2) -->
169
-
170
-
`do_not_generate_tokens_for_opted_out()` applies `optout_check=1` in the [POST /token/generate](../endpoints/post-token-generate.md) call. Without this, `optout_check` is omitted to maintain backwards compatibility.
164
+
<!-- uid2_euid_diff: admonition re legal basis (in EUID not in UID2)-->
0 commit comments