Skip to main content
POST
Create an upload for an image or file cell

Authorizations

X-Auth-Token
string
header
required

Project API key for sending traces and accessing project-scoped resources. Format: sk-lw-... (no underscore). Obtain one by creating a project via the Admin API or the LangWatch UI.

Body

application/json
filename
string
required

The file name the reference will carry.

Minimum string length: 1
mediaType
string
required

The media type of the file.

Required string length: 1 - 127
Pattern: ^[\u0020-\u007e]+$
byteLength
integer
required

The size of the file, in bytes.

Required range: 0 <= x <= 9007199254740991

Response

Success

objectId
string
required
Minimum string length: 1
uploadUrl
string<uri>
required
method
string
required
Allowed value: "PUT"
expiresAt
string
required
Minimum string length: 1
headers
object
Last modified on October 12, 2026