# Workflows v1 API - Class WorkflowsClient (2.7.0)

<button class="button button-with-icon cloud-select-dropdown__button " aria-haspopup="true">Version latest</button>

- [2.7.0 (latest)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.6.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.6.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.5.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.5.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.4.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.4.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.3.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.3.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.2.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.2.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.1.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [2.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/2.0.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [1.2.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/1.2.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [1.1.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/1.1.0/Google.Cloud.Workflows.V1.WorkflowsClient)
- [1.0.0](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/1.0.0/Google.Cloud.Workflows.V1.WorkflowsClient)

    public abstract class WorkflowsClient

Reference documentation and code samples for the Workflows v1 API class WorkflowsClient.

Workflows client wrapper, for convenient use.

## Inheritance

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

## 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

[WorkflowsClientImpl](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClientImpl)

## Namespace

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

## Assembly

Google.Cloud.Workflows.V1.dll

## Remarks

Workflows is used to deploy and execute workflow programs.
Workflows makes sure the program executes reliably, despite hardware and
networking interruptions.

## Properties

### CreateWorkflowOperationsClient

    public virtual OperationsClient CreateWorkflowOperationsClient { get; }

The long-running operations client for `CreateWorkflow`.

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

### DefaultEndpoint

    public static string DefaultEndpoint { get; }

The default endpoint for the Workflows service, which is a host of "workflows.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 Workflows 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 Workflows scopes are:

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

<br />

### DeleteWorkflowOperationsClient

    public virtual OperationsClient DeleteWorkflowOperationsClient { get; }

The long-running operations client for `DeleteWorkflow`.

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

### GrpcClient

    public virtual Workflows.WorkflowsClient GrpcClient { get; }

The underlying gRPC Workflows client

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowshttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflows.WorkflowsClient` |   |

### 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` |   |

### UpdateWorkflowOperationsClient

    public virtual OperationsClient UpdateWorkflowOperationsClient { get; }

The long-running operations client for `UpdateWorkflow`.

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

## Methods

### Create()

    public static WorkflowsClient Create()

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

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

### CreateAsync(CancellationToken)

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

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

| **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.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient` | The task representing the created [WorkflowsClient](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient). |

### CreateWorkflow(LocationName, Workflow, string, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> CreateWorkflow(LocationName parent, Workflow workflow, string workflowId, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.LocationName.html` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = workflowsClient.CreateWorkflow(parent, workflow, workflowId);

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

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

### CreateWorkflow(CreateWorkflowRequest, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> CreateWorkflow(CreateWorkflowRequest request, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.CreateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    CreateWorkflowRequest request = new CreateWorkflowRequest
    {
        ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
        Workflow = new Workflow(),
        WorkflowId = "",
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = workflowsClient.CreateWorkflow(request);

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

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

### CreateWorkflow(string, Workflow, string, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> CreateWorkflow(string parent, Workflow workflow, string workflowId, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]";
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = workflowsClient.CreateWorkflow(parent, workflow, workflowId);

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

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

### CreateWorkflowAsync(LocationName, Workflow, string, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(LocationName parent, Workflow workflow, string workflowId, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.LocationName.html` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(parent, workflow, workflowId);

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

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

### CreateWorkflowAsync(LocationName, Workflow, string, CancellationToken)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(LocationName parent, Workflow workflow, string workflowId, CancellationToken cancellationToken)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.LocationName.html` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(parent, workflow, workflowId);

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

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

### CreateWorkflowAsync(CreateWorkflowRequest, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(CreateWorkflowRequest request, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.CreateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    CreateWorkflowRequest request = new CreateWorkflowRequest
    {
        ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
        Workflow = new Workflow(),
        WorkflowId = "",
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(request);

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

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

### CreateWorkflowAsync(CreateWorkflowRequest, CancellationToken)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(CreateWorkflowRequest request, CancellationToken cancellationToken)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.CreateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    CreateWorkflowRequest request = new CreateWorkflowRequest
    {
        ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
        Workflow = new Workflow(),
        WorkflowId = "",
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(request);

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

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

### CreateWorkflowAsync(string, Workflow, string, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(string parent, Workflow workflow, string workflowId, CallSettings callSettings = null)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]";
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(parent, workflow, workflowId);

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

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

### CreateWorkflowAsync(string, Workflow, string, CancellationToken)

    public virtual Task<Operation<Workflow, OperationMetadata>> CreateWorkflowAsync(string parent, Workflow workflow, string workflowId, CancellationToken cancellationToken)

Creates a new workflow. If a workflow with the specified name already
exists in the specified project and location, the long running operation
returns a \[ALREADY_EXISTS\]\[google.rpc.Code.ALREADY_EXISTS\] error.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Project and location in which the workflow should be created. Format: projects/{project}/locations/{location} |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be created. |
| `workflowId` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The ID of the workflow to be created. It has to fulfill the following requirements: - Must contain only letters, numbers, underscores and hyphens. - Must start with a letter. - Must be between 1-64 characters. - Must end with a number or a letter. - Must be unique within the customer project and location. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]";
    Workflow workflow = new Workflow();
    string workflowId = "";
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.CreateWorkflowAsync(parent, workflow, workflowId);

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

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

### DeleteWorkflow(WorkflowName, CallSettings)

    public virtual Operation<Empty, OperationMetadata> DeleteWorkflow(WorkflowName name, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Operation<Empty, OperationMetadata> response = workflowsClient.DeleteWorkflow(name);

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

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

### DeleteWorkflow(DeleteWorkflowRequest, CallSettings)

    public virtual Operation<Empty, OperationMetadata> DeleteWorkflow(DeleteWorkflowRequest request, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.DeleteWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    DeleteWorkflowRequest request = new DeleteWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
    };
    // Make the request
    Operation<Empty, OperationMetadata> response = workflowsClient.DeleteWorkflow(request);

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

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

### DeleteWorkflow(string, CallSettings)

    public virtual Operation<Empty, OperationMetadata> DeleteWorkflow(string name, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Operation<Empty, OperationMetadata> response = workflowsClient.DeleteWorkflow(name);

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

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

### DeleteWorkflowAsync(WorkflowName, CallSettings)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(WorkflowName name, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(name);

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

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

### DeleteWorkflowAsync(WorkflowName, CancellationToken)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(WorkflowName name, CancellationToken cancellationToken)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(name);

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

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

### DeleteWorkflowAsync(DeleteWorkflowRequest, CallSettings)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(DeleteWorkflowRequest request, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.DeleteWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    DeleteWorkflowRequest request = new DeleteWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
    };
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(request);

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

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

### DeleteWorkflowAsync(DeleteWorkflowRequest, CancellationToken)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(DeleteWorkflowRequest request, CancellationToken cancellationToken)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.DeleteWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    DeleteWorkflowRequest request = new DeleteWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
    };
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(request);

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

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

### DeleteWorkflowAsync(string, CallSettings)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(string name, CallSettings callSettings = null)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(name);

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

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

### DeleteWorkflowAsync(string, CancellationToken)

    public virtual Task<Operation<Empty, OperationMetadata>> DeleteWorkflowAsync(string name, CancellationToken cancellationToken)

Deletes a workflow with the specified name.
This method also cancels and deletes all running executions of the
workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow to be deleted. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Operation<Empty, OperationMetadata> response = await workflowsClient.DeleteWorkflowAsync(name);

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

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

### GetWorkflow(WorkflowName, CallSettings)

    public virtual Workflow GetWorkflow(WorkflowName name, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Workflow response = workflowsClient.GetWorkflow(name);

### GetWorkflow(GetWorkflowRequest, CallSettings)

    public virtual Workflow GetWorkflow(GetWorkflowRequest request, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.GetWorkflowRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    GetWorkflowRequest request = new GetWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
        RevisionId = "",
    };
    // Make the request
    Workflow response = workflowsClient.GetWorkflow(request);

### GetWorkflow(string, CallSettings)

    public virtual Workflow GetWorkflow(string name, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Workflow response = workflowsClient.GetWorkflow(name);

### GetWorkflowAsync(WorkflowName, CallSettings)

    public virtual Task<Workflow> GetWorkflowAsync(WorkflowName name, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(name);

### GetWorkflowAsync(WorkflowName, CancellationToken)

    public virtual Task<Workflow> GetWorkflowAsync(WorkflowName name, CancellationToken cancellationToken)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.Common.V1/latest/Google.Cloud.Workflows.Common.V1.WorkflowName.html` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    WorkflowName name = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]");
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(name);

### GetWorkflowAsync(GetWorkflowRequest, CallSettings)

    public virtual Task<Workflow> GetWorkflowAsync(GetWorkflowRequest request, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.GetWorkflowRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    GetWorkflowRequest request = new GetWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
        RevisionId = "",
    };
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(request);

### GetWorkflowAsync(GetWorkflowRequest, CancellationToken)

    public virtual Task<Workflow> GetWorkflowAsync(GetWorkflowRequest request, CancellationToken cancellationToken)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.GetWorkflowRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    GetWorkflowRequest request = new GetWorkflowRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
        RevisionId = "",
    };
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(request);

### GetWorkflowAsync(string, CallSettings)

    public virtual Task<Workflow> GetWorkflowAsync(string name, CallSettings callSettings = null)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(name);

### GetWorkflowAsync(string, CancellationToken)

    public virtual Task<Workflow> GetWorkflowAsync(string name, CancellationToken cancellationToken)

Gets details of a single workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Name of the workflow for which information should be retrieved. Format: projects/{project}/locations/{location}/workflows/{workflow} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/locations/[LOCATION]/workflows/[WORKFLOW]";
    // Make the request
    Workflow response = await workflowsClient.GetWorkflowAsync(name);

### ListWorkflowRevisions(ListWorkflowRevisionsRequest, CallSettings)

    public virtual PagedEnumerable<ListWorkflowRevisionsResponse, Workflow> ListWorkflowRevisions(ListWorkflowRevisionsRequest request, CallSettings callSettings = null)

Lists revisions for a given workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowRevisionsRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowRevisionsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    ListWorkflowRevisionsRequest request = new ListWorkflowRevisionsRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
    };
    // Make the request
    PagedEnumerable<ListWorkflowRevisionsResponse, Workflow> response = workflowsClient.ListWorkflowRevisions(request);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Workflow 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 (ListWorkflowRevisionsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### ListWorkflowRevisionsAsync(ListWorkflowRevisionsRequest, CallSettings)

    public virtual PagedAsyncEnumerable<ListWorkflowRevisionsResponse, Workflow> ListWorkflowRevisionsAsync(ListWorkflowRevisionsRequest request, CallSettings callSettings = null)

Lists revisions for a given workflow.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowRevisionsRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowRevisionsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable asynchronous sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    ListWorkflowRevisionsRequest request = new ListWorkflowRevisionsRequest
    {
        WorkflowName = WorkflowName.FromProjectLocationWorkflow("[PROJECT]", "[LOCATION]", "[WORKFLOW]"),
    };
    // Make the request
    PagedAsyncEnumerable<ListWorkflowRevisionsResponse, Workflow> response = workflowsClient.ListWorkflowRevisionsAsync(request);

    // Iterate over all response items, lazily performing RPCs as required
    await response.ForEachAsync((Workflow item) =>
    {
        // Do something with each item
        Console.WriteLine(item);
    });

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await response.AsRawResponses().ForEachAsync((ListWorkflowRevisionsResponse page) =>
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### ListWorkflows(LocationName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListWorkflowsResponse, Workflow> ListWorkflows(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.LocationName.html` Required. Project and location from which the workflows should be listed. Format: projects/{project}/locations/{location} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
    // Make the request
    PagedEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflows(parent);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Workflow 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 (ListWorkflowsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### ListWorkflows(ListWorkflowsRequest, CallSettings)

    public virtual PagedEnumerable<ListWorkflowsResponse, Workflow> ListWorkflows(ListWorkflowsRequest request, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    ListWorkflowsRequest request = new ListWorkflowsRequest
    {
        ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
        Filter = "",
        OrderBy = "",
    };
    // Make the request
    PagedEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflows(request);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Workflow 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 (ListWorkflowsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

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

    public virtual PagedEnumerable<ListWorkflowsResponse, Workflow> ListWorkflows(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Project and location from which the workflows should be listed. Format: projects/{project}/locations/{location} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]";
    // Make the request
    PagedEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflows(parent);

    // Iterate over all response items, lazily performing RPCs as required
    foreach (Workflow 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 (ListWorkflowsResponse page in response.AsRawResponses())
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### ListWorkflowsAsync(LocationName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> ListWorkflowsAsync(LocationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.LocationName.html` Required. Project and location from which the workflows should be listed. Format: projects/{project}/locations/{location} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable asynchronous sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    LocationName parent = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]");
    // Make the request
    PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflowsAsync(parent);

    // Iterate over all response items, lazily performing RPCs as required
    await response.ForEachAsync((Workflow item) =>
    {
        // Do something with each item
        Console.WriteLine(item);
    });

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await response.AsRawResponses().ForEachAsync((ListWorkflowsResponse page) =>
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### ListWorkflowsAsync(ListWorkflowsRequest, CallSettings)

    public virtual PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> ListWorkflowsAsync(ListWorkflowsRequest request, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsRequest` 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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable asynchronous sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    ListWorkflowsRequest request = new ListWorkflowsRequest
    {
        ParentAsLocationName = LocationName.FromProjectLocation("[PROJECT]", "[LOCATION]"),
        Filter = "",
        OrderBy = "",
    };
    // Make the request
    PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflowsAsync(request);

    // Iterate over all response items, lazily performing RPCs as required
    await response.ForEachAsync((Workflow item) =>
    {
        // Do something with each item
        Console.WriteLine(item);
    });

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await response.AsRawResponses().ForEachAsync((ListWorkflowsResponse page) =>
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

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

    public virtual PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> ListWorkflowsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists workflows in a given project and location.
The default order is not specified.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. Project and location from which the workflows should be listed. Format: projects/{project}/locations/{location} |
| `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.Workflows.V1/latest/Google.Cloud.Workflows.V1.ListWorkflowsResponsehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` | A pageable asynchronous sequence of [Workflow](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow) resources. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]/locations/[LOCATION]";
    // Make the request
    PagedAsyncEnumerable<ListWorkflowsResponse, Workflow> response = workflowsClient.ListWorkflowsAsync(parent);

    // Iterate over all response items, lazily performing RPCs as required
    await response.ForEachAsync((Workflow item) =>
    {
        // Do something with each item
        Console.WriteLine(item);
    });

    // Or iterate over pages (of server-defined size), performing one RPC per page
    await response.AsRawResponses().ForEachAsync((ListWorkflowsResponse page) =>
    {
        // Do something with each page of items
        Console.WriteLine("A page of results:");
        foreach (Workflow 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<Workflow> 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 (Workflow 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;

### PollOnceCreateWorkflow(string, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> PollOnceCreateWorkflow(string operationName, CallSettings callSettings = null)

Poll an operation once, using an `operationName` from a previous invocation of `CreateWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The result of polling the operation. |

### PollOnceCreateWorkflowAsync(string, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> PollOnceCreateWorkflowAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an `operationName` from a previous invocation of
`CreateWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A task representing the result of polling the operation. |

### PollOnceDeleteWorkflow(string, CallSettings)

    public virtual Operation<Empty, OperationMetadata> PollOnceDeleteWorkflow(string operationName, CallSettings callSettings = null)

Poll an operation once, using an `operationName` from a previous invocation of `DeleteWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The result of polling the operation. |

### PollOnceDeleteWorkflowAsync(string, CallSettings)

    public virtual Task<Operation<Empty, OperationMetadata>> PollOnceDeleteWorkflowAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an `operationName` from a previous invocation of
`DeleteWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.Empty.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A task representing the result of polling the operation. |

### PollOnceUpdateWorkflow(string, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> PollOnceUpdateWorkflow(string operationName, CallSettings callSettings = null)

Poll an operation once, using an `operationName` from a previous invocation of `UpdateWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The result of polling the operation. |

### PollOnceUpdateWorkflowAsync(string, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> PollOnceUpdateWorkflowAsync(string operationName, CallSettings callSettings = null)

Asynchronously poll an operation once, using an `operationName` from a previous invocation of
`UpdateWorkflow`.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `https://learn.microsoft.com/dotnet/api/system.string` The name of a previously invoked operation. Must not be `null` or empty. |
| `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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A task representing the result of polling the operation. |

### ShutdownDefaultChannelsAsync()

    public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by [Create()](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient#Google_Cloud_Workflows_V1_WorkflowsClient_Create) and
[CreateAsync(CancellationToken)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient#Google_Cloud_Workflows_V1_WorkflowsClient_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.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient#Google_Cloud_Workflows_V1_WorkflowsClient_Create) and
[CreateAsync(CancellationToken)](https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.WorkflowsClient#Google_Cloud_Workflows_V1_WorkflowsClient_CreateAsync_System_Threading_CancellationToken_) will create new channels, which could in turn be shut down
by another call to this method.

### UpdateWorkflow(UpdateWorkflowRequest, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> UpdateWorkflow(UpdateWorkflowRequest request, CallSettings callSettings = null)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.UpdateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    UpdateWorkflowRequest request = new UpdateWorkflowRequest
    {
        Workflow = new Workflow(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = workflowsClient.UpdateWorkflow(request);

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

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

### UpdateWorkflow(Workflow, FieldMask, CallSettings)

    public virtual Operation<Workflow, OperationMetadata> UpdateWorkflow(Workflow workflow, FieldMask updateMask, CallSettings callSettings = null)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be updated. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` List of fields to be updated. If not present, the entire workflow will be 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | The RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = WorkflowsClient.Create();
    // Initialize request argument(s)
    Workflow workflow = new Workflow();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Operation<Workflow, OperationMetadata> response = workflowsClient.UpdateWorkflow(workflow, updateMask);

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

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

### UpdateWorkflowAsync(UpdateWorkflowRequest, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> UpdateWorkflowAsync(UpdateWorkflowRequest request, CallSettings callSettings = null)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.UpdateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    UpdateWorkflowRequest request = new UpdateWorkflowRequest
    {
        Workflow = new Workflow(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.UpdateWorkflowAsync(request);

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

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

### UpdateWorkflowAsync(UpdateWorkflowRequest, CancellationToken)

    public virtual Task<Operation<Workflow, OperationMetadata>> UpdateWorkflowAsync(UpdateWorkflowRequest request, CancellationToken cancellationToken)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.UpdateWorkflowRequest` 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    UpdateWorkflowRequest request = new UpdateWorkflowRequest
    {
        Workflow = new Workflow(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.UpdateWorkflowAsync(request);

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

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

### UpdateWorkflowAsync(Workflow, FieldMask, CallSettings)

    public virtual Task<Operation<Workflow, OperationMetadata>> UpdateWorkflowAsync(Workflow workflow, FieldMask updateMask, CallSettings callSettings = null)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be updated. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` List of fields to be updated. If not present, the entire workflow will be 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    Workflow workflow = new Workflow();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.UpdateWorkflowAsync(workflow, updateMask);

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

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

### UpdateWorkflowAsync(Workflow, FieldMask, CancellationToken)

    public virtual Task<Operation<Workflow, OperationMetadata>> UpdateWorkflowAsync(Workflow workflow, FieldMask updateMask, CancellationToken cancellationToken)

Updates an existing workflow.
Running this method has no impact on already running executions of the
workflow. A new revision of the workflow might be created as a result of a
successful update operation. In that case, the new revision is used
in new workflow executions.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `workflow` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflow` Required. Workflow to be updated. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` List of fields to be updated. If not present, the entire workflow will be 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.LongRunning/latest/Google.LongRunning.Operation-2.htmlhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.Workflowhttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.Workflows.V1/latest/Google.Cloud.Workflows.V1.OperationMetadata` | A Task containing the RPC response. |

**Example**

    // Create client
    WorkflowsClient workflowsClient = await WorkflowsClient.CreateAsync();
    // Initialize request argument(s)
    Workflow workflow = new Workflow();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Operation<Workflow, OperationMetadata> response = await workflowsClient.UpdateWorkflowAsync(workflow, updateMask);

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

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