> ## Documentation Index
> Fetch the complete documentation index at: https://docs.platform.toloka.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# client.datasets.create()

> Create a dataset.

Send an optional name and profile. A profile creates typed fields and mappings that validate file uploads. Without a profile, uploaded rows are stored in the "uploaded" field. Returns the dataset.

## Signature

Method signature on `client.datasets`:

```ts theme={null}
create(args: {
  projectId: string;
  name?: string;
  profile?: "instruction" | "chat-sft";
}): Promise<Dataset>;
```

## Parameters

**projectId** `string` *required*

Project ID with prefix `pp.`.

**name** `string`

Name of the dataset; defaults to `New Dataset`.

**profile** `"instruction" | "chat-sft"`

Create typed fields and upload mappings with "chat-sft" (messages, tools, split, assistant, source\_ref) or "instruction" (prompt, completion, split). Without a profile, uploaded rows are stored in the "uploaded" field.

## Returns

`Promise<Dataset>`

A dataset within a project.

**id** `DatasetId` *required*

Dataset ID with prefix `ds.`.

**projectId** `ProjectId` *required*

Project ID with prefix `pp.`.

**name** `string` *required*

Name of the dataset.

**hidden** `boolean` *required*

Whether the dataset is hidden from ordinary dataset lists.

**profile** `DatasetProfileStamp | null` *required*

Profile used to create the dataset fields, or null for a dataset without a profile.

**Fields**

**name** `"chat-sft" | "instruction"` *required*

Profile name: `chat-sft` for chat training examples or `instruction` for prompt and completion pairs.

**version** `number` *required*

Version of the profile definition used when the dataset was created.

**createdAt** `string` *required*

Time the dataset was created, as an ISO 8601 timestamp.

## Errors

HTTP errors throw [`PotatoApiError`](https://docs.platform.toloka.ai/docs/sdk/errors). The endpoint documents these error responses:

| Status | Description |
| - | - |
| 404 | Project not found |
| 429 | Rate limit exceeded |

HTTP endpoint: [`POST /projects/{projectId}/datasets`](https://docs.platform.toloka.ai/docs/api-reference/datasets/create-dataset).

```ts create() theme={null}
import { createClient } from "@toloka-platform/sdk";

const client = createClient({
  baseUrl: "https://platform.toloka.ai",
  apiKey: process.env.TOLOKA_API_KEY!,
});

const dataset = await client.datasets.create({
  projectId: "pp.019a0000-0000-7000-8000-000000000001",
  name: "training_examples"
});
console.log(dataset);
```

```json create() theme={null}
{
  "id": "ds.019a0000-0000-7000-8000-000000000001",
  "projectId": "pp.019a0000-0000-7000-8000-000000000001",
  "name": "<string>",
  "hidden": false,
  "profile": null,
  "createdAt": "2026-01-01T00:00:00Z"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.