Skip to main content
POST
Create presigned upload URL
Use this upload endpoint for your post media and custom video thumbnail images. Send the file’s MIME type in type when you know it. For an MP4 video, use:
If you omit type, Mallary uses the filename extension to choose a supported MIME type. Files with unknown extensions need an explicit supported type. Upload the file bytes to the returned uploadUrl with HTTP PUT. Use the returned headers, including Content-Type, without changing them. Wait for the upload to finish before passing mediaUrl to POST /api/v1/post.

Authorizations

Authorization
string
header
required

Use Authorization: Bearer {api_key}

Body

application/json
filename
string
required
Example:

"launch-video.mp4"

size
integer

Optional file size in bytes for early validation against the 5GB limit.

Required range: x >= 1
type
string

File MIME type. Send it when known, such as video/mp4 for an MP4 video. If omitted, Mallary infers it from a supported filename extension. Files with unknown extensions need an explicit supported type.

Example:

"video/mp4"

Response

Upload metadata created

uploadUrl
string<uri>
required
mediaUrl
string<uri>
required
contentType
string
required
storageKey
string
size
integer

Echoed back when a size value was supplied in the request.

headers
object
Last modified on September 22, 2026