Cloud AI Platform v1 API - Class IndexEndpointServiceClient (2.12.0)

public abstract class IndexEndpointServiceClient

Reference documentation and code samples for the Cloud AI Platform v1 API class IndexEndpointServiceClient.

IndexEndpointService client wrapper, for convenient use.

Inheritance

object > IndexEndpointServiceClient

Namespace

GoogleCloudGoogle.Cloud.AIPlatformV1

Assembly

Google.Cloud.AIPlatform.V1.dll

Remarks

A service for managing Vertex AI's IndexEndpoints.

Properties

CreateIndexEndpointOperationsClient

public virtual OperationsClient CreateIndexEndpointOperationsClient { get; }

The long-running operations client for CreateIndexEndpoint.

Property Value
TypeDescription
OperationsClient

DefaultEndpoint

public static string DefaultEndpoint { get; }

The default endpoint for the IndexEndpointService service, which is a host of "aiplatform.googleapis.com" and a port of 443.

Property Value
TypeDescription
string

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default IndexEndpointService scopes.

Property Value
TypeDescription
IReadOnlyListstring
Remarks

The default IndexEndpointService scopes are:

DeleteIndexEndpointOperationsClient

public virtual OperationsClient DeleteIndexEndpointOperationsClient { get; }

The long-running operations client for DeleteIndexEndpoint.

Property Value
TypeDescription
OperationsClient

DeployIndexOperationsClient

public virtual OperationsClient DeployIndexOperationsClient { get; }

The long-running operations client for DeployIndex.

Property Value
TypeDescription
OperationsClient

GrpcClient

public virtual IndexEndpointService.IndexEndpointServiceClient GrpcClient { get; }

The underlying gRPC IndexEndpointService client

Property Value
TypeDescription
IndexEndpointServiceIndexEndpointServiceClient

IAMPolicyClient

public virtual IAMPolicyClient IAMPolicyClient { get; }

The IAMPolicyClient associated with this client.

Property Value
TypeDescription
IAMPolicyClient

LocationsClient

public virtual LocationsClient LocationsClient { get; }

The LocationsClient associated with this client.

Property Value
TypeDescription
LocationsClient

MutateDeployedIndexOperationsClient

public virtual OperationsClient MutateDeployedIndexOperationsClient { get; }

The long-running operations client for MutateDeployedIndex.

Property Value
TypeDescription
OperationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
TypeDescription
ServiceMetadata

UndeployIndexOperationsClient

public virtual OperationsClient UndeployIndexOperationsClient { get; }

The long-running operations client for UndeployIndex.

Property Value
TypeDescription
OperationsClient

Methods

Create()

public static IndexEndpointServiceClient Create()

Synchronously creates a IndexEndpointServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use IndexEndpointServiceClientBuilder.

Returns
TypeDescription
IndexEndpointServiceClient

The created IndexEndpointServiceClient.

CreateAsync(CancellationToken)

public static Task<IndexEndpointServiceClient> CreateAsync(CancellationToken cancellationToken = default)

Asynchronously creates a IndexEndpointServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use IndexEndpointServiceClientBuilder.

Parameter
NameDescription
cancellationTokenCancellationToken

The CancellationToken to use while creating the client.

Returns
TypeDescription
TaskIndexEndpointServiceClient

The task representing the created IndexEndpointServiceClient.

CreateIndexEndpoint(LocationName, IndexEndpoint, CallSettings)

public virtual Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> CreateIndexEndpoint(LocationName parent, IndexEndpoint indexEndpoint, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
parentLocationName

Required. The resource name of the Location to create the IndexEndpoint in. Format: projects/{project}/locations/{location}

indexEndpointIndexEndpoint

Required. The IndexEndpoint to create.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationIndexEndpointCreateIndexEndpointOperationMetadata

The RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = IndexEndpointServiceClient.Create();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
IndexEndpoint indexEndpoint = new IndexEndpoint();
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = indexEndpointServiceClient.CreateIndexEndpoint(parent, indexEndpoint);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = indexEndpointServiceClient.PollOnceCreateIndexEndpoint(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpoint(CreateIndexEndpointRequest, CallSettings)

public virtual Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> CreateIndexEndpoint(CreateIndexEndpointRequest request, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
requestCreateIndexEndpointRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationIndexEndpointCreateIndexEndpointOperationMetadata

The RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = IndexEndpointServiceClient.Create();
// Initialize request argument(s)
CreateIndexEndpointRequest request = new CreateIndexEndpointRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    IndexEndpoint = new IndexEndpoint(),
};
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = indexEndpointServiceClient.CreateIndexEndpoint(request);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = indexEndpointServiceClient.PollOnceCreateIndexEndpoint(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpoint(string, IndexEndpoint, CallSettings)

public virtual Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> CreateIndexEndpoint(string parent, IndexEndpoint indexEndpoint, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
parentstring

Required. The resource name of the Location to create the IndexEndpoint in. Format: projects/{project}/locations/{location}

indexEndpointIndexEndpoint

Required. The IndexEndpoint to create.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
OperationIndexEndpointCreateIndexEndpointOperationMetadata

The RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = IndexEndpointServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]";
IndexEndpoint indexEndpoint = new IndexEndpoint();
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = indexEndpointServiceClient.CreateIndexEndpoint(parent, indexEndpoint);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = response.PollUntilCompleted();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = indexEndpointServiceClient.PollOnceCreateIndexEndpoint(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpointAsync(LocationName, IndexEndpoint, CallSettings)

public virtual Task<Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata>> CreateIndexEndpointAsync(LocationName parent, IndexEndpoint indexEndpoint, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
parentLocationName

Required. The resource name of the Location to create the IndexEndpoint in. Format: projects/{project}/locations/{location}

indexEndpointIndexEndpoint

Required. The IndexEndpoint to create.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationIndexEndpointCreateIndexEndpointOperationMetadata

A Task containing the RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = await IndexEndpointServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
IndexEndpoint indexEndpoint = new IndexEndpoint();
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = await indexEndpointServiceClient.CreateIndexEndpointAsync(parent, indexEndpoint);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = await indexEndpointServiceClient.PollOnceCreateIndexEndpointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpointAsync(LocationName, IndexEndpoint, CancellationToken)

public virtual Task<Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata>> CreateIndexEndpointAsync(LocationName parent, IndexEndpoint indexEndpoint, CancellationToken cancellationToken)

Creates an IndexEndpoint.

Parameters
NameDescription
parentLocationName

Required. The resource name of the Location to create the IndexEndpoint in. Format: projects/{project}/locations/{location}

indexEndpointIndexEndpoint

Required. The IndexEndpoint to create.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationIndexEndpointCreateIndexEndpointOperationMetadata

A Task containing the RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = await IndexEndpointServiceClient.CreateAsync();
// Initialize request argument(s)
LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
IndexEndpoint indexEndpoint = new IndexEndpoint();
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = await indexEndpointServiceClient.CreateIndexEndpointAsync(parent, indexEndpoint);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = await indexEndpointServiceClient.PollOnceCreateIndexEndpointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpointAsync(CreateIndexEndpointRequest, CallSettings)

public virtual Task<Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata>> CreateIndexEndpointAsync(CreateIndexEndpointRequest request, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
requestCreateIndexEndpointRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationIndexEndpointCreateIndexEndpointOperationMetadata

A Task containing the RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = await IndexEndpointServiceClient.CreateAsync();
// Initialize request argument(s)
CreateIndexEndpointRequest request = new CreateIndexEndpointRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    IndexEndpoint = new IndexEndpoint(),
};
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = await indexEndpointServiceClient.CreateIndexEndpointAsync(request);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = await indexEndpointServiceClient.PollOnceCreateIndexEndpointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpointAsync(CreateIndexEndpointRequest, CancellationToken)

public virtual Task<Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata>> CreateIndexEndpointAsync(CreateIndexEndpointRequest request, CancellationToken cancellationToken)

Creates an IndexEndpoint.

Parameters
NameDescription
requestCreateIndexEndpointRequest

The request object containing all of the parameters for the API call.

cancellationTokenCancellationToken

A CancellationToken to use for this RPC.

Returns
TypeDescription
TaskOperationIndexEndpointCreateIndexEndpointOperationMetadata

A Task containing the RPC response.

Example
// Create client
IndexEndpointServiceClient indexEndpointServiceClient = await IndexEndpointServiceClient.CreateAsync();
// Initialize request argument(s)
CreateIndexEndpointRequest request = new CreateIndexEndpointRequest
{
    ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
    IndexEndpoint = new IndexEndpoint(),
};
// Make the request
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> response = await indexEndpointServiceClient.CreateIndexEndpointAsync(request);

// Poll until the returned long-running operation is complete
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> completedResponse = await response.PollUntilCompletedAsync();
// Retrieve the operation result
IndexEndpoint result = completedResponse.Result;

// Or get the name of the operation
string operationName = response.Name;
// This name can be stored, then the long-running operation retrieved later by name
Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata> retrievedResponse = await indexEndpointServiceClient.PollOnceCreateIndexEndpointAsync(operationName);
// Check if the retrieved long-running operation has completed
if (retrievedResponse.IsCompleted)
{
    // If it has completed, then access the result
    IndexEndpoint retrievedResult = retrievedResponse.Result;
}

CreateIndexEndpointAsync(string, IndexEndpoint, CallSettings)

public virtual Task<Operation<IndexEndpoint, CreateIndexEndpointOperationMetadata>> CreateIndexEndpointAsync(string parent, IndexEndpoint indexEndpoint, CallSettings callSettings = null)

Creates an IndexEndpoint.

Parameters
NameDescription
parentstring

Required. The resource name of the Location to create the IndexEndpoint in. Format: projects/{project}/locations/{location}

indexEndpointIndexEndpoint

Required. The IndexEndpoint to create.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
TaskOperationIndexEndpointCreateIndexEndpointOperationMetadata

A Task containing the RPC response.

Example