---
updatedAt: 2026-06-12T14:47:10.000Z
agentTools:
  projectIndex: https://docs.formant.io/llms.txt
---

# Begin upload

Initiate a file upload. Must be followed by Complete Upload endpoint call.
Resource: fileStorage
Authorized roles: administrator

# OpenAPI definition

```json
{
  "components": {
    "schemas": {
      "BeginUploadRequest": {
        "properties": {
          "fileName": {
            "pattern": "^[a-zA-Z0-9!-_.*'() ]{1,1024}$",
            "type": "string",
            "minLength": 1,
            "maxLength": 256
          },
          "fileSize": {
            "type": "integer",
            "format": "int64",
            "minimum": 1,
            "maximum": 10737418240
          },
          "forceOverwrite": {
            "type": "boolean"
          },
          "contentType": {
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "fileName",
          "fileSize"
        ]
      },
      "BeginUploadResponse": {
        "properties": {
          "fileId": {
            "format": "uuid",
            "type": "string",
            "description": "ID of the file being uploaded."
          },
          "uploadId": {
            "type": "string",
            "description": "ID of the upload."
          },
          "partUrls": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "partSize": {
            "type": "integer",
            "format": "int64",
            "minimum": 5242880,
            "maximum": 5368709120
          }
        },
        "type": "object",
        "required": [
          "fileId",
          "uploadId",
          "partUrls",
          "partSize"
        ]
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "info": {
    "title": "Formant admin-api",
    "version": "1.357.8"
  },
  "openapi": "3.0.0",
  "paths": {
    "/files/begin-upload": {
      "post": {
        "operationId": "FileController.beginUpload",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BeginUploadRequest"
              }
            }
          },
          "description": "BeginUploadRequest",
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/BeginUploadResponse"
                }
              }
            },
            "description": ""
          }
        },
        "summary": "Begin upload",
        "tags": [
          "File"
        ],
        "description": "Initiate a file upload. Must be followed by Complete Upload endpoint call.\nResource: fileStorage\nAuthorized roles: administrator",
        "security": [
          {
            "bearerAuth": []
          }
        ]
      }
    }
  },
  "servers": [
    {
      "url": "https://api.formant.io/v1/admin"
    }
  ]
}
```