Skip to main content
POST
Upload File
Upload a file to project storage. The file is saved using a path structure defined by pathParts. The filename is sanitized using transliteration.

Headers

Content-Type
string
required
Must be multipart/form-data

Body Parameters (multipart/form-data)

file
file
required
The file to upload. Must not exceed 15MB.
pathParts
string
required
A JSON stringified array of folder path segments (e.g., ["profile", "images"])

Response

fileId
string
Unique identifier for the uploaded file
relativePath
string
Relative path to the file (e.g., “profile/images/photo.jpg”)
publicPath
string
Public URL to access the file

Error Responses


Notes

  • Requires authentication
  • The uploaded file is stored at the location specified by pathParts, with the filename sanitized
  • Returns a public URL to access the file
  • Maximum file size: 15MB
  • Content-Type must be multipart/form-data
  • Rate limiting: 50 requests per 5 minutes