> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stax.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Rename email folder

> Rename a folder in the connected mailbox's provider via Nylas and mirror the change into the local catalog. System folders (Inbox/Sent/Trash) cannot be renamed. On Gmail, where hierarchy lives in the label name, the folder's parent path is preserved and every descendant label is rewritten onto the new prefix — Gmail does not cascade renames itself.



## OpenAPI

````yaml /api-reference/cx/swagger.json patch /inbox/folders/{folder}
openapi: 3.0.0
info:
  description: CX API.
  title: CX API
  contact:
    name: API Support
    url: https://stax.ai
    email: support@stax.ai
  version: '1.0'
servers:
  - url: https://api.cx.stax.ai
security: []
paths:
  /inbox/folders/{folder}:
    patch:
      tags:
        - Inbox
      summary: Rename email folder
      description: >-
        Rename a folder in the connected mailbox's provider via Nylas and mirror
        the change into the local catalog. System folders (Inbox/Sent/Trash)
        cannot be renamed. On Gmail, where hierarchy lives in the label name,
        the folder's parent path is preserved and every descendant label is
        rewritten onto the new prefix — Gmail does not cascade renames itself.
      responses:
        default:
          description: No response is documented for this operation upstream.
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      description: CX API key. Create one in CX under Settings → Advanced → API Keys.
      in: header
      name: x-api-key
      type: apiKey

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.