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

# Create a folder archive snapshot schedule

> Creates a per-folder recurring snapshot. Convertly runs due schedules automatically; you do not need your own cron unless you prefer one-off archives via POST /api/files/archive.



## OpenAPI

````yaml /openapi.json post /api/folder-archive-schedules
openapi: 3.1.0
info:
  title: Convertly API
  version: 1.0.0
  description: >-
    Convertly provides production API endpoints for media conversion,
    compression, Image CDN delivery, Forma AI, HLS/DASH video streaming, media
    tools, async jobs, workflows, webhooks, and Convertly Storage.
  license:
    name: Proprietary
    url: https://convertly.sh/terms
servers:
  - url: https://convertly.sh
security:
  - bearerAuth: []
  - apiKeyAuth: []
paths:
  /api/folder-archive-schedules:
    post:
      tags:
        - Files
      summary: Create a folder archive snapshot schedule
      description: >-
        Creates a per-folder recurring snapshot. Convertly runs due schedules
        automatically; you do not need your own cron unless you prefer one-off
        archives via POST /api/files/archive.
      operationId: createFolderArchiveSchedule
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/FolderArchiveScheduleInput'
      responses:
        '201':
          description: Schedule created
        '400':
          $ref: '#/components/responses/Error'
        '401':
          $ref: '#/components/responses/Error'
        '404':
          $ref: '#/components/responses/Error'
components:
  schemas:
    FolderArchiveScheduleInput:
      type: object
      required:
        - folderId
        - name
        - frequency
        - hour
        - minute
      properties:
        folderId:
          type: string
          format: uuid
          description: Folder to snapshot. One schedule row applies to one folder.
        name:
          type: string
          maxLength: 120
          example: Campaign assets backup
        frequency:
          type: string
          enum:
            - daily
            - weekly
            - monthly
        hour:
          type: integer
          minimum: 0
          maximum: 23
          example: 2
        minute:
          type: integer
          minimum: 0
          maximum: 59
          example: 0
        dayOfWeek:
          type: integer
          minimum: 0
          maximum: 6
          description: Required for weekly schedules. 0 = Sunday.
        dayOfMonth:
          type: integer
          minimum: 1
          maximum: 28
          description: Required for monthly schedules.
        timezone:
          type: string
          example: America/New_York
          default: UTC
        format:
          type: string
          enum:
            - zip
            - tar
            - tgz
          default: zip
        targetFolderId:
          type:
            - string
            - 'null'
          format: uuid
          description: Where to store the archive. Defaults to the source folder.
        retentionCount:
          type: integer
          minimum: 1
          maximum: 365
          default: 7
          description: Maximum number of snapshots to keep for this schedule.
        retentionDays:
          type: integer
          minimum: 1
          maximum: 3650
          default: 90
          description: Delete snapshots older than this many days.
        enabled:
          type: boolean
          default: true
    Error:
      type: object
      properties:
        error:
          type: string
        upgradeUrl:
          type: string
      required:
        - error
  responses:
    Error:
      description: Error response
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Dashboard-generated Convertly API key. Keys currently begin with
        `cvly_`.
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: Alternative API key header for server-side clients.

````