Index an asset

This method indexes an uploaded asset to make it searchable and analyzable. Indexing processes your content and extracts information that enables the platform to search and analyze your videos. This operation is asynchronous. The platform returns an indexed asset ID immediately and processes your content in the background. Monitor the indexing status to know when your content is ready to use. Your asset must meet the requirements based on your workflow: - **Search**: [Marengo requirements](/v1.3/docs/concepts/models/marengo#video-file-requirements) - **Video analysis**: [Pegasus requirements](/v1.3/docs/concepts/models/pegasus#input-requirements). If you want to both search and analyze your videos, the most restrictive requirements apply.

Authentication

x-api-keystring
Your API key. <Note title="Note"> You can find your API key on the <a href="https://playground.twelvelabs.io/dashboard/api-key" target="_blank">API Key</a> page. </Note>

Path Parameters

index-idstringRequired
The unique identifier of the index to which the asset will be indexed.

Request

This endpoint expects an object.
asset_idstringRequired
The unique identifier of the asset to index.
enable_video_streambooleanOptionalDefaults to false
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`](/v1.3/api-reference/videos/retrieve) method of the `/indexes/{index-id}/indexed-assets/{indexed-asset-id}` endpoint. You can then use this URL to access the stream over the <a href="https://en.wikipedia.org/wiki/HTTP_Live_Streaming" target="_blank">HLS</a> protocol.

Response

The indexing request has been accepted and is processing.
_idstring or null
The unique identifier of the indexed asset. Use it to monitor the indexing progress.

Errors