Upload files
POST /files
Upload one or more files to a specified bucket. Supports batch uploading with optional custom metadata for each file. If uploading multiple files, either provide metadata for all files or none.
Authorizations
Section titled “Authorizations ”Request Body required
Section titled “Request Body required ”File upload data including files and optional metadata
object
Target bucket identifier where files will be stored.
Example
user-uploadsOptional custom metadata for each uploaded file. Must match the order of the file[] array.
Metadata provided when uploading a new file.
object
Optional custom ID for the file. If not provided, a UUID will be generated.
Example
custom-id-123Name to assign to the file. If not provided, the original filename will be used.
Example
custom-filename.pngCustom metadata to associate with the file.
object
Example
{ "alt": "Custom image", "category": "document"}Array of files to upload.
Responses
Section titled “ Responses ”Files successfully uploaded
object
List of successfully processed files with their metadata.
Comprehensive metadata information about a file in storage.
object
Unique identifier for the file.
Example
d5e76ceb-77a2-4153-b7da-1f7c115b2ff2Name of the file including extension.
Example
profile-picture.jpgSize of the file in bytes.
Example
245678ID of the bucket containing the file.
Example
users-bucketEntity tag for cache validation.
Example
"a1b2c3d4e5f6"Timestamp when the file was created.
Example
2023-01-15T12:34:56ZTimestamp when the file was last updated.
Example
2023-01-16T09:45:32ZWhether the file has been successfully uploaded.
Example
trueMIME type of the file.
Example
image/jpegID of the user who uploaded the file.
Example
abc123def456Custom metadata associated with the file.
object
Example
{ "alt": "Profile picture", "category": "avatar"}default
Section titled “default ”Error occurred during upload
Error information returned by the API.
object
List of files that were successfully processed before the error occurred.
Comprehensive metadata information about a file in storage.
object
Unique identifier for the file.
Example
d5e76ceb-77a2-4153-b7da-1f7c115b2ff2Name of the file including extension.
Example
profile-picture.jpgSize of the file in bytes.
Example
245678ID of the bucket containing the file.
Example
users-bucketEntity tag for cache validation.
Example
"a1b2c3d4e5f6"Timestamp when the file was created.
Example
2023-01-15T12:34:56ZTimestamp when the file was last updated.
Example
2023-01-16T09:45:32ZWhether the file has been successfully uploaded.
Example
trueMIME type of the file.
Example
image/jpegID of the user who uploaded the file.
Example
abc123def456Custom metadata associated with the file.
object
Example
{ "alt": "Profile picture", "category": "avatar"}Error details.
object
Human-readable error message.
Example
File not foundAdditional data related to the error, if any.