Index content
The IndexesClient.IndexedAssetsClient class provides methods to manage indexed assets within an index.
Workflow
Before you begin, create an index if you don’t have one.
Upload your content using direct or multipart uploads. The platform creates an asset and return its unique identifier.
Index your content using the indexes.indexed_assets.create method.
Monitor the indexing status until it shows ready using the indexes.indexed_assets.retrieve method.
Methods
Index an asset
Description: 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
- Video analysis: Pegasus requirements
If you want to both search and analyze your videos, the most restrictive requirements apply.
Function signature and example:
Parameters:
Return value: Returns an IndexedAssetsCreateResponse object containing the unique identifier of the indexed asset.
The IndexedAssetsCreateResponse class contains the following properties:
API Reference: Index an asset
Retrieve an indexed asset
Description: This method retrieves information about an indexed asset, including its status, metadata, and optional embeddings or transcription.
Use this method to:
-
Monitor the indexing progress:
- Call this endpoint after creating an indexed asset
- Check the
statusfield until it showsready - Once ready, your content is available for search and analysis
-
Retrieve the asset metadata:
- Retrieve system metadata (duration, resolution, filename)
- Access user-defined metadata
-
Retrieve the embeddings:
- Include the
embeddingOptionparameter to retrieve video embeddings - Requires the Marengo video understanding model to be enabled in your index
- Include the
-
Retrieve transcriptions:
- Set the transcription parameter to true to retrieve spoken words from your video Function signature and example:
Parameters:
Return value: Returns an IndexedAssetDetailed object containing detailed information about the indexed asset.
The IndexedAssetDetailed class extends IndexedAsset and contains the following additional properties:
The IndexedAssetDetailed class also inherits all properties from IndexedAsset:
The IndexedAssetSystemMetadata class contains the following properties:
The HlsObject class contains the following properties:
The TranscriptionDataItem class contains the following properties:
API Reference: Retrieve an indexed asset
Update an indexed asset
Description: This method updates one or more fields of the metadata of an indexed asset. You can also delete a field by setting it to null.
Function signature and example:
Parameters:
Return value: Returns None.
API Reference: Update indexed asset
List indexed assets
Description: This method returns a list of the indexed assets in the specified index. By default, the platform returns your indexed assets sorted by creation date, with the newest at the top of the list.
Function signature and example:
Parameters:
Return value: Returns a SyncPager[IndexedAsset] object that allows you to iterate through the paginated indexed asset results.
The SyncPager[T] class contains the following properties and methods:
The IndexedAsset class contains the following properties:
API Reference: List indexed assets
Delete an indexed asset
Description: This method deletes all the information about the specified indexed asset. This action cannot be undone.
Function signature and example:
Parameters:
Return value: Returns None.
API Reference: Delete an indexed asset