Skip to main content
POST
Server-side direct upload

Overview

Uploads a file to your workspace as multipart/form-data. This is the primary upload endpoint for backend services.

Required request

Headers

Form fields

Minimal example

Common optional fields

Success response shape

Error pattern

A failed request returns success: false with an error and a message. A missing or invalid key returns:

Next steps

Remote URL upload

Fetch a file from another server instead of uploading its bytes.

Multipart start

Upload large files in parts with presigned URLs.

Authorizations

x-api-key
string
header
required

API key for public endpoints. Can also be provided via Authorization: Bearer

Body

multipart/form-data
file
file
required

File to upload.

file_name
string
required

File name (e.g. product.jpg)

Example:

"product.jpg"

folder
string

Optional folder path

Example:

"products/sku123"

transform
string

Transform string (w_300,h_300,c_crop,...)

tags
string

Comma-separated tags

Example:

"product,thumbnail"

random_prefix
string

true/false to append random suffix

custom_id
string

Custom identifier

Example:

"sku123"

metadata
string

JSON string of metadata

Example:

"{\"productId\":\"123\"}"

webhook_url
string

URL to notify on success

Response

Upload created

Upload created

id
string
required
file_no
string
required
workspace_id
string
required
name
string
required
path
string
required
url
string
required
width
integer | null
required
Required range: -9007199254740991 <= x <= 9007199254740991
height
integer | null
required
Required range: -9007199254740991 <= x <= 9007199254740991
size
integer
required
Required range: -9007199254740991 <= x <= 9007199254740991
mime_type
string
required
tags
string[]
required
metadata
object | null
required
custom_id
string | null
required
folder_no
string | null
required
is_duplicate
boolean
required
created_at
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
upload_source
string
required
thumbnail
string
required
extension
string
required
format
string
hash
string
is_private
boolean