Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ npm-debug.log*
yarn-debug.log*
yarn-error.log*
.aider*

# Temporary exclusion for Claude project 4/10/26
# md-sentence-case*
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ npm i

After you've checked out the repo (and whenever you pull in new changes) you should run this command to install any new packages.

## Local Development
## Local development

```
npm start
Expand All @@ -31,7 +31,7 @@ npm run build

This command generates static content into the `build` directory and can be served using any static contents hosting service.

## Build All Languages
## Build all languages

```
npm run build && npm run serve
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# UID2 Documentation
# UID2 documentation

> Note: The new location for viewing UID2 documentation content is on the Unified ID website: [Unified ID 2.0 Overview](https://unifiedid.com/docs/intro).

Expand All @@ -7,7 +7,7 @@ This repository contains all the content files and supporting site infrastructur
- English (US)
- Japanese

For information about build tools and about contributing to this repository, see [CONTRIBUTING.md](CONTRIBUTING.md).
For information about build tools and about contributing to this repository, see [Contributing.md](CONTRIBUTING.md).

## Adding custom tags

Expand Down
26 changes: 13 additions & 13 deletions docs/endpoints/post-identity-buckets.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,35 +12,35 @@ import Link from '@docusaurus/Link';

Monitors rotated <Link href="../ref-info/glossary-uid#gl-salt-bucket">salt buckets</Link>.

Used by: This endpoint is used mainly by advertisers and data providers. For details, see [Advertiser/Data Provider Integration Overview](../guides/integration-advertiser-dataprovider-overview.md).
Used by: This endpoint is used mainly by advertisers and data providers. For details, see [Advertiser/data provider integration overview](../guides/integration-advertiser-dataprovider-overview.md).

:::important
If you're using the latest version (v3) of `POST /v3/identity/map`, you don't need to use `POST /identity/buckets` at all. You only need to use it if you're using the earlier version (v2) of `POST /v2/identity/map`.

If you're using the v2 version, we recommend that you upgrade as soon as possible, to take advantage of improvements. For migration guidance, see [Migration from v2 Identity Map](post-identity-map.md#migration-from-v2-identity-map).
If you're using the v2 version, we recommend that you upgrade as soon as possible, to take advantage of improvements. For migration guidance, see [Migration from v2 identity map](post-identity-map.md#migration-from-v2-identity-map).
:::

## Request Format
## Request format

`POST '{environment}/v2/identity/buckets'`

For authentication details, see [Authentication and Authorization](../getting-started/gs-auth.md).
For authentication details, see [Authentication and authorization](../getting-started/gs-auth.md).

:::important
You must encrypt all requests using your secret. For details, and code examples in different programming languages, see [Encrypting Requests and Decrypting Responses](../getting-started/gs-encryption-decryption.md).
You must encrypt all requests using your secret. For details, and code examples in different programming languages, see [Encrypting requests and decrypting responses](../getting-started/gs-encryption-decryption.md).
:::

### Path Parameters
### Path parameters

| Path Parameter | Data Type | Attribute | Description |
| :--- | :--- | :--- | :--- |
| `{environment}` | string | Required | Testing (integration) environment: `https://operator-integ.uidapi.com`<br/>Production environment: The best choice depends on where your users are based. For information about how to choose the best URL for your use case, and a full list of valid base URLs, see [Environments](../getting-started/gs-environments.md). |

:::note
The integration environment and the production environment require different <Link href="../ref-info/glossary-uid#gl-api-key">API keys</Link>. For information about getting credentials for each environment, see [Getting Your Credentials](../getting-started/gs-credentials.md#getting-your-credentials).
The integration environment and the production environment require different <Link href="../ref-info/glossary-uid#gl-api-key">API keys</Link>. For information about getting credentials for each environment, see [Getting your credentials](../getting-started/gs-credentials.md#getting-your-credentials).
:::

### Unencrypted JSON Body Parameters
### Unencrypted JSON body parameters

:::important
You must include the following parameter as a key-value pair in the JSON body of a request when encrypting it.
Expand All @@ -50,7 +50,7 @@ You must include the following parameter as a key-value pair in the JSON body of
| :--- | :--- | :--- | :--- | :--- |
| `since_timestamp` | date-time or integer | Required | Specify the date and time to which to compare the last updated UTC timestamps of the buckets to be returned. | ISO 8601 format:<br/>`YYYY-MM-DDThh:mm:ss` |

### Request Examples
### Request examples

The following is an unencrypted JSON request body example, which you should include in your identity bucket rotation requests:

Expand All @@ -65,9 +65,9 @@ Here's an encrypted identity bucket rotation request example:
echo '{"since_timestamp": "2023-04-19T13:00:00"}' | python3 uid2_request.py https://prod.uidapi.com/v2/identity/buckets [Your-Client-API-Key] [Your-Client-Secret]
```

For details, and code examples in different programming languages, see [Encrypting Requests and Decrypting Responses](../getting-started/gs-encryption-decryption.md).
For details, and code examples in different programming languages, see [Encrypting requests and decrypting responses](../getting-started/gs-encryption-decryption.md).

## Decrypted JSON Response Format
## Decrypted JSON response format

:::note
The response is encrypted only if the HTTP status code is 200. Otherwise, the response is not encrypted.
Expand All @@ -94,7 +94,7 @@ A successful decrypted response returns a list of salt bucket IDs and the timest
"status":"success"
}
```
### Response Body Properties
### Response body properties

The response body includes the properties shown in the following table.

Expand All @@ -103,7 +103,7 @@ The response body includes the properties shown in the following table.
| `bucket_id` | string | The salt bucket ID. |
| `last_updated` | date-time | The UTC timestamp of the last time the bucket salt was rotated. |

### Response Status Codes
### Response status codes

The following table lists the `status` property values and their HTTP status code equivalents.

Expand Down
34 changes: 17 additions & 17 deletions docs/endpoints/post-identity-map-v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,53 +11,53 @@ import Link from '@docusaurus/Link';

Maps multiple email addresses, phone numbers, or their respective hashes to their raw UID2s and <Link href="../ref-info/glossary-uid#gl-salt-bucket-id">salt bucket IDs</Link>. You can also use this endpoint to check for updates to opt-out information.

Used by: This endpoint is used mainly by advertisers and data providers. For details, see [Advertiser/Data Provider Integration Overview](../guides/integration-advertiser-dataprovider-overview.md).
Used by: This endpoint is used mainly by advertisers and data providers. For details, see [Advertiser/data provider integration overview](../guides/integration-advertiser-dataprovider-overview.md).

For details about the UID2 opt-out workflow and how users can opt out, see [User Opt-Out](../getting-started/gs-opt-out.md).
For details about the UID2 opt-out workflow and how users can opt out, see [User opt-out](../getting-started/gs-opt-out.md).

## Version

This documentation is for version 2 of this endpoint, which is not the latest version. For the latest version, v3, see [POST /identity/map](post-identity-map.md).

:::note
If you're using an earlier version, we recommend that you upgrade as soon as possible, to take advantage of improvements. For migration guidance, see [Migration from v2 Identity Map](post-identity-map.md#migration-from-v2-identity-map). For deprecation information, see [Deprecation Schedule: Endpoint Versions](../ref-info/deprecation-schedule.md#endpoint-versions).
If you're using an earlier version, we recommend that you upgrade as soon as possible, to take advantage of improvements. For migration guidance, see [Migration from v2 identity map](post-identity-map.md#migration-from-v2-identity-map). For deprecation information, see [Deprecation schedule: Endpoint versions](../ref-info/deprecation-schedule.md#endpoint-versions).
:::

## Batch Size and Request Parallelization Requirements
## Batch size and request parallelization requirements

Here's what you need to know:

- The maximum request size is 1MB.
- To map a large number of email addresses, phone numbers, or their respective hashes, send them in batches with a maximum of 5,000 items per batch. We recommend sending no more than 20 batches in parallel.
- Be sure to store mappings of email addresses, phone numbers, or their respective hashes.<br/>Not storing mappings could increase processing time drastically when you have to map millions of email addresses or phone numbers. Recalculating only those mappings that actually need to be updated, however, reduces the total processing time because only about 1/365th of raw UID2s need to be updated daily. See also [Advertiser/Data Provider Integration Overview](../guides/integration-advertiser-dataprovider-overview.md) and [FAQs for Advertisers and Data Providers](../getting-started/gs-faqs.md#faqs-for-advertisers-and-data-providers).
- Be sure to store mappings of email addresses, phone numbers, or their respective hashes.<br/>Not storing mappings could increase processing time drastically when you have to map millions of email addresses or phone numbers. Recalculating only those mappings that actually need to be updated, however, reduces the total processing time because only about 1/365th of raw UID2s need to be updated daily. See also [Advertiser/data provider integration overview](../guides/integration-advertiser-dataprovider-overview.md) and [FAQs for advertisers and data providers](../getting-started/gs-faqs.md#faqs-for-advertisers-and-data-providers).

## Rate Limiting
## Rate limiting

To ensure fair usage and platform stability, the `POST /identity/map` endpoint enforces rate limits to safeguard against bursts of incoming traffic. If you send many requests in quick succession, you might receive `429` error responses.

To handle rate limit errors gracefully, we recommend implementing [exponential backoff](https://en.wikipedia.org/wiki/Exponential_backoff) with random jitter when retrying requests. To maximize throughput within the limit, use the maximum batch size of 5,000 items per request rather than sending many small requests.

## Request Format
## Request format

`POST '{environment}/v2/identity/map'`

For authentication details, see [Authentication and Authorization](../getting-started/gs-auth.md).
For authentication details, see [Authentication and authorization](../getting-started/gs-auth.md).

:::important
You must encrypt all requests using your secret. For details, and code examples in different programming languages, see [Encrypting Requests and Decrypting Responses](../getting-started/gs-encryption-decryption.md).
You must encrypt all requests using your secret. For details, and code examples in different programming languages, see [Encrypting requests and decrypting responses](../getting-started/gs-encryption-decryption.md).
:::

### Path Parameters
### Path parameters

| Path Parameter | Data Type | Attribute | Description |
| :--- | :--- | :--- | :--- |
| `{environment}` | string | Required | Testing (integration) environment: `https://operator-integ.uidapi.com`<br/>Production environment: The best choice depends on where your users are based. For information about how to choose the best URL for your use case, and a full list of valid base URLs, see [Environments](../getting-started/gs-environments.md). |

:::note
The integration environment and the production environment require different <Link href="../ref-info/glossary-uid#gl-api-key">API keys</Link>. For information about getting credentials for each environment, see [Getting Your Credentials](../getting-started/gs-credentials.md#getting-your-credentials).
The integration environment and the production environment require different <Link href="../ref-info/glossary-uid#gl-api-key">API keys</Link>. For information about getting credentials for each environment, see [Getting your credentials](../getting-started/gs-credentials.md#getting-your-credentials).
:::

### Unencrypted JSON Body Parameters
### Unencrypted JSON body parameters

:::important
You must include only **one** of the following four conditional parameters as a key-value pair in the JSON body of the request when encrypting it.
Expand All @@ -70,7 +70,7 @@ You must include only **one** of the following four conditional parameters as a
| `phone` | string array | Conditionally Required | The list of [normalized](../getting-started/gs-normalization-encoding.md#phone-number-normalization) phone numbers to be mapped. |
| `phone_hash` | string array | Conditionally Required | The list of [Base64-encoded SHA-256](../getting-started/gs-normalization-encoding.md#phone-number-hash-encoding) hashes of [normalized](../getting-started/gs-normalization-encoding.md#phone-number-normalization) phone numbers to be mapped. |

### Request Examples
### Request examples

The following are unencrypted JSON request body examples for each parameter, one of which you should include in your requests to the `POST /identity/map` endpoint:

Expand Down Expand Up @@ -113,9 +113,9 @@ Here's an encrypted request example to the `POST /identity/map` endpoint for a p
echo '{"phone": ["+12345678901", "+441234567890"]}' | python3 uid2_request.py https://prod.uidapi.com/v2/identity/map [Your-Client-API-Key] [Your-Client-Secret]
```

For details, and code examples in different programming languages, see [Encrypting Requests and Decrypting Responses](../getting-started/gs-encryption-decryption.md).
For details, and code examples in different programming languages, see [Encrypting requests and decrypting responses](../getting-started/gs-encryption-decryption.md).

## Decrypted JSON Response Format
## Decrypted JSON response format

:::note
The response is encrypted only if the HTTP status code is 200. Otherwise, the response is not encrypted.
Expand Down Expand Up @@ -189,7 +189,7 @@ If some identifiers have opted out from the UID2 ecosystem, the opted-out identi
}
```

### Response Body Properties
### Response body properties

The response body includes the properties shown in the following table.

Expand All @@ -199,7 +199,7 @@ The response body includes the properties shown in the following table.
| `advertising_id` | string | The corresponding advertising ID (raw UID2). |
| `bucket_id` | string | The ID of the salt bucket used to generate the raw UID2. |

### Response Status Codes
### Response status codes

The following table lists the `status` property values and their HTTP status code equivalents.

Expand Down
Loading
Loading