---
title: "Create category"
method: POST
path: "/kb-categories"
tags: ["Categories"]
---

# Create category

`POST /kb-categories`

## Request

- Base URL: `https://api.weav.com/v1`
- URL: `https://api.weav.com/v1/kb-categories`
- Auth: HTTP bearer

Lazily creates the organization's knowledge base if this is its first write.

## Request body

- object
  - `name` string, required
  - `slug` string, nullable: Auto-generated from name when omitted
  - `section_id` string, uuid, nullable

## Response `201`

Created

- KbCategory
  - `id` string, uuid
  - `name` string
  - `slug` string
  - `section_id` string, uuid, nullable
  - `position` integer, nullable
  - `created_at` string, date-time, nullable
  - `updated_at` string, date-time, nullable

## Other responses

- `401`: Unauthorized
- `422`: Validation error or slug already taken

---

[API](https://skmtc.dev/weav/apis/weav-api.md) · [All operations](https://skmtc.dev/weav/apis/weav-api/llms.txt) · [OpenAPI document](https://skmtc.dev/weav/apis/weav-api/revisions/15970f126c0e?raw)
