1.0.0-beta25 (latest) 1.0.0-beta24

    public abstract class ControlServiceClient

Reference documentation and code samples for the Discovery Engine v1beta API class ControlServiceClient.

ControlService client wrapper, for convenient use.

## Inheritance

[object](https://learn.microsoft.com/dotnet/api/system.object) \> ControlServiceClient

## Inherited Members

[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) [object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) [object.MemberwiseClone()](https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone) [object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)

## Derived Types

[ControlServiceClientImpl](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClientImpl)

## Namespace

[Google.Cloud.DiscoveryEngine.V1Beta](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta)

## Assembly

Google.Cloud.DiscoveryEngine.V1Beta.dll

## Remarks

Service for performing CRUD operations on Controls.
Controls allow for custom logic to be implemented in the serving path.
Controls need to be attached to a Serving Config to be considered during a
request.

## Properties

### DefaultEndpoint

    public static string DefaultEndpoint { get; }

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

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.string` |   |

### DefaultScopes

    public static IReadOnlyList<string> DefaultScopes { get; }

The default ControlService scopes.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.collections.generic.ireadonlylist-1https://learn.microsoft.com/dotnet/api/system.string` |   |

**Remarks** The default ControlService scopes are:

- <https://www.googleapis.com/auth/cloud-platform>
- <https://www.googleapis.com/auth/discoveryengine.readwrite>
- <https://www.googleapis.com/auth/discoveryengine.serving.readwrite>

### GrpcClient

    public virtual ControlService.ControlServiceClient GrpcClient { get; }

The underlying gRPC ControlService client

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServicehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlService.ControlServiceClient` |   |

### LocationsClient

    public virtual LocationsClient LocationsClient { get; }

The [LocationsClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Location/latest/Google.Cloud.Location.LocationsClient.html) associated with this client.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Location/latest/Google.Cloud.Location.LocationsClient.html` |   |

### ServiceMetadata

    public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.ServiceMetadata.html` |   |

## Methods

### Create()

    public static ControlServiceClient Create()

Synchronously creates a [ControlServiceClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient) using the default credentials, endpoint and
settings. To specify custom credentials or other settings, use [ControlServiceClientBuilder](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClientBuilder).

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient` | The created [ControlServiceClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient). |

### CreateAsync(CancellationToken)

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

Asynchronously creates a [ControlServiceClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient) using the default credentials, endpoint and
settings. To specify custom credentials or other settings, use [ControlServiceClientBuilder](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClientBuilder).

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` The [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use while creating the client. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient` | The task representing the created [ControlServiceClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient). |

### CreateControl(CreateControlRequest, CallSettings)

    public virtual Control CreateControl(CreateControlRequest request, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.CreateControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    CreateControlRequest request = new CreateControlRequest
    {
        ParentAsEngineName = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]"),
        Control = new Control(),
        ControlId = "",
    };
    // Make the request
    Control response = controlServiceClient.CreateControl(request);

### CreateControl(DataStoreName, Control, string, CallSettings)

    public virtual Control CreateControl(DataStoreName parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DataStoreName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    DataStoreName parent = DataStoreName.FromProjectLocationDataStore("[PROJECT]", "[LOCATION]", "[DATA_STORE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = controlServiceClient.CreateControl(parent, control, controlId);

### CreateControl(EngineName, Control, string, CallSettings)

    public virtual Control CreateControl(EngineName parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.EngineName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    EngineName parent = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = controlServiceClient.CreateControl(parent, control, controlId);

### CreateControl(string, Control, string, CallSettings)

    public virtual Control CreateControl(string parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]/collections/[COLLECTION]/engines/[ENGINE]";
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = controlServiceClient.CreateControl(parent, control, controlId);

### CreateControlAsync(CreateControlRequest, CallSettings)

    public virtual Task<Control> CreateControlAsync(CreateControlRequest request, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.CreateControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    CreateControlRequest request = new CreateControlRequest
    {
        ParentAsEngineName = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]"),
        Control = new Control(),
        ControlId = "",
    };
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(request);

### CreateControlAsync(CreateControlRequest, CancellationToken)

    public virtual Task<Control> CreateControlAsync(CreateControlRequest request, CancellationToken cancellationToken)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.CreateControlRequest` The request object containing all of the parameters for the API call. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    CreateControlRequest request = new CreateControlRequest
    {
        ParentAsEngineName = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]"),
        Control = new Control(),
        ControlId = "",
    };
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(request);

### CreateControlAsync(DataStoreName, Control, string, CallSettings)

    public virtual Task<Control> CreateControlAsync(DataStoreName parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DataStoreName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    DataStoreName parent = DataStoreName.FromProjectLocationDataStore("[PROJECT]", "[LOCATION]", "[DATA_STORE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### CreateControlAsync(DataStoreName, Control, string, CancellationToken)

    public virtual Task<Control> CreateControlAsync(DataStoreName parent, Control control, string controlId, CancellationToken cancellationToken)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DataStoreName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    DataStoreName parent = DataStoreName.FromProjectLocationDataStore("[PROJECT]", "[LOCATION]", "[DATA_STORE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### CreateControlAsync(EngineName, Control, string, CallSettings)

    public virtual Task<Control> CreateControlAsync(EngineName parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.EngineName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    EngineName parent = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### CreateControlAsync(EngineName, Control, string, CancellationToken)

    public virtual Task<Control> CreateControlAsync(EngineName parent, Control control, string controlId, CancellationToken cancellationToken)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.EngineName` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    EngineName parent = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]");
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### CreateControlAsync(string, Control, string, CallSettings)

    public virtual Task<Control> CreateControlAsync(string parent, Control control, string controlId, CallSettings callSettings = null)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]/collections/[COLLECTION]/engines/[ENGINE]";
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### CreateControlAsync(string, Control, string, CancellationToken)

    public virtual Task<Control> CreateControlAsync(string parent, Control control, string controlId, CancellationToken cancellationToken)

Creates a Control.

By default 1000 controls are allowed for a data store.
A request can be submitted to adjust this limit.
If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to create
already exists, an ALREADY_EXISTS error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Full resource name of parent data store. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to create. |
| `controlId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID to use for the Control, which will become the final component of the Control's resource name. This value must be within 1-63 characters. Valid characters are /\[a-z\]\[0-9\]-_/. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]/collections/[COLLECTION]/engines/[ENGINE]";
    Control control = new Control();
    string controlId = "";
    // Make the request
    Control response = await controlServiceClient.CreateControlAsync(parent, control, controlId);

### DeleteControl(ControlName, CallSettings)

    public virtual void DeleteControl(ControlName name, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    controlServiceClient.DeleteControl(name);

### DeleteControl(DeleteControlRequest, CallSettings)

    public virtual void DeleteControl(DeleteControlRequest request, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DeleteControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    DeleteControlRequest request = new DeleteControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    controlServiceClient.DeleteControl(request);

### DeleteControl(string, CallSettings)

    public virtual void DeleteControl(string name, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    controlServiceClient.DeleteControl(name);

### DeleteControlAsync(ControlName, CallSettings)

    public virtual Task DeleteControlAsync(ControlName name, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    await controlServiceClient.DeleteControlAsync(name);

### DeleteControlAsync(ControlName, CancellationToken)

    public virtual Task DeleteControlAsync(ControlName name, CancellationToken cancellationToken)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    await controlServiceClient.DeleteControlAsync(name);

### DeleteControlAsync(DeleteControlRequest, CallSettings)

    public virtual Task DeleteControlAsync(DeleteControlRequest request, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DeleteControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    DeleteControlRequest request = new DeleteControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    await controlServiceClient.DeleteControlAsync(request);

### DeleteControlAsync(DeleteControlRequest, CancellationToken)

    public virtual Task DeleteControlAsync(DeleteControlRequest request, CancellationToken cancellationToken)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DeleteControlRequest` The request object containing all of the parameters for the API call. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    DeleteControlRequest request = new DeleteControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    await controlServiceClient.DeleteControlAsync(request);

### DeleteControlAsync(string, CallSettings)

    public virtual Task DeleteControlAsync(string name, CallSettings callSettings = null)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    await controlServiceClient.DeleteControlAsync(name);

### DeleteControlAsync(string, CancellationToken)

    public virtual Task DeleteControlAsync(string name, CancellationToken cancellationToken)

Deletes a Control.

If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to delete
does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to delete. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    await controlServiceClient.DeleteControlAsync(name);

### GetControl(ControlName, CallSettings)

    public virtual Control GetControl(ControlName name, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    Control response = controlServiceClient.GetControl(name);

### GetControl(GetControlRequest, CallSettings)

    public virtual Control GetControl(GetControlRequest request, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.GetControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    GetControlRequest request = new GetControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    Control response = controlServiceClient.GetControl(request);

### GetControl(string, CallSettings)

    public virtual Control GetControl(string name, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    Control response = controlServiceClient.GetControl(name);

### GetControlAsync(ControlName, CallSettings)

    public virtual Task<Control> GetControlAsync(ControlName name, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(name);

### GetControlAsync(ControlName, CancellationToken)

    public virtual Task<Control> GetControlAsync(ControlName name, CancellationToken cancellationToken)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlName` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    ControlName name = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]");
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(name);

### GetControlAsync(GetControlRequest, CallSettings)

    public virtual Task<Control> GetControlAsync(GetControlRequest request, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.GetControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    GetControlRequest request = new GetControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(request);

### GetControlAsync(GetControlRequest, CancellationToken)

    public virtual Task<Control> GetControlAsync(GetControlRequest request, CancellationToken cancellationToken)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.GetControlRequest` The request object containing all of the parameters for the API call. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    GetControlRequest request = new GetControlRequest
    {
        ControlName = ControlName.FromProjectLocationDataStoreControl("[PROJECT]", "[LOCATION]", "[DATA_STORE]", "[CONTROL]"),
    };
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(request);

### GetControlAsync(string, CallSettings)

    public virtual Task<Control> GetControlAsync(string name, CallSettings callSettings = null)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(name);

### GetControlAsync(string, CancellationToken)

    public virtual Task<Control> GetControlAsync(string name, CancellationToken cancellationToken)

Gets a Control.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource name of the Control to get. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}/controls/{control_id}` |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/dataStores/[DATA_STORE]/controls/[CONTROL]";
    // Make the request
    Control response = await controlServiceClient.GetControlAsync(name);

### ListControls(DataStoreName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListControlsResponse, Control> ListControls(DataStoreName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DataStoreName` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    DataStoreName parent = DataStoreName.FromProjectLocationDataStore("[PROJECT]", "[LOCATION]", "[DATA_STORE]");
    // Make the request
    PagedEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControls(parent);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = response.ReadPage(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControls(EngineName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListControlsResponse, Control> ListControls(EngineName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.EngineName` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    EngineName parent = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]");
    // Make the request
    PagedEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControls(parent);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = response.ReadPage(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControls(ListControlsRequest, CallSettings)

    public virtual PagedEnumerable<ListControlsResponse, Control> ListControls(ListControlsRequest request, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    ListControlsRequest request = new ListControlsRequest
    {
        ParentAsEngineName = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]"),
        Filter = "",
    };
    // Make the request
    PagedEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControls(request);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = response.ReadPage(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControls(string, string, int?, CallSettings)

    public virtual PagedEnumerable<ListControlsResponse, Control> ListControls(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]/collections/[COLLECTION]/engines/[ENGINE]";
    // Make the request
    PagedEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControls(parent);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = response.ReadPage(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControlsAsync(DataStoreName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListControlsResponse, Control> ListControlsAsync(DataStoreName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.DataStoreName` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedAsyncEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable asynchronous sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    DataStoreName parent = DataStoreName.FromProjectLocationDataStore("[PROJECT]", "[LOCATION]", "[DATA_STORE]");
    // Make the request
    PagedAsyncEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControlsAsync(parent);

    // Iterate over all response items, lazily performing RPCs as required
    await foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = await response.ReadPageAsync(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControlsAsync(EngineName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListControlsResponse, Control> ListControlsAsync(EngineName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.EngineName` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedAsyncEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable asynchronous sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    EngineName parent = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]");
    // Make the request
    PagedAsyncEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControlsAsync(parent);

    // Iterate over all response items, lazily performing RPCs as required
    await foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = await response.ReadPageAsync(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControlsAsync(ListControlsRequest, CallSettings)

    public virtual PagedAsyncEnumerable<ListControlsResponse, Control> ListControlsAsync(ListControlsRequest request, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedAsyncEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable asynchronous sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    ListControlsRequest request = new ListControlsRequest
    {
        ParentAsEngineName = EngineName.FromProjectLocationCollectionEngine("[PROJECT]", "[LOCATION]", "[COLLECTION]", "[ENGINE]"),
        Filter = "",
    };
    // Make the request
    PagedAsyncEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControlsAsync(request);

    // Iterate over all response items, lazily performing RPCs as required
    await foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = await response.ReadPageAsync(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ListControlsAsync(string, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListControlsResponse, Control> ListControlsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists all Controls by their parent
\[DataStore\]\[google.cloud.discoveryengine.v1beta.DataStore\].

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The data store resource name. Format: `projects/{project}/locations/{location}/collections/{collection_id}/dataStores/{data_store_id}` or `projects/{project}/locations/{location}/collections/{collection_id}/engines/{engine_id}`. |
| `pageToken` | `https://learn.microsoft.com/dotnet/api/system.string` The token returned from the previous request. A value of `null` or an empty string retrieves the first page. |
| `pageSize` | `https://learn.microsoft.com/dotnet/api/system.int32` The size of page to request. The response will not be larger than this, but may be smaller. A value of `null` or `0` uses a server-defined page size. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.PagedAsyncEnumerable-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ListControlsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A pageable asynchronous sequence of [Control](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control) resources. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]/collections/[COLLECTION]/engines/[ENGINE]";
    // Make the request
    PagedAsyncEnumerable<ListControlsResponse, Control> response = controlServiceClient.ListControlsAsync(parent);

    // Iterate over all response items, lazily performing RPCs as required
    await foreach (Control item in response)
    {
        // Do something with each item
        Console.WriteLine(item);
    }

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await foreach (ListControlsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Control item in page)
        {
            // Do something with each item
            Console.WriteLine(item);
        }
    }

    // Or retrieve a single page of known size (unless it's the final page), performing as many RPCs as required
    int pageSize = 10;
    Page<Control> singlePage = await response.ReadPageAsync(pageSize);
    // Do something with the page of items
    Console.WriteLine($"A page of {pageSize} results (unless it's the final page):");
    foreach (Control item in singlePage)
    {
        // Do something with each item
        Console.WriteLine(item);
    }
    // Store the pageToken, for when the next page is required.
    string nextPageToken = singlePage.NextPageToken;

### ShutdownDefaultChannelsAsync()

    public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by [Create()](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient#Google_Cloud_DiscoveryEngine_V1Beta_ControlServiceClient_Create) and
[CreateAsync(CancellationToken)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient#Google_Cloud_DiscoveryEngine_V1Beta_ControlServiceClient_CreateAsync_System_Threading_CancellationToken_). Channels which weren't automatically created are not
affected.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task` | A task representing the asynchronous shutdown operation. |

**Remarks** After calling this method, further calls to [Create()](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient#Google_Cloud_DiscoveryEngine_V1Beta_ControlServiceClient_Create) and
[CreateAsync(CancellationToken)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.ControlServiceClient#Google_Cloud_DiscoveryEngine_V1Beta_ControlServiceClient_CreateAsync_System_Threading_CancellationToken_) will create new channels, which could in turn be shut down
by another call to this method.

### UpdateControl(Control, FieldMask, CallSettings)

    public virtual Control UpdateControl(Control control, FieldMask updateMask, CallSettings callSettings = null)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to update. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. Indicates which fields in the provided \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to update. The following are NOT supported: - \[Control.name\]\[google.cloud.discoveryengine.v1beta.Control.name\] - \[Control.solution_type\]\[google.cloud.discoveryengine.v1beta.Control.solution_type\] If not set or empty, all supported fields are updated. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    Control control = new Control();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Control response = controlServiceClient.UpdateControl(control, updateMask);

### UpdateControl(UpdateControlRequest, CallSettings)

    public virtual Control UpdateControl(UpdateControlRequest request, CallSettings callSettings = null)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.UpdateControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | The RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = ControlServiceClient.Create();
    // Initialize request argument(s)
    UpdateControlRequest request = new UpdateControlRequest
    {
        Control = new Control(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Control response = controlServiceClient.UpdateControl(request);

### UpdateControlAsync(Control, FieldMask, CallSettings)

    public virtual Task<Control> UpdateControlAsync(Control control, FieldMask updateMask, CallSettings callSettings = null)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to update. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. Indicates which fields in the provided \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to update. The following are NOT supported: - \[Control.name\]\[google.cloud.discoveryengine.v1beta.Control.name\] - \[Control.solution_type\]\[google.cloud.discoveryengine.v1beta.Control.solution_type\] If not set or empty, all supported fields are updated. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    Control control = new Control();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Control response = await controlServiceClient.UpdateControlAsync(control, updateMask);

### UpdateControlAsync(Control, FieldMask, CancellationToken)

    public virtual Task<Control> UpdateControlAsync(Control control, FieldMask updateMask, CancellationToken cancellationToken)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `control` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` Required. The Control to update. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. Indicates which fields in the provided \[Control\]\[google.cloud.discoveryengine.v1beta.Control\] to update. The following are NOT supported: - \[Control.name\]\[google.cloud.discoveryengine.v1beta.Control.name\] - \[Control.solution_type\]\[google.cloud.discoveryengine.v1beta.Control.solution_type\] If not set or empty, all supported fields are updated. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    Control control = new Control();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Control response = await controlServiceClient.UpdateControlAsync(control, updateMask);

### UpdateControlAsync(UpdateControlRequest, CallSettings)

    public virtual Task<Control> UpdateControlAsync(UpdateControlRequest request, CallSettings callSettings = null)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.UpdateControlRequest` The request object containing all of the parameters for the API call. |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    UpdateControlRequest request = new UpdateControlRequest
    {
        Control = new Control(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Control response = await controlServiceClient.UpdateControlAsync(request);

### UpdateControlAsync(UpdateControlRequest, CancellationToken)

    public virtual Task<Control> UpdateControlAsync(UpdateControlRequest request, CancellationToken cancellationToken)

Updates a Control.

\[Control\]\[google.cloud.discoveryengine.v1beta.Control\] action type cannot
be changed. If the \[Control\]\[google.cloud.discoveryengine.v1beta.Control\]
to update does not exist, a NOT_FOUND error is returned.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.UpdateControlRequest` The request object containing all of the parameters for the API call. |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://learn.microsoft.com/dotnet/api/system.threading.tasks.task-1https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.DiscoveryEngine.V1Beta/latest/Google.Cloud.DiscoveryEngine.V1Beta.Control` | A Task containing the RPC response. |

**Example**

    // Create client
    ControlServiceClient controlServiceClient = await ControlServiceClient.CreateAsync();
    // Initialize request argument(s)
    UpdateControlRequest request = new UpdateControlRequest
    {
        Control = new Control(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Control response = await controlServiceClient.UpdateControlAsync(request);