Example #1
0
def sample_update_index_endpoint():
    # Create a client
    client = aiplatform_v1beta1.IndexEndpointServiceClient()

    # Initialize request argument(s)
    index_endpoint = aiplatform_v1beta1.IndexEndpoint()
    index_endpoint.display_name = "display_name_value"

    request = aiplatform_v1beta1.UpdateIndexEndpointRequest(
        index_endpoint=index_endpoint, )

    # Make the request
    response = client.update_index_endpoint(request=request)

    # Handle the response
    print(response)
def sample_create_index_endpoint():
    # Create a client
    client = aiplatform_v1beta1.IndexEndpointServiceClient()

    # Initialize request argument(s)
    index_endpoint = aiplatform_v1beta1.IndexEndpoint()
    index_endpoint.display_name = "display_name_value"

    request = aiplatform_v1beta1.CreateIndexEndpointRequest(
        parent="parent_value",
        index_endpoint=index_endpoint,
    )

    # Make the request
    operation = client.create_index_endpoint(request=request)

    print("Waiting for operation to complete...")

    response = operation.result()

    # Handle the response
    print(response)