# Essential Contacts v1 API - Class EssentialContactsServiceClient (2.6.0)

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

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

    public abstract class EssentialContactsServiceClient

Reference documentation and code samples for the Essential Contacts v1 API class EssentialContactsServiceClient.

EssentialContactsService client wrapper, for convenient use.

## Inheritance

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

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

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

## Namespace

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

## Assembly

Google.Cloud.EssentialContacts.V1.dll

## Remarks

Manages contacts for important Google Cloud notifications.

## Properties

### DefaultEndpoint

    public static string DefaultEndpoint { get; }

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

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

<br />

### GrpcClient

    public virtual EssentialContactsService.EssentialContactsServiceClient GrpcClient { get; }

The underlying gRPC EssentialContactsService client

| **Property Value** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.EssentialContactsServicehttps://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.EssentialContactsService.EssentialContactsServiceClient` |   |

### ServiceMetadata

    public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

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

## Methods

### ComputeContacts(ComputeContactsRequest, CallSettings)

    public virtual PagedEnumerable<ComputeContactsResponse, Contact> ComputeContacts(ComputeContactsRequest request, CallSettings callSettings = null)

Lists all contacts for the resource that are subscribed to the
specified notification categories, including contacts inherited from
any parent resources.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ComputeContactsRequest request = new ComputeContactsRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
        NotificationCategories =
        {
            NotificationCategory.Unspecified,
        },
    };
    // Make the request
    PagedEnumerable<ComputeContactsResponse, Contact> response = essentialContactsServiceClient.ComputeContacts(request);

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

### ComputeContactsAsync(ComputeContactsRequest, CallSettings)

    public virtual PagedAsyncEnumerable<ComputeContactsResponse, Contact> ComputeContactsAsync(ComputeContactsRequest request, CallSettings callSettings = null)

Lists all contacts for the resource that are subscribed to the
specified notification categories, including contacts inherited from
any parent resources.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ComputeContactsRequest request = new ComputeContactsRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
        NotificationCategories =
        {
            NotificationCategory.Unspecified,
        },
    };
    // Make the request
    PagedAsyncEnumerable<ComputeContactsResponse, Contact> response = essentialContactsServiceClient.ComputeContactsAsync(request);

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

### Create()

    public static EssentialContactsServiceClient Create()

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

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

### CreateAsync(CancellationToken)

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

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

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

