# Purposes & Vendors Numerical IDs

In the Didomi Consent String, purposes and vendors are identified by a numerical ID. Each time a notice is published, Didomi generates the numerical IDs for the vendors and purposes contained in the notice (if they do not already have numerical IDs).

To be able to decode the consent string, you will need a mapping of purposes and vendors string IDs to their numerical IDs. Use these requests:

## Vendors

### Request

<pre><code><strong>curl --request GET \
</strong>  --url https://api.didomi.io/metadata/numeric-partners \
  --header 'accept: application/json' \
  --header 'authorization: Bearer &#x3C;TOKEN>' \
  --header 'content-type: application/json'
</code></pre>

### Response sample

```
{
    "total": 3,
    "limit": 100,
    "skip": 0,
    "data": [
        {
            "created_at": "2023-06-09T12:14:02.828Z",
            "updated_at": "2023-06-09T12:14:02.828Z",
            "metadata_partner_id": "googleana-4TXnJigR",
            "numeric_id": 1,
            "organization_id": "didomi-test"
        },
        {
            "created_at": "2023-06-09T12:14:02.828Z",
            "updated_at": "2023-06-09T12:14:02.828Z",
            "metadata_partner_id": "google",
            "numeric_id": 2,
            "organization_id": "didomi-test"
        },
        {
            "created_at": "2023-06-09T12:21:04.583Z",
            "updated_at": "2023-06-09T12:21:04.583Z",
            "metadata_partner_id": "tappx-jjy49eFA",
            "numeric_id": 3,
            "organization_id": "didomi-test"
        }
    ]
}
```

## Purposes

### Request

```
curl --request GET \
  --url https://api.didomi.io/metadata/numeric-purposes \
  --header 'accept: application/json' \
  --header 'authorization: Bearer <TOKEN>' \
  --header 'content-type: application/json'
```

### Response sample

```
{
    "total": 4,
    "limit": 100,
    "skip": 0,
    "data": [
        {
            "created_at": "2023-06-09T12:14:02.839Z",
            "updated_at": "2023-06-09T12:14:02.839Z",
            "metadata_purpose_id": "analytics",
            "numeric_id": 5,
            "organization_id": "didomi-test"
        },
        {
            "created_at": "2023-06-09T12:14:02.839Z",
            "updated_at": "2023-06-09T12:14:02.839Z",
            "metadata_purpose_id": "content_personalization",
            "numeric_id": 6,
            "organization_id": "didomi-test"
        },
        {
            "created_at": "2023-06-09T12:14:02.839Z",
            "updated_at": "2023-06-09T12:14:02.839Z",
            "metadata_purpose_id": "create_ads_profile",
            "numeric_id": 7,
            "organization_id": "didomi-test"
        },
        {
            "created_at": "2023-06-09T12:14:02.839Z",
            "updated_at": "2023-06-09T12:14:02.839Z",
            "metadata_purpose_id": "create_content_profile",
            "numeric_id": 8,
            "organization_id": "didomi-test"
        }    
    ]
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developers.didomi.io/api-and-platform/data-manager/purposes/purposes-and-vendors-numerical-ids.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
