Share via


VectorStoresAsyncClient Class

  • java.lang.Object
    • com.azure.ai.agents.persistent.VectorStoresAsyncClient

public final class VectorStoresAsyncClient

Initializes a new instance of the asynchronous VectorStores type.

Method Summary

Modifier and Type Method and Description
Mono<VectorStoreFileBatch> cancelVectorStoreFileBatch(String vectorStoreId, String batchId)

Cancel a vector store file batch.

Mono<Response<BinaryData>> cancelVectorStoreFileBatchWithResponse(String vectorStoreId, String batchId, RequestOptions requestOptions)

Cancel a vector store file batch.

Mono<VectorStore> createVectorStore()

Creates a vector store.

Mono<VectorStore> createVectorStore(List<String> fileIds, String name, VectorStoreConfiguration storeConfiguration, VectorStoreExpirationPolicy expiresAfter, VectorStoreChunkingStrategyRequest chunkingStrategy, Map<String,String> metadata)

Creates a vector store.

Mono<VectorStoreFile> createVectorStoreFile(String vectorStoreId)

Create a vector store file by attaching a file to a vector store.

Mono<VectorStoreFile> createVectorStoreFile(String vectorStoreId, String fileId, VectorStoreDataSource dataSource, VectorStoreChunkingStrategyRequest chunkingStrategy)

Create a vector store file by attaching a file to a vector store.

Mono<VectorStoreFileBatch> createVectorStoreFileBatch(String vectorStoreId)

Create a vector store file batch.

Mono<VectorStoreFileBatch> createVectorStoreFileBatch(String vectorStoreId, List<String> fileIds, List<VectorStoreDataSource> dataSources, VectorStoreChunkingStrategyRequest chunkingStrategy)

Create a vector store file batch.

Mono<Response<BinaryData>> createVectorStoreFileBatchWithResponse(String vectorStoreId, BinaryData createVectorStoreFileBatchRequest, RequestOptions requestOptions)

Create a vector store file batch.

Mono<Response<BinaryData>> createVectorStoreFileWithResponse(String vectorStoreId, BinaryData createVectorStoreFileRequest, RequestOptions requestOptions)

Create a vector store file by attaching a file to a vector store.

Mono<Response<BinaryData>> createVectorStoreWithResponse(BinaryData createVectorStoreRequest, RequestOptions requestOptions)

Creates a vector store.

Mono<Void> deleteVectorStore(String vectorStoreId)

Deletes the vector store object matching the specified ID.

Mono<Void> deleteVectorStoreFile(String vectorStoreId, String fileId)

Deletes a vector store file.

Mono<VectorStore> getVectorStore(String vectorStoreId)

Returns the vector store object matching the specified ID.

Mono<VectorStoreFile> getVectorStoreFile(String vectorStoreId, String fileId)

Retrieves a vector store file.

Mono<VectorStoreFileBatch> getVectorStoreFileBatch(String vectorStoreId, String batchId)

Retrieve a vector store file batch.

Mono<Response<BinaryData>> getVectorStoreFileBatchWithResponse(String vectorStoreId, String batchId, RequestOptions requestOptions)

Retrieve a vector store file batch.

Mono<Response<BinaryData>> getVectorStoreFileWithResponse(String vectorStoreId, String fileId, RequestOptions requestOptions)

Retrieves a vector store file.

Mono<Response<BinaryData>> getVectorStoreWithResponse(String vectorStoreId, RequestOptions requestOptions)

Returns the vector store object matching the specified ID.

PagedFlux<VectorStoreFile> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId)

Returns a list of vector store files in a batch.

PagedFlux<BinaryData> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId, RequestOptions requestOptions)

Returns a list of vector store files in a batch.

PagedFlux<VectorStoreFile> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId, VectorStoreFileStatusFilter filter, Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector store files in a batch.

PagedFlux<VectorStoreFile> listVectorStoreFiles(String vectorStoreId)

Returns a list of vector store files.

PagedFlux<BinaryData> listVectorStoreFiles(String vectorStoreId, RequestOptions requestOptions)

Returns a list of vector store files.

PagedFlux<VectorStoreFile> listVectorStoreFiles(String vectorStoreId, VectorStoreFileStatusFilter filter, Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector store files.

PagedFlux<VectorStore> listVectorStores()

Returns a list of vector stores.

PagedFlux<VectorStore> listVectorStores(Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector stores.

PagedFlux<BinaryData> listVectorStores(RequestOptions requestOptions)

Returns a list of vector stores.

Mono<VectorStore> modifyVectorStore(String vectorStoreId)

Modifies an existing vector store.

Mono<VectorStore> modifyVectorStore(String vectorStoreId, String name, VectorStoreExpirationPolicy expiresAfter, Map<String,String> metadata)

Modifies an existing vector store.

Mono<Response<BinaryData>> modifyVectorStoreWithResponse(String vectorStoreId, BinaryData modifyVectorStoreRequest, RequestOptions requestOptions)

Modifies an existing vector store.

Methods inherited from java.lang.Object

Method Details

cancelVectorStoreFileBatch

public Mono<VectorStoreFileBatch> cancelVectorStoreFileBatch(String vectorStoreId, String batchId)

Cancel a vector store file batch. This attempts to cancel the processing of files in this batch as soon as possible.

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.

Returns:

a batch of files attached to a vector store on successful completion of Mono.

cancelVectorStoreFileBatchWithResponse

public Mono<Response<BinaryData>> cancelVectorStoreFileBatchWithResponse(String vectorStoreId, String batchId, RequestOptions requestOptions)

Cancel a vector store file batch. This attempts to cancel the processing of files in this batch as soon as possible.

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/cancelled/failed) (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a batch of files attached to a vector store along with Response<T> on successful completion of Mono.

createVectorStore

public Mono<VectorStore> createVectorStore()

Creates a vector store.

Returns:

a vector store is a collection of processed files can be used by the file_search tool on successful completion of Mono.

createVectorStore

public Mono<VectorStore> createVectorStore(List<String> fileIds, String name, VectorStoreConfiguration storeConfiguration, VectorStoreExpirationPolicy expiresAfter, VectorStoreChunkingStrategyRequest chunkingStrategy, Map<String,String> metadata)

Creates a vector store.

Parameters:

fileIds - A list of file IDs that the vector store should use. Useful for tools like file_search that can access files.
name - The name of the vector store.
storeConfiguration - The vector store configuration, used when vector store is created from Azure asset URIs.
expiresAfter - Details on when this vector store expires.
chunkingStrategy - The chunking strategy used to chunk the file(s). If not set, will use the auto strategy. Only applicable if file_ids is non-empty.
metadata - A set of up to 16 key/value pairs that can be attached to an object, used for storing additional information about that object in a structured format. Keys may be up to 64 characters in length and values may be up to 512 characters in length.

Returns:

a vector store is a collection of processed files can be used by the file_search tool on successful completion of Mono.

createVectorStoreFile

public Mono<VectorStoreFile> createVectorStoreFile(String vectorStoreId)

Create a vector store file by attaching a file to a vector store.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

description of a file attached to a vector store on successful completion of Mono.

createVectorStoreFile

public Mono<VectorStoreFile> createVectorStoreFile(String vectorStoreId, String fileId, VectorStoreDataSource dataSource, VectorStoreChunkingStrategyRequest chunkingStrategy)

Create a vector store file by attaching a file to a vector store.

Parameters:

vectorStoreId - Identifier of the vector store.
fileId - Identifier of the file.
dataSource - Azure asset ID.
chunkingStrategy - The chunking strategy used to chunk the file. If not set, uses the auto strategy.

Returns:

description of a file attached to a vector store on successful completion of Mono.

createVectorStoreFileBatch

public Mono<VectorStoreFileBatch> createVectorStoreFileBatch(String vectorStoreId)

Create a vector store file batch.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

a batch of files attached to a vector store on successful completion of Mono.

createVectorStoreFileBatch

public Mono<VectorStoreFileBatch> createVectorStoreFileBatch(String vectorStoreId, List<String> fileIds, List<VectorStoreDataSource> dataSources, VectorStoreChunkingStrategyRequest chunkingStrategy)

Create a vector store file batch.

Parameters:

vectorStoreId - Identifier of the vector store.
fileIds - List of file identifiers.
dataSources - List of Azure assets.
chunkingStrategy - The chunking strategy used to chunk the file(s). If not set, will use the auto strategy.

Returns:

a batch of files attached to a vector store on successful completion of Mono.

createVectorStoreFileBatchWithResponse

public Mono<Response<BinaryData>> createVectorStoreFileBatchWithResponse(String vectorStoreId, BinaryData createVectorStoreFileBatchRequest, RequestOptions requestOptions)

Create a vector store file batch.

Request Body Schema

{
     file_ids (Optional): [
         String (Optional)
     ]
     data_sources (Optional): [
          (Optional){
             uri: String (Required)
             type: String(uri_asset/id_asset) (Required)
         }
     ]
     chunking_strategy (Optional): {
         type: String(auto/static) (Required)
     }
 }

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/cancelled/failed) (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
createVectorStoreFileBatchRequest - The createVectorStoreFileBatchRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a batch of files attached to a vector store along with Response<T> on successful completion of Mono.

createVectorStoreFileWithResponse

public Mono<Response<BinaryData>> createVectorStoreFileWithResponse(String vectorStoreId, BinaryData createVectorStoreFileRequest, RequestOptions requestOptions)

Create a vector store file by attaching a file to a vector store.

Request Body Schema

{
     file_id: String (Optional)
     data_source (Optional): {
         uri: String (Required)
         type: String(uri_asset/id_asset) (Required)
     }
     chunking_strategy (Optional): {
         type: String(auto/static) (Required)
     }
 }

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     usage_bytes: int (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/failed/cancelled) (Required)
     last_error (Required): {
         code: String(server_error/invalid_file/unsupported_file) (Required)
         message: String (Required)
     }
     chunking_strategy (Required): {
         type: String(other/static) (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
createVectorStoreFileRequest - The createVectorStoreFileRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

description of a file attached to a vector store along with Response<T> on successful completion of Mono.

createVectorStoreWithResponse

public Mono<Response<BinaryData>> createVectorStoreWithResponse(BinaryData createVectorStoreRequest, RequestOptions requestOptions)

Creates a vector store.

Request Body Schema

{
     file_ids (Optional): [
         String (Optional)
     ]
     name: String (Optional)
     configuration (Optional): {
         data_sources (Required): [
              (Required){
                 uri: String (Required)
                 type: String(uri_asset/id_asset) (Required)
             }
         ]
     }
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     chunking_strategy (Optional): {
         type: String(auto/static) (Required)
     }
     metadata (Optional): {
         String: String (Required)
     }
 }

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     name: String (Required)
     usage_bytes: int (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
     status: String(expired/in_progress/completed) (Required)
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     expires_at: Long (Optional)
     last_active_at: Long (Required)
     metadata (Required): {
         String: String (Required)
     }
 }

Parameters:

createVectorStoreRequest - The createVectorStoreRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a vector store is a collection of processed files can be used by the file_search tool along with Response<T> on successful completion of Mono.

deleteVectorStore

public Mono<Void> deleteVectorStore(String vectorStoreId)

Deletes the vector store object matching the specified ID.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

a Mono that completes when the vector store is deleted successfully.

deleteVectorStoreFile

public Mono<Void> deleteVectorStoreFile(String vectorStoreId, String fileId)

Deletes a vector store file. This removes the file‐to‐store link (does not delete the file itself).

Parameters:

vectorStoreId - Identifier of the vector store.
fileId - Identifier of the file.

Returns:

a Mono that completes when the vector store file is deleted successfully.

getVectorStore

public Mono<VectorStore> getVectorStore(String vectorStoreId)

Returns the vector store object matching the specified ID.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

a vector store is a collection of processed files can be used by the file_search tool on successful completion of Mono.

getVectorStoreFile

public Mono<VectorStoreFile> getVectorStoreFile(String vectorStoreId, String fileId)

Retrieves a vector store file.

Parameters:

vectorStoreId - Identifier of the vector store.
fileId - Identifier of the file.

Returns:

description of a file attached to a vector store on successful completion of Mono.

getVectorStoreFileBatch

public Mono<VectorStoreFileBatch> getVectorStoreFileBatch(String vectorStoreId, String batchId)

Retrieve a vector store file batch.

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.

Returns:

a batch of files attached to a vector store on successful completion of Mono.

getVectorStoreFileBatchWithResponse

public Mono<Response<BinaryData>> getVectorStoreFileBatchWithResponse(String vectorStoreId, String batchId, RequestOptions requestOptions)

Retrieve a vector store file batch.

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/cancelled/failed) (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a batch of files attached to a vector store along with Response<T> on successful completion of Mono.

getVectorStoreFileWithResponse

public Mono<Response<BinaryData>> getVectorStoreFileWithResponse(String vectorStoreId, String fileId, RequestOptions requestOptions)

Retrieves a vector store file.

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     usage_bytes: int (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/failed/cancelled) (Required)
     last_error (Required): {
         code: String(server_error/invalid_file/unsupported_file) (Required)
         message: String (Required)
     }
     chunking_strategy (Required): {
         type: String(other/static) (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
fileId - Identifier of the file.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

description of a file attached to a vector store along with Response<T> on successful completion of Mono.

getVectorStoreWithResponse

public Mono<Response<BinaryData>> getVectorStoreWithResponse(String vectorStoreId, RequestOptions requestOptions)

Returns the vector store object matching the specified ID.

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     name: String (Required)
     usage_bytes: int (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
     status: String(expired/in_progress/completed) (Required)
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     expires_at: Long (Optional)
     last_active_at: Long (Required)
     metadata (Required): {
         String: String (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a vector store is a collection of processed files can be used by the file_search tool along with Response<T> on successful completion of Mono.

listVectorStoreFileBatchFiles

public PagedFlux<VectorStoreFile> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId)

Returns a list of vector store files in a batch.

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStoreFileBatchFiles

public PagedFlux<BinaryData> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId, RequestOptions requestOptions)

Returns a list of vector store files in a batch.

Query Parameters

| ------ | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name   | Type    | Required | Description                                                                                                                                                                                                                                                                           |
| filter | String  | No       | Filter by file status. Allowed values: "in\_progress", "completed", "failed", "cancelled".                                                                                                                                                                                            |
| limit  | Integer | No       | A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.                                                                                                                                                                            |
| order  | String  | No       | Sort order by the created\_at timestamp of the objects. asc for ascending order and desc for descending order. Allowed values: "asc", "desc".                                                                                                                                         |
| after  | String  | No       | A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include after=obj\_foo in order to fetch the next page of the list.       |
| before | String  | No       | A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include before=obj\_foo in order to fetch the previous page of the list. |

You can add these to a request with RequestOptions#addQueryParam

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     usage_bytes: int (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/failed/cancelled) (Required)
     last_error (Required): {
         code: String(server_error/invalid_file/unsupported_file) (Required)
         message: String (Required)
     }
     chunking_strategy (Required): {
         type: String(other/static) (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStoreFileBatchFiles

public PagedFlux<VectorStoreFile> listVectorStoreFileBatchFiles(String vectorStoreId, String batchId, VectorStoreFileStatusFilter filter, Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector store files in a batch.

Parameters:

vectorStoreId - Identifier of the vector store.
batchId - Identifier of the file batch.
filter - Filter by file status.
limit - A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.
order - Sort order by the created_at timestamp of the objects. asc for ascending order and desc for descending order.
after - A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include after=obj_foo in order to fetch the next page of the list.
before - A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include before=obj_foo in order to fetch the previous page of the list.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStoreFiles

public PagedFlux<VectorStoreFile> listVectorStoreFiles(String vectorStoreId)

Returns a list of vector store files.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStoreFiles

public PagedFlux<BinaryData> listVectorStoreFiles(String vectorStoreId, RequestOptions requestOptions)

Returns a list of vector store files.

Query Parameters

| ------ | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name   | Type    | Required | Description                                                                                                                                                                                                                                                                           |
| filter | String  | No       | Filter by file status. Allowed values: "in\_progress", "completed", "failed", "cancelled".                                                                                                                                                                                            |
| limit  | Integer | No       | A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.                                                                                                                                                                            |
| order  | String  | No       | Sort order by the created\_at timestamp of the objects. asc for ascending order and desc for descending order. Allowed values: "asc", "desc".                                                                                                                                         |
| after  | String  | No       | A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include after=obj\_foo in order to fetch the next page of the list.       |
| before | String  | No       | A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include before=obj\_foo in order to fetch the previous page of the list. |

You can add these to a request with RequestOptions#addQueryParam

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     usage_bytes: int (Required)
     created_at: long (Required)
     vector_store_id: String (Required)
     status: String(in_progress/completed/failed/cancelled) (Required)
     last_error (Required): {
         code: String(server_error/invalid_file/unsupported_file) (Required)
         message: String (Required)
     }
     chunking_strategy (Required): {
         type: String(other/static) (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStoreFiles

public PagedFlux<VectorStoreFile> listVectorStoreFiles(String vectorStoreId, VectorStoreFileStatusFilter filter, Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector store files.

Parameters:

vectorStoreId - Identifier of the vector store.
filter - Filter by file status.
limit - A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.
order - Sort order by the created_at timestamp of the objects. asc for ascending order and desc for descending order.
after - A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include after=obj_foo in order to fetch the next page of the list.
before - A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include before=obj_foo in order to fetch the previous page of the list.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStores

public PagedFlux<VectorStore> listVectorStores()

Returns a list of vector stores.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStores

public PagedFlux<VectorStore> listVectorStores(Integer limit, ListSortOrder order, String after, String before)

Returns a list of vector stores.

Parameters:

limit - A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.
order - Sort order by the created_at timestamp of the objects. asc for ascending order and desc for descending order.
after - A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include after=obj_foo in order to fetch the next page of the list.
before - A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include before=obj_foo in order to fetch the previous page of the list.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

listVectorStores

public PagedFlux<BinaryData> listVectorStores(RequestOptions requestOptions)

Returns a list of vector stores.

Query Parameters

| ------ | ------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Name   | Type    | Required | Description                                                                                                                                                                                                                                                                           |
| limit  | Integer | No       | A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.                                                                                                                                                                            |
| order  | String  | No       | Sort order by the created\_at timestamp of the objects. asc for ascending order and desc for descending order. Allowed values: "asc", "desc".                                                                                                                                         |
| after  | String  | No       | A cursor for use in pagination. after is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include after=obj\_foo in order to fetch the next page of the list.       |
| before | String  | No       | A cursor for use in pagination. before is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj\_foo, your subsequent call can include before=obj\_foo in order to fetch the previous page of the list. |

You can add these to a request with RequestOptions#addQueryParam

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     name: String (Required)
     usage_bytes: int (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
     status: String(expired/in_progress/completed) (Required)
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     expires_at: Long (Optional)
     last_active_at: Long (Required)
     metadata (Required): {
         String: String (Required)
     }
 }

Parameters:

requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

the response data for a requested list of items as paginated response with PagedFlux<T>.

modifyVectorStore

public Mono<VectorStore> modifyVectorStore(String vectorStoreId)

Modifies an existing vector store.

Parameters:

vectorStoreId - Identifier of the vector store.

Returns:

a vector store is a collection of processed files can be used by the file_search tool on successful completion of Mono.

modifyVectorStore

public Mono<VectorStore> modifyVectorStore(String vectorStoreId, String name, VectorStoreExpirationPolicy expiresAfter, Map<String,String> metadata)

Modifies an existing vector store.

Parameters:

vectorStoreId - Identifier of the vector store.
name - The name of the vector store.
expiresAfter - Details on when this vector store expires.
metadata - A set of up to 16 key/value pairs that can be attached to an object, used for storing additional information about that object in a structured format. Keys may be up to 64 characters in length and values may be up to 512 characters in length.

Returns:

a vector store is a collection of processed files can be used by the file_search tool on successful completion of Mono.

modifyVectorStoreWithResponse

public Mono<Response<BinaryData>> modifyVectorStoreWithResponse(String vectorStoreId, BinaryData modifyVectorStoreRequest, RequestOptions requestOptions)

Modifies an existing vector store.

Request Body Schema

{
     name: String (Optional)
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     metadata (Optional): {
         String: String (Required)
     }
 }

Response Body Schema

{
     id: String (Required)
     object: String (Required)
     created_at: long (Required)
     name: String (Required)
     usage_bytes: int (Required)
     file_counts (Required): {
         in_progress: int (Required)
         completed: int (Required)
         failed: int (Required)
         cancelled: int (Required)
         total: int (Required)
     }
     status: String(expired/in_progress/completed) (Required)
     expires_after (Optional): {
         anchor: String(last_active_at) (Required)
         days: int (Required)
     }
     expires_at: Long (Optional)
     last_active_at: Long (Required)
     metadata (Required): {
         String: String (Required)
     }
 }

Parameters:

vectorStoreId - Identifier of the vector store.
modifyVectorStoreRequest - The modifyVectorStoreRequest parameter.
requestOptions - The options to configure the HTTP request before HTTP client sends it.

Returns:

a vector store is a collection of processed files can be used by the file_search tool along with Response<T> on successful completion of Mono.

Applies to