Create a video indexing task
This method creates a video indexing task that uploads and indexes a video in a single operation.
You can no longer add videos to an index that has only Pegasus 1.2 enabled. When you add videos to an index that has both Marengo and Pegasus 1.2 enabled, the platform indexes them with Marengo only.
Upload options:
- Local file: Use the
video_fileparameter. - Publicly accessible URL: Use the
video_urlparameter.
Your videos must meet requirements based on your workflow:
- Search: Marengo requirements.
- Video analysis: Pegasus requirements.
- If you want to both search and analyze your videos, the most restrictive requirements apply.
- This method allows you to upload files up to 2 GB in size. To upload larger files, use the Multipart Upload API
Indexes have limits on video hours and video count. For details, see the Video hours and video count limits section.
This endpoint is rate-limited. For details, see the Rate limits page.
Authentication
Your API key.
You can find your API key on the API Keys page.
Request
This parameter indicates if the platform stores the video for streaming. When set to true, the platform stores the video, and you can retrieve its URL by calling the GET method of the /indexes/{index-id}/videos/{video-id} endpoint. You can then use this URL to access the stream over the HLS protocol.
Metadata that helps you categorize your videos. You can specify a list of keys and values. Keys are strings, and values can be a string, a number, a boolean, or an array of strings. Send an integer wider than 53 bits (-9007199254740991 to 9007199254740991), and any identifier you want preserved verbatim, as a string. Send this value as a JSON-encoded string.