Uploads

Upload a media file

Upload a local image, video, or audio file and receive a public HTTPS URL for use as a reference input. Send multipart/form-data with a single file field. Accepts JPEG, PNG, WebP up to 10 MB, and MP4, MOV, WebM, MP3, M4A, WAV, OGG, or FLAC up to 25 MB; the URL expires after 24h.

post/v1/uploads

Request

  • Base URL: https://api.hotapi.ai
  • URL: https://api.hotapi.ai/v1/uploads
  • Auth: HTTP bearer

Response

A stored upload, ready to use as a supported image, video, or audio input.

urlstring required

Public HTTPS URL of the stored image, video, or audio file on HotAPI's CDN. Pass it directly to a supported reference input field.

expires_atinteger required

Unix seconds after which the upload is deleted. Submit your task before this.

content_typestring required
sizeinteger required

File size in bytes.

widthinteger

Image width in pixels; present for images only.

heightinteger

Image height in pixels; present for images only.

Example response

{
  "url": "https://cdn.hotapi.ai/uploads/org_8sd9f7aQ2/V1StGXR8Z5.png",
  "content_type": "image/png"
}

Changes

No recorded changes to this operation across all 1 revision of this API.