---
title: "Rename, move and/or restyle a folder."
method: PATCH
path: "/v1/folders/{id}"
tags: ["folders"]
---

# Rename, move and/or restyle a folder.

`PATCH /v1/folders/{id}`

## Request

- Base URL: `http://localhost:8080`
- URL: `http://localhost:8080/v1/folders/{id}`
- Auth: one of:
  - API key in cookie `dvt_session`
  - HTTP bearer

Renames the folder, moves it to a new parent and/or restyles it. `parentId: null` moves it to
root; an absent `parentId` leaves the parent unchanged. `icon`/`tint` set the nav glyph and
tint; `null` resets one to its default and an absent key leaves it unchanged. Moving carries the folder's
whole subtree; a move into the folder's own subtree is rejected (409 folder-cycle).
Requires the folder's current `version` (optimistic concurrency). Editor or above.

## Request body

- object
  - `version` integer, required
  - `name` string
  - `parentId` string, uuid, nullable: New parent, or null for root. Omit to keep the current parent.
  - `icon` 'folder' | 'chart' | 'trend' | 'pie' | 'dollar' | 'wallet' | 'truck' | 'box' | 'warehouse' | 'pin' | 'globe' | 'users' | 'target' | 'flag' | 'star' | 'shield' | 'clipboard' | 'calendar' | 'clock' | 'bolt' | 'gear' | 'briefcase' | 'megaphone' | 'book', nullable: Nav icon key. null resets to the default glyph; omit to keep the current icon.
  - `tint` 'slate' | 'teal' | 'indigo' | 'sea' | 'navy' | 'periwinkle' | 'violet' | 'steel', nullable: Nav tint key. null resets to the default (slate); omit to keep the current tint.

## Response `200`

The updated folder (version incremented).

- FolderEnvelope
  - `data` Folder, required: A node in the org's dashboard folder tree. Folders are returned flat (id + parentId); clients assemble the hierarchy. Tenancy is org-wide — every member of the organization sees the same tree.
    - `id` string, uuid, required
    - `parentId` string, uuid, nullable, required: The parent folder, or null for a root-level folder.
    - `name` string, required
    - `icon` 'folder' | 'chart' | 'trend' | 'pie' | 'dollar' | 'wallet' | 'truck' | 'box' | 'warehouse' | 'pin' | 'globe' | 'users' | 'target' | 'flag' | 'star' | 'shield' | 'clipboard' | 'calendar' | 'clock' | 'bolt' | 'gear' | 'briefcase' | 'megaphone' | 'book', nullable: Nav icon key; null = the default folder glyph.
    - `tint` 'slate' | 'teal' | 'indigo' | 'sea' | 'navy' | 'periwinkle' | 'violet' | 'steel', nullable: Nav tint key; null = the default (slate).
    - `version` integer, required: Optimistic-concurrency version. Pass this back on PATCH.
    - `createdAt` string, date-time, required
    - `updatedAt` string, date-time, required
  - `meta` Meta, required: Response metadata.
    - `requestId` string, required: Correlates with the X-Request-Id header.
    - `total` integer: Item count, present on collection responses.
    - `nextCursor` string, nullable: Opaque keyset-pagination cursor, present on paginated responses (e.g. GET /v1/dashboards) when more rows exist beyond this page. Pass it back as the `cursor` query param to fetch the next page; absent or null on the last page.
    - `roleResolveDegraded` boolean: Snowflake mode only (DVT-2260), on GET /v1/dashboards: present and true when the caller's live Snowflake role resolution failed or was unavailable — role-shared dashboards may be missing from this page. Omitted (not merely false) whenever resolution succeeded or the role-share arm does not apply (off snowflake mode, an org admin/owner, or off the ingress listener).

## Other responses

- `400`: Malformed request.
- `401`: Missing, invalid, or expired session.
- `403`: The caller's role does not permit this action.
- `404`: Resource does not exist.
- `409`: Stale version (version-conflict) or a move into the folder's own subtree (folder-cycle).

---

[API](https://skmtc.dev/dvt/apis/dvt-rest-api.md) · [All operations](https://skmtc.dev/dvt/apis/dvt-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/dvt/apis/dvt-rest-api/revisions/00016f504165?raw)
