Yandex Cloud
Search
Contact UsGet started
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • AI for business
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
  • Pricing
  • Customer Stories
  • Documentation
  • Blog
© 2025 Direct Cursus Technology L.L.C.
Yandex AI Studio
    • About Yandex AI Studio
    • Yandex Workflows
    • Quotas and limits
    • Terms and definitions
  • Compatibility with OpenAI
    • About Yandex Cloud ML SDK
      • Overview
        • Overview
        • Models domain
        • Assistants domain
        • Tools domain
        • Files domain
        • Threads domain
        • Runs domain
        • Search indexes domain
        • Search API domain
        • Datasets domain
        • Tuning domain
        • Batch domain
        • Chat domain
      • Authentication
      • Request retries
  • Access management
  • Pricing policy
  • Audit Trails events
  • Public materials
  • Release notes

In this article:

  • class yandex_cloud_ml_sdk._search_indexes.domain.AsyncSearchIndexes
  • class yandex_cloud_ml_sdk._search_indexes.search_index.AsyncSearchIndex
  1. Yandex Cloud ML SDK
  2. SDK reference
  3. Async SDK
  4. Search indexes domain

Search indexes domain

Written by
Yandex Cloud
Updated at November 7, 2025
  • class yandex_cloud_ml_sdk._search_indexes.domain.AsyncSearchIndexes
  • class yandex_cloud_ml_sdk._search_indexes.search_index.AsyncSearchIndex

class yandexcloudmlsdk.searchindexes.domain.AsyncSearchIndexesclass yandex_cloud_ml_sdk._search_indexes.domain.AsyncSearchIndexes

A class for search indexes. It is a part of Assistants API and it provides the foundation for creating and managing search indexes.

async create_deferred(files, *, index_type=Undefined, name=Undefined, description=Undefined, labels=Undefined, ttl_days=Undefined, expiration_policy=Undefined, timeout=60)

Create a deferred search index.

It returns an operation that can be used to track the creation process.

Parameters

  • files (str | BaseFile | Iterable[BaseFile] | Iterable[str]) – the files to be indexed.
  • index_type (BaseSearchIndexType | Undefined) – the type of the search index.
  • name (str | Undefined) – the name of the search index.
  • description (str | Undefined) – a description for the search index.
  • labels (dict[str, str] | Undefined) – a set of labels for the search index.
  • ttl_days (int | Undefined) – time-to-live in days for the search index.
  • expiration_policy (ExpirationPolicy | Literal[1, 2] | ~typing.Literal['STATIC', 'SINCE_LAST_ACTIVE'] | ~typing.Literal['static', 'since_last_active'] | ~yandex_cloud_ml_sdk._types.misc.Undefined) – expiration policy for the file. Assepts for passing static or since_last_active strings. Should be defined if ttl_days has been defined, otherwise both parameters should be undefined.
  • timeout (float) – the time to wait for the operation to complete. Defaults to 60 seconds.

Return type

AsyncOperation[AsyncSearchIndex]

async get(search_index_id, *, timeout=60)

Retrieve a search index by its id.

This method fetches an already created search index using its unique identifier.

Parameters

  • search_index_id (str) – the unique identifier of the search index to retrieve.
  • timeout (float) – the time to wait for the operation to complete. Defaults to 60 seconds.

Return type

AsyncSearchIndex

async list(*, page_size=Undefined, timeout=60)

List search indexes in the specified folder.

This method retrieves a list of search indexes. It continues to fetch search indexes until there are no more available.

Parameters

  • page_size (int | Undefined) – the maximum number of search indexes to return per page.
  • timeout (float) – the time to wait for the operation to complete. Defaults to 60 seconds.

Return type

AsyncIterator[AsyncSearchIndex]

class yandexcloudmlsdk.searchindexes.searchindex.AsyncSearchIndexclass yandex_cloud_ml_sdk._search_indexes.search_index.AsyncSearchIndex

async update(*, name=Undefined, description=Undefined, labels=Undefined, ttl_days=Undefined, expiration_policy=Undefined, timeout=60)

Updates the search index with the provided parameters.

Parameters

  • name (str | Undefined) – the name of the search index.
  • description (str | Undefined) – a description for the search index.
  • labels (dict[str, str] | Undefined) – a set of labels for the search index.
  • ttl_days (int | Undefined) – time-to-live in days for the search index.
  • expiration_policy (ExpirationPolicy | Literal[1, 2] | ~typing.Literal['STATIC', 'SINCE_LAST_ACTIVE'] | ~typing.Literal['static', 'since_last_active'] | ~yandex_cloud_ml_sdk._types.misc.Undefined) – expiration policy for the search index.
  • timeout (float) – the time to wait for the update request. Defaults to 60 seconds.

Return type

Self

async delete(*, timeout=60)

Deletes the search index.

Parameters

timeout (float) – the time to wait for the delete request. Defaults to 60 seconds.

Return type

None

async get_file(file_id, *, timeout=60)

Retrieves a file associated with the search index.

Parameters

  • file_id (str) – the ID of the file to retrieve.
  • timeout (float) – the time to wait for the get request. Defaults to 60 seconds.

Return type

SearchIndexFile

async list_files(*, page_size=Undefined, timeout=60)

Lists all files associated with the search index.

Parameters

  • page_size (int | Undefined) – the number of files to retrieve per page.
  • timeout (float) – the time to wait for the list request. Defaults to 60 seconds.

Return type

AsyncIterator[SearchIndexFile]

async add_files_deferred(files, *, timeout=60)

Adds files to the search index in a deferred manner.

Parameters

  • files (str | BaseFile | Iterable[BaseFile] | Iterable[str]) – the files to add to the search index.
  • timeout (float) – the time to wait for the add files request. Defaults to 60 seconds.

Return type

AsyncOperation[tuple[SearchIndexFile, …]]

folder_id: str

the ID of the folder

name: str | None

the new name for the search index

description: str | None

the new description for the search index

created_by: str

the user who created the search index

created_at: datetime

the timestamp when the search index was created

updated_by: str

the user who last updated the search index

updated_at: datetime

the timestamp when the search index was last updated

expires_at: datetime

the expiration date and time of the search index

labels: dict[str, str] | None

a dictionary of labels to associate with the search index

index_type: BaseSearchIndexType

the type of the search index

expiration_config: ExpirationConfig

id: str

Was the article helpful?

Previous
Runs domain
Next
Search API domain
© 2025 Direct Cursus Technology L.L.C.