> For the complete documentation index, see [llms.txt](https://developer.mediarithmics.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.mediarithmics.io/advanced-usages/data-clean-room/dataset.md).

# Dataset

## Create a Segment catalog dataset from your datamart

<mark style="color:green;">`POST`</mark> [`https://api.mediarithmics.com/v1/datasets?bunker_id={{bunker_id}}`](https://api.mediarithmics.com/v1/datasets?bunker_id={{bunker_id}})

**Body parameters**

| Name              | Type             | Description                                                                             |
| ----------------- | ---------------- | --------------------------------------------------------------------------------------- |
| `organisation_id` | string           | ID of the organisation attached to the bunker                                           |
| `datamart_id`     | string           | ID of the datamart attached to the bunker                                               |
| `bunker_id`       | string           | ID of the bunker in which to create the dataset                                         |
| `name`            | string           | Name of the dataset                                                                     |
| `description`     | string           | Description of the dataset                                                              |
| `label_ids`       | array of strings | All segments linked to at least one of the provided labels will be added in the dataset |
| `expiration_ts`   | integer          | Expiration timestamp of the dataset in ms                                               |

**Body example**

```json
{
  "dataset":{
    "source":"DATAMART",
    "type":"SEGMENT_CATALOG",
    "organisation_id":"1912",
    "datamart_id": "1996",
    "bunker_id":"110",
    "name":"Insights catalog",
    "description":"Catalog for insights generation",
    "label_ids": ["1263","1264"],
    "expiration_ts":1806157679000
  }
}  
```

**Response**

{% tabs %}
{% tab title="200" %}

```json
{
  "status": "ok",
  "data": {
    "type": "SEGMENT_CATALOG",
    "id": "3326",
    "expiration_ts": 1806157679000,
    "type": "SEGMENT_CATALOG",
    "organisation_id": "1912",
    "bunker_id": "110",
    "name": "Insights catalog",
    "source": "DATAMART",
    "created_by": "3594",
    "created_ts": 1781771031958,
    "last_modified_by": null,
    "last_modified_ts": null,
    "archived_by": null,
    "archived_ts": null,
    "archived": false,
    "properties": [],
    "records_count": 0,
    "status": "SYNCHRONIZATION_PENDING",
    "datamart_id": "1996",
    "label_ids": [
      "1263",
      "1264"
    ],
    "organisation_name": "AV Sub 1.5",
    "description": "Catalog for insights generation"
  }
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://developer.mediarithmics.io/advanced-usages/data-clean-room/dataset.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
