---
title: "Create Dataset"
method: POST
path: "/knowledge-base/datasets"
tags: ["datasets"]
---

# Create Dataset

`POST /knowledge-base/datasets`

## Request

- Base URL: `https://api.anyreach.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.anyreach.ai/knowledge-base/datasets`
- Auth: HTTP bearer

## Headers

- `x-anyreach-org` string, nullable: Organization ID for user PATs (pat_ prefix tokens)

## Request body

- DatasetCreateRequestSchema
  - `name` string, required
  - `description` string, nullable
  - `embedding_model` 'text-embedding-3-small' | 'text-embedding-3-large', required
  - `embedding_dimension` 768 | 1536 | 3072, required

## Response `200`

Successful Response

- DatasetSchema
  - `id` string, uuid, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `created_by` string, nullable
  - `modified_by` string, nullable
  - `organization_id` string, required
  - `name` string, required
  - `description` string, nullable
  - `embedding_model` 'text-embedding-3-small' | 'text-embedding-3-large', required
  - `embedding_dimension` 768 | 1536 | 3072, required
  - `source_count` integer, nullable
  - `today_sources` integer, nullable
  - `daily_source_counts` integer[], nullable
  - `last_source_date` string, nullable

## Other responses

- `404`: Not found
- `422`: Validation Error

---

[API](https://skmtc.dev/anyreach/apis/anyreach-api.md) - [All operations](https://skmtc.dev/anyreach/apis/anyreach-api/llms.txt) - [OpenAPI document](https://skmtc.dev/anyreach/apis/anyreach-api/revisions/2eddf40c8c93?raw)