### CreateContact(FolderName, Contact, CallSettings)

    public virtual Contact CreateContact(FolderName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.FolderName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    FolderName parent = FolderName.FromFolder("[FOLDER]");
    Contact contact = new Contact();
    // Make the request
    Contact response = essentialContactsServiceClient.CreateContact(parent, contact);

### CreateContact(OrganizationName, Contact, CallSettings)

    public virtual Contact CreateContact(OrganizationName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.OrganizationName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    OrganizationName parent = OrganizationName.FromOrganization("[ORGANIZATION]");
    Contact contact = new Contact();
    // Make the request
    Contact response = essentialContactsServiceClient.CreateContact(parent, contact);

### CreateContact(ProjectName, Contact, CallSettings)

    public virtual Contact CreateContact(ProjectName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.ProjectName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ProjectName parent = ProjectName.FromProject("[PROJECT]");
    Contact contact = new Contact();
    // Make the request
    Contact response = essentialContactsServiceClient.CreateContact(parent, contact);

### CreateContact(CreateContactRequest, CallSettings)

    public virtual Contact CreateContact(CreateContactRequest request, CallSettings callSettings = null)

Adds a new contact for a resource.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    CreateContactRequest request = new CreateContactRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
        Contact = new Contact(),
    };
    // Make the request
    Contact response = essentialContactsServiceClient.CreateContact(request);

### CreateContact(string, Contact, CallSettings)

    public virtual Contact CreateContact(string parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]";
    Contact contact = new Contact();
    // Make the request
    Contact response = essentialContactsServiceClient.CreateContact(parent, contact);

### CreateContactAsync(FolderName, Contact, CallSettings)

    public virtual Task<Contact> CreateContactAsync(FolderName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.FolderName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    FolderName parent = FolderName.FromFolder("[FOLDER]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(FolderName, Contact, CancellationToken)

    public virtual Task<Contact> CreateContactAsync(FolderName parent, Contact contact, CancellationToken cancellationToken)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.FolderName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    FolderName parent = FolderName.FromFolder("[FOLDER]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(OrganizationName, Contact, CallSettings)

    public virtual Task<Contact> CreateContactAsync(OrganizationName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.OrganizationName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    OrganizationName parent = OrganizationName.FromOrganization("[ORGANIZATION]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(OrganizationName, Contact, CancellationToken)

    public virtual Task<Contact> CreateContactAsync(OrganizationName parent, Contact contact, CancellationToken cancellationToken)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.OrganizationName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    OrganizationName parent = OrganizationName.FromOrganization("[ORGANIZATION]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(ProjectName, Contact, CallSettings)

    public virtual Task<Contact> CreateContactAsync(ProjectName parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.ProjectName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ProjectName parent = ProjectName.FromProject("[PROJECT]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(ProjectName, Contact, CancellationToken)

    public virtual Task<Contact> CreateContactAsync(ProjectName parent, Contact contact, CancellationToken cancellationToken)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.ResourceNames.ProjectName.html` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ProjectName parent = ProjectName.FromProject("[PROJECT]");
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(CreateContactRequest, CallSettings)

    public virtual Task<Contact> CreateContactAsync(CreateContactRequest request, CallSettings callSettings = null)

Adds a new contact for a resource.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    CreateContactRequest request = new CreateContactRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
        Contact = new Contact(),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(request);

### CreateContactAsync(CreateContactRequest, CancellationToken)

    public virtual Task<Contact> CreateContactAsync(CreateContactRequest request, CancellationToken cancellationToken)

Adds a new contact for a resource.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    CreateContactRequest request = new CreateContactRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
        Contact = new Contact(),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(request);

### CreateContactAsync(string, Contact, CallSettings)

    public virtual Task<Contact> CreateContactAsync(string parent, Contact contact, CallSettings callSettings = null)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]";
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### CreateContactAsync(string, Contact, CancellationToken)

    public virtual Task<Contact> CreateContactAsync(string parent, Contact contact, CancellationToken cancellationToken)

Adds a new contact for a resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `parent` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The resource to save this contact for. Format: organizations/{organization_id}, folders/{folder_id} or projects/{project_id} |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact to create. Must specify an email address and language tag. |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]";
    Contact contact = new Contact();
    // Make the request
    Contact response = await essentialContactsServiceClient.CreateContactAsync(parent, contact);

### DeleteContact(ContactName, CallSettings)

    public virtual void DeleteContact(ContactName name, CallSettings callSettings = null)

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    essentialContactsServiceClient.DeleteContact(name);

### DeleteContact(DeleteContactRequest, CallSettings)

    public virtual void DeleteContact(DeleteContactRequest request, CallSettings callSettings = null)

Deletes a contact.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    DeleteContactRequest request = new DeleteContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    essentialContactsServiceClient.DeleteContact(request);

### DeleteContact(string, CallSettings)

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

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    essentialContactsServiceClient.DeleteContact(name);

### DeleteContactAsync(ContactName, CallSettings)

    public virtual Task DeleteContactAsync(ContactName name, CallSettings callSettings = null)

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(name);

### DeleteContactAsync(ContactName, CancellationToken)

    public virtual Task DeleteContactAsync(ContactName name, CancellationToken cancellationToken)

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(name);

### DeleteContactAsync(DeleteContactRequest, CallSettings)

    public virtual Task DeleteContactAsync(DeleteContactRequest request, CallSettings callSettings = null)

Deletes a contact.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    DeleteContactRequest request = new DeleteContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(request);

### DeleteContactAsync(DeleteContactRequest, CancellationToken)

    public virtual Task DeleteContactAsync(DeleteContactRequest request, CancellationToken cancellationToken)

Deletes a contact.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    DeleteContactRequest request = new DeleteContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(request);

### DeleteContactAsync(string, CallSettings)

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

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(name);

### DeleteContactAsync(string, CancellationToken)

    public virtual Task DeleteContactAsync(string name, CancellationToken cancellationToken)

Deletes a contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to delete. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    await essentialContactsServiceClient.DeleteContactAsync(name);

### GetContact(ContactName, CallSettings)

    public virtual Contact GetContact(ContactName name, CallSettings callSettings = null)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    Contact response = essentialContactsServiceClient.GetContact(name);

### GetContact(GetContactRequest, CallSettings)

    public virtual Contact GetContact(GetContactRequest request, CallSettings callSettings = null)

Gets a single contact.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    GetContactRequest request = new GetContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    Contact response = essentialContactsServiceClient.GetContact(request);

### GetContact(string, CallSettings)

    public virtual Contact GetContact(string name, CallSettings callSettings = null)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    Contact response = essentialContactsServiceClient.GetContact(name);

### GetContactAsync(ContactName, CallSettings)

    public virtual Task<Contact> GetContactAsync(ContactName name, CallSettings callSettings = null)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(name);

### GetContactAsync(ContactName, CancellationToken)

    public virtual Task<Contact> GetContactAsync(ContactName name, CancellationToken cancellationToken)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.ContactName` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ContactName name = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]");
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(name);

### GetContactAsync(GetContactRequest, CallSettings)

    public virtual Task<Contact> GetContactAsync(GetContactRequest request, CallSettings callSettings = null)

Gets a single contact.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    GetContactRequest request = new GetContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(request);

### GetContactAsync(GetContactRequest, CancellationToken)

    public virtual Task<Contact> GetContactAsync(GetContactRequest request, CancellationToken cancellationToken)

Gets a single contact.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    GetContactRequest request = new GetContactRequest
    {
        ContactName = ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(request);

### GetContactAsync(string, CallSettings)

    public virtual Task<Contact> GetContactAsync(string name, CallSettings callSettings = null)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `callSettings` | `https://cloud.google.com/dotnet/docs/reference/Google.Api.Gax/latest/Google.Api.Gax.Grpc.CallSettings.html` If not null, applies overrides to this RPC call. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(name);

### GetContactAsync(string, CancellationToken)

    public virtual Task<Contact> GetContactAsync(string name, CancellationToken cancellationToken)

Gets a single contact.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `name` | `https://learn.microsoft.com/dotnet/api/system.string` Required. The name of the contact to retrieve. Format: organizations/{organization_id}/contacts/{contact_id}, folders/{folder_id}/contacts/{contact_id} or projects/{project_id}/contacts/{contact_id} |
| `cancellationToken` | `https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken` A [CancellationToken](https://learn.microsoft.com/dotnet/api/system.threading.cancellationtoken) to use for this RPC. |

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string name = "projects/[PROJECT]/contacts/[CONTACT]";
    // Make the request
    Contact response = await essentialContactsServiceClient.GetContactAsync(name);

### ListContacts(FolderName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListContactsResponse, Contact> ListContacts(FolderName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    FolderName parent = FolderName.FromFolder("[FOLDER]");
    // Make the request
    PagedEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContacts(parent);

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

### ListContacts(OrganizationName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListContactsResponse, Contact> ListContacts(OrganizationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    OrganizationName parent = OrganizationName.FromOrganization("[ORGANIZATION]");
    // Make the request
    PagedEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContacts(parent);

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

### ListContacts(ProjectName, string, int?, CallSettings)

    public virtual PagedEnumerable<ListContactsResponse, Contact> ListContacts(ProjectName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ProjectName parent = ProjectName.FromProject("[PROJECT]");
    // Make the request
    PagedEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContacts(parent);

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

### ListContacts(ListContactsRequest, CallSettings)

    public virtual PagedEnumerable<ListContactsResponse, Contact> ListContacts(ListContactsRequest request, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    ListContactsRequest request = new ListContactsRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
    };
    // Make the request
    PagedEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContacts(request);

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

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

    public virtual PagedEnumerable<ListContactsResponse, Contact> ListContacts(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]";
    // Make the request
    PagedEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContacts(parent);

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

### ListContactsAsync(FolderName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListContactsResponse, Contact> ListContactsAsync(FolderName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    FolderName parent = FolderName.FromFolder("[FOLDER]");
    // Make the request
    PagedAsyncEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContactsAsync(parent);

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

### ListContactsAsync(OrganizationName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListContactsResponse, Contact> ListContactsAsync(OrganizationName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    OrganizationName parent = OrganizationName.FromOrganization("[ORGANIZATION]");
    // Make the request
    PagedAsyncEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContactsAsync(parent);

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

### ListContactsAsync(ProjectName, string, int?, CallSettings)

    public virtual PagedAsyncEnumerable<ListContactsResponse, Contact> ListContactsAsync(ProjectName parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ProjectName parent = ProjectName.FromProject("[PROJECT]");
    // Make the request
    PagedAsyncEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContactsAsync(parent);

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

### ListContactsAsync(ListContactsRequest, CallSettings)

    public virtual PagedAsyncEnumerable<ListContactsResponse, Contact> ListContactsAsync(ListContactsRequest request, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    ListContactsRequest request = new ListContactsRequest
    {
        ParentAsProjectName = ProjectName.FromProject("[PROJECT]"),
    };
    // Make the request
    PagedAsyncEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContactsAsync(request);

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

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

    public virtual PagedAsyncEnumerable<ListContactsResponse, Contact> ListContactsAsync(string parent, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Lists the contacts that have been set on a resource.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    string parent = "projects/[PROJECT]";
    // Make the request
    PagedAsyncEnumerable<ListContactsResponse, Contact> response = essentialContactsServiceClient.ListContactsAsync(parent);

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

### SendTestMessage(SendTestMessageRequest, CallSettings)

    public virtual void SendTestMessage(SendTestMessageRequest request, CallSettings callSettings = null)

Allows a contact admin to send a test message to contact to verify that it
has been configured correctly.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    SendTestMessageRequest request = new SendTestMessageRequest
    {
        ContactsAsContactNames =
        {
            ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
        },
        ResourceAsProjectName = ProjectName.FromProject("[PROJECT]"),
        NotificationCategory = NotificationCategory.Unspecified,
    };
    // Make the request
    essentialContactsServiceClient.SendTestMessage(request);

### SendTestMessageAsync(SendTestMessageRequest, CallSettings)

    public virtual Task SendTestMessageAsync(SendTestMessageRequest request, CallSettings callSettings = null)

Allows a contact admin to send a test message to contact to verify that it
has been configured correctly.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    SendTestMessageRequest request = new SendTestMessageRequest
    {
        ContactsAsContactNames =
        {
            ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
        },
        ResourceAsProjectName = ProjectName.FromProject("[PROJECT]"),
        NotificationCategory = NotificationCategory.Unspecified,
    };
    // Make the request
    await essentialContactsServiceClient.SendTestMessageAsync(request);

### SendTestMessageAsync(SendTestMessageRequest, CancellationToken)

    public virtual Task SendTestMessageAsync(SendTestMessageRequest request, CancellationToken cancellationToken)

Allows a contact admin to send a test message to contact to verify that it
has been configured correctly.

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

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    SendTestMessageRequest request = new SendTestMessageRequest
    {
        ContactsAsContactNames =
        {
            ContactName.FromProjectContact("[PROJECT]", "[CONTACT]"),
        },
        ResourceAsProjectName = ProjectName.FromProject("[PROJECT]"),
        NotificationCategory = NotificationCategory.Unspecified,
    };
    // Make the request
    await essentialContactsServiceClient.SendTestMessageAsync(request);

### ShutdownDefaultChannelsAsync()

    public static Task ShutdownDefaultChannelsAsync()

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

### UpdateContact(Contact, FieldMask, CallSettings)

    public virtual Contact UpdateContact(Contact contact, FieldMask updateMask, CallSettings callSettings = null)

Updates a contact.
Note: A contact's email address cannot be changed.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact resource to replace the existing saved contact. Note: the email address of the contact cannot be modified. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. The update mask applied to the resource. For the `FieldMask` definition, see <https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask> |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | The RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    Contact contact = new Contact();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Contact response = essentialContactsServiceClient.UpdateContact(contact, updateMask);

### UpdateContact(UpdateContactRequest, CallSettings)

    public virtual Contact UpdateContact(UpdateContactRequest request, CallSettings callSettings = null)

Updates a contact.
Note: A contact's email address cannot be changed.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = EssentialContactsServiceClient.Create();
    // Initialize request argument(s)
    UpdateContactRequest request = new UpdateContactRequest
    {
        Contact = new Contact(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Contact response = essentialContactsServiceClient.UpdateContact(request);

### UpdateContactAsync(Contact, FieldMask, CallSettings)

    public virtual Task<Contact> UpdateContactAsync(Contact contact, FieldMask updateMask, CallSettings callSettings = null)

Updates a contact.
Note: A contact's email address cannot be changed.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact resource to replace the existing saved contact. Note: the email address of the contact cannot be modified. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. The update mask applied to the resource. For the `FieldMask` definition, see <https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask> |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    Contact contact = new Contact();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Contact response = await essentialContactsServiceClient.UpdateContactAsync(contact, updateMask);

### UpdateContactAsync(Contact, FieldMask, CancellationToken)

    public virtual Task<Contact> UpdateContactAsync(Contact contact, FieldMask updateMask, CancellationToken cancellationToken)

Updates a contact.
Note: A contact's email address cannot be changed.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `contact` | `https://docs.cloud.google.com/dotnet/docs/reference/Google.Cloud.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` Required. The contact resource to replace the existing saved contact. Note: the email address of the contact cannot be modified. |
| `updateMask` | `https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.WellKnownTypes.FieldMask.html` Optional. The update mask applied to the resource. For the `FieldMask` definition, see <https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask> |
| `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.EssentialContacts.V1/latest/Google.Cloud.EssentialContacts.V1.Contact` | A Task containing the RPC response. |

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    Contact contact = new Contact();
    FieldMask updateMask = new FieldMask();
    // Make the request
    Contact response = await essentialContactsServiceClient.UpdateContactAsync(contact, updateMask);

### UpdateContactAsync(UpdateContactRequest, CallSettings)

    public virtual Task<Contact> UpdateContactAsync(UpdateContactRequest request, CallSettings callSettings = null)

Updates a contact.
Note: A contact's email address cannot be changed.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    UpdateContactRequest request = new UpdateContactRequest
    {
        Contact = new Contact(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.UpdateContactAsync(request);

### UpdateContactAsync(UpdateContactRequest, CancellationToken)

    public virtual Task<Contact> UpdateContactAsync(UpdateContactRequest request, CancellationToken cancellationToken)

Updates a contact.
Note: A contact's email address cannot be changed.

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

**Example**

    // Create client
    EssentialContactsServiceClient essentialContactsServiceClient = await EssentialContactsServiceClient.CreateAsync();
    // Initialize request argument(s)
    UpdateContactRequest request = new UpdateContactRequest
    {
        Contact = new Contact(),
        UpdateMask = new FieldMask(),
    };
    // Make the request
    Contact response = await essentialContactsServiceClient.UpdateContactAsync(request);