---
title: "Rename a folder"
method: POST
path: "/folders/{folder_id}/rename"
tags: ["Folders"]
---

# Rename a folder

`POST /folders/{folder_id}/rename`

Renames an existing folder. The new name must be unique within the same parent folder.
This operation only changes the folder name, not its location or contents.

## Path parameters

- `folder_id` string, required

## Request body

- object
  - `name` string, required

## Response `200`

successful rename

- Folder
  - `id` string, nullable, required
  - `name` string, nullable, required
  - `path` string, nullable, required
  - `parent_folder_id` string, nullable, required

## Other responses

- `401` — authentication failed
- `404` — folder doesn't belong to me
- `422` — name already exist

---

[API](https://skmtc.dev/docspring/apis/docspring-api.md) · [All operations](https://skmtc.dev/docspring/apis/docspring-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/docspring/docspring-api/revisions/5726657b9432/schema)
