---
title: "Create Directory"
method: POST
path: "/agent-knowledge/directories"
tags: ["agent-knowledge"]
---

# Create Directory

`POST /agent-knowledge/directories`

## Request body

- CreateAgentKnowledgeDirectoryRequest
  - `path` string, required

## Response `201`

Successful Response

- CreateAgentKnowledgeDirectoryResponse
  - `kind` 'directory'
  - `id` string, nullable
  - `path` string, required
  - `parentPath` string, required
  - `name` string, required
  - `directoryKind` string, nullable
  - `status` string, nullable
  - `isUserVisible` boolean, required
  - `fileCount` integer, nullable
  - `directoryCount` integer, nullable
  - `categoryLabel` string, nullable
  - `commentCount` integer
  - `updatedAt` string, date-time, nullable
  - `node` AgentKnowledgeDirectoryWindowNodeResponse, required
    - `hasChildDirectories` boolean, required
    - `hasChildren` boolean, required
    - `id` string, nullable, required
    - `isUserVisible` boolean, required
    - `kind` 'directory', required
    - `name` string, required
    - `path` string, required
    - `updatedAt` string, date-time, nullable, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/traversal/apis/fastapi.md) · [All operations](https://skmtc.net/traversal/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/traversal/fastapi/revisions/2134ebffd1ef/schema)
