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

# List mailbox folders

> Returns a cursor-paginated list of folders for the authenticated mailbox.



## OpenAPI

````yaml /openapi-app.json get /mailbox/folders
openapi: 3.1.0
info:
  description: Programmatic access to your Sendmux email infrastructure.
  title: Sendmux API
  version: 1.0.0
servers:
  - description: API v1
    url: https://app.sendmux.ai/api/v1
security:
  - bearerAuth: []
paths:
  /mailbox/folders:
    get:
      tags:
        - Mailbox API
      summary: List mailbox folders
      description: >-
        Returns a cursor-paginated list of folders for the authenticated
        mailbox.
      operationId: mailboxListFolders
      parameters:
        - in: query
          name: cursor
          required: false
          schema:
            description: Pagination cursor — the `next_cursor` from the previous response.
            type: string
        - in: query
          name: limit
          required: false
          schema:
            description: Maximum results (default 50, max 100).
            maximum: 100
            minimum: 1
            type: integer
        - description: >-
            Mailbox public ID to target when the credential grants access to
            more than one mailbox. Omit when the credential is scoped to exactly
            one mailbox.
          in: query
          name: mailbox_id
          required: false
          schema:
            type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MailboxFolderCursorListResponse'
          description: Folder list
      security:
        - bearerAuth: []
components:
  schemas:
    MailboxFolderCursorListResponse:
      allOf:
        - $ref: '#/components/schemas/SuccessEnvelope'
        - properties:
            data:
              items:
                $ref: '#/components/schemas/MailboxFolder'
              type: array
            meta:
              $ref: '#/components/schemas/ResponseMeta'
            pagination:
              $ref: '#/components/schemas/CursorPagination'
          required:
            - data
            - pagination
          type: object
      unevaluatedProperties: false
    SuccessEnvelope:
      properties:
        meta:
          additionalProperties: {}
          properties: {}
          type: object
        ok:
          enum:
            - true
          type: boolean
      required:
        - ok
        - meta
      type: object
    MailboxFolder:
      additionalProperties: false
      properties:
        can_add_items:
          description: Whether messages can be moved into this folder.
          type: boolean
        id:
          description: Folder ID
          type: string
        name:
          type: string
        parent_id:
          type:
            - string
            - 'null'
        role:
          description: System role when the folder is a built-in folder.
          type:
            - string
            - 'null'
        sort_order:
          type:
            - integer
            - 'null'
        total_messages:
          type: integer
        unread_messages:
          type: integer
      required:
        - id
        - name
        - parent_id
        - role
        - sort_order
        - total_messages
        - unread_messages
        - can_add_items
      type: object
    ResponseMeta:
      additionalProperties: false
      properties:
        request_id:
          example: req_clxxxxxxxxxxxxxxxxxxxxxxxxx
          type: string
      required:
        - request_id
      type: object
    CursorPagination:
      additionalProperties: false
      properties:
        has_more:
          type: boolean
        next_cursor:
          type: string
      required:
        - has_more
      type: object
  securitySchemes:
    bearerAuth:
      bearerFormat: API Key
      description: >-
        Sendmux API key. Use a root API key for Management API routes, or a
        mailbox credential for Mailbox API routes. Obtain keys from the
        dashboard under API Keys.
      scheme: bearer
      type: http

````