# Create Folder

Creates a new folder under your account. 

<Callout icon="📘" theme="info">
  **Note:**

  * Scroll down to the **Response** section below and expand the status code(s) to view the detailed response schema.
  * Refer to the **RESPONSE** section on the right and choose an example to see how the API response appears for each status code.
</Callout>

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "heygen-api",
    "version": "4.0.8"
  },
  "servers": [
    {
      "url": "https://api.heygen.com"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "apiKey",
        "name": "x-api-key",
        "in": "header",
        "x-default": "<your-api-key>"
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/v1/folders/create": {
      "post": {
        "summary": "Create Folder",
        "description": "",
        "operationId": "create-folder",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "Name of the folder. ",
                    "default": ""
                  },
                  "project_type": {
                    "type": "string",
                    "description": "Type of project associated with the folder. The `instant_avatar` and `asset` project types are **Enterprise-Only** and require special access. Please contact your AE for further details. ",
                    "enum": [
                      "video_translate",
                      "instant_avatar",
                      "video",
                      "asset",
                      "brand_kit",
                      "mixed"
                    ],
                    "default": "mixed"
                  },
                  "parent_id": {
                    "type": "string",
                    "description": "Unique identifier of the parent folder. Leave empty to create a top-level folder, or provide an existing folder's ID to create a subfolder under it. Another way to create a subfolder is by first creating a parent folder using this API and then using the returned folder `id` as the `parent_id` in a subsequent request. "
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Folder created successfully - Expand to view the detailed response schema.",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": {
                      "error": null,
                      "data": {
                        "id": "61b2e7f17b174849895576ce042894a2",
                        "name": "AI Videos Folder",
                        "parent_id": null,
                        "project_type": "video_translate",
                        "is_trash": false,
                        "created_ts": 1760972268,
                        "updated_ts": 1760972268,
                        "direct_children_count": null,
                        "creator_username": "65ebafd83a8532f0b8d56a1dc8a4cee2"
                      }
                    }
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "error": {
                      "type": "string",
                      "description": "Displays error message when the request fails; null if the request is successful."
                    },
                    "data": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "Unique identifier of the folder."
                        },
                        "name": {
                          "type": "string",
                          "description": "Name of the folder."
                        },
                        "parent_id": {
                          "type": "string",
                          "description": "Unique identifier of the parent folder. `null` if the folder is at root level."
                        },
                        "project_type": {
                          "type": "string",
                          "description": "Type of project associated with the folder. For example, `video_translate`, `instant_avatar`, `video`, `asset`, `brand_kit`, and `mixed`.  "
                        },
                        "is_trash": {
                          "type": "boolean",
                          "description": "Whether the folder is in the trash. "
                        },
                        "created_ts": {
                          "type": "integer",
                          "description": "Unix timestamp when the folder was created. "
                        },
                        "updated_ts": {
                          "type": "integer",
                          "description": "Unix timestamp when the folder was updated. "
                        },
                        "direct_children_count": {
                          "type": "integer",
                          "description": "Number of subfolders directly contained within the folder.  "
                        },
                        "creator_username": {
                          "type": "string",
                          "description": "Unique identifier of the user who created the folder. "
                        }
                      },
                      "description": "Contains details of the newly created folder. "
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```