---
title: "Rename or move folder"
method: PATCH
path: "/tests/folders"
---

# Rename or move folder

`PATCH /tests/folders`

Rename a folder, move it under another folder, or both in one call. `parentId: null` moves it back to the top level; omitting `parentId` leaves it where it is. Moving a folder takes its subfolders and its tests with it. Both halves are applied together, so a refused move never leaves the rename it came with applied.

## Request body

- UpdateFolder — Send `folderId` plus `name`, `parentId`, or both.
  - `folderId` string, required
  - `name` string — The new display name. Omit it to leave the name as it is.
  - `parentId` string, nullable — Move the folder under this one, or `null` to move it to the top level. Omit the field to leave it where it is. A folder cannot be moved inside itself or one of its own subfolders.

## Response `200`

Successful response

- unknown

## Other responses

- `400` — Neither `name` nor `parentId` was given, the name is empty or too long, or the move would put the folder inside its own subtree.
- `404` — The folder, or the folder named as `parentId`, does not exist.

---

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