Files

Create file upload

Changed on

Create a new file and receive a pre-signed upload URL. PUT the file bytes to the returned URL, then poll GET /v1/files/{fileId} until the file is ready.

post/v1/files/upload

Request

  • Base URL
    https://api.videogen.io
  • Auth
    HTTP bearer

Request body

type'IMAGE' | 'VIDEO' | 'AUDIO' | 'PDF' | 'SLIDESHOW' | 'TEXT' | 'LOTTIE'

File type. TEXT covers plain-text and editor-interchange documents; LOTTIE is a JSON animation.

displayNamestring required

Display name for the uploaded file. Analysis may replace this with a short name based on the file content and this original name.

isTemporaryboolean

When true, the file is temporary. Temporary files are guaranteed to be available for 24 hours, after which they may be archived at any time. Temporary files are not analyzed (no description, transcript, or embedding will be generated), so they will not appear in search results. Defaults to false.

Response

Upload instructions

fileIdstring required

The file id to use in subsequent API calls (e.g. vg_file_...).

uploadUrlstring required

Pre-signed URL. PUT the raw file bytes to this URL to complete the upload.

Changes