Recommendations AI v1beta1 API - Class CatalogServiceClient (2.0.0-beta06)

public abstract class CatalogServiceClient

Reference documentation and code samples for the Recommendations AI v1beta1 API class CatalogServiceClient.

CatalogService client wrapper, for convenient use.

Inheritance

object > CatalogServiceClient

Derived Types

Namespace

Google.Cloud.RecommendationEngine.V1Beta1

Assembly

Google.Cloud.RecommendationEngine.V1Beta1.dll

Remarks

Service for ingesting catalog information of the customer's website.

Properties

DefaultEndpoint

public static string DefaultEndpoint { get; }

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

Property Value
Type Description
string

DefaultScopes

public static IReadOnlyList<string> DefaultScopes { get; }

The default CatalogService scopes.

Property Value
Type Description
IReadOnlyListstring
Remarks

The default CatalogService scopes are:

GrpcClient

public virtual CatalogService.CatalogServiceClient GrpcClient { get; }

The underlying gRPC CatalogService client

Property Value
Type Description
CatalogServiceCatalogServiceClient

ImportCatalogItemsOperationsClient

public virtual OperationsClient ImportCatalogItemsOperationsClient { get; }

The long-running operations client for ImportCatalogItems.

Property Value
Type Description
OperationsClient

ServiceMetadata

public static ServiceMetadata ServiceMetadata { get; }

The service metadata associated with this client type.

Property Value
Type Description
ServiceMetadata

Methods

Create()

public static CatalogServiceClient Create()

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

Returns
Type Description
CatalogServiceClient

The created CatalogServiceClient.

CreateAsync(CancellationToken)

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

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

Parameter
Name Description
cancellationToken CancellationToken

The CancellationToken to use while creating the client.

Returns
Type Description
TaskCatalogServiceClient

The task representing the created CatalogServiceClient.

CreateCatalogItem(CatalogName, CatalogItem, CallSettings)

public virtual CatalogItem CreateCatalogItem(CatalogName parent, CatalogItem catalogItem, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
parent CatalogName

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = catalogServiceClient.CreateCatalogItem(parent, catalogItem);

CreateCatalogItem(CreateCatalogItemRequest, CallSettings)

public virtual CatalogItem CreateCatalogItem(CreateCatalogItemRequest request, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
request CreateCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CreateCatalogItemRequest request = new CreateCatalogItemRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    CatalogItem = new CatalogItem(),
};
// Make the request
CatalogItem response = catalogServiceClient.CreateCatalogItem(request);

CreateCatalogItem(string, CatalogItem, CallSettings)

public virtual CatalogItem CreateCatalogItem(string parent, CatalogItem catalogItem, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
parent string

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = catalogServiceClient.CreateCatalogItem(parent, catalogItem);

CreateCatalogItemAsync(CatalogName, CatalogItem, CallSettings)

public virtual Task<CatalogItem> CreateCatalogItemAsync(CatalogName parent, CatalogItem catalogItem, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
parent CatalogName

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(parent, catalogItem);

CreateCatalogItemAsync(CatalogName, CatalogItem, CancellationToken)

public virtual Task<CatalogItem> CreateCatalogItemAsync(CatalogName parent, CatalogItem catalogItem, CancellationToken cancellationToken)

Creates a catalog item.

Parameters
Name Description
parent CatalogName

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(parent, catalogItem);

CreateCatalogItemAsync(CreateCatalogItemRequest, CallSettings)

public virtual Task<CatalogItem> CreateCatalogItemAsync(CreateCatalogItemRequest request, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
request CreateCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCatalogItemRequest request = new CreateCatalogItemRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    CatalogItem = new CatalogItem(),
};
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(request);

CreateCatalogItemAsync(CreateCatalogItemRequest, CancellationToken)

public virtual Task<CatalogItem> CreateCatalogItemAsync(CreateCatalogItemRequest request, CancellationToken cancellationToken)

Creates a catalog item.

Parameters
Name Description
request CreateCatalogItemRequest

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

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CreateCatalogItemRequest request = new CreateCatalogItemRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    CatalogItem = new CatalogItem(),
};
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(request);

CreateCatalogItemAsync(string, CatalogItem, CallSettings)

public virtual Task<CatalogItem> CreateCatalogItemAsync(string parent, CatalogItem catalogItem, CallSettings callSettings = null)

Creates a catalog item.

Parameters
Name Description
parent string

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(parent, catalogItem);

CreateCatalogItemAsync(string, CatalogItem, CancellationToken)

public virtual Task<CatalogItem> CreateCatalogItemAsync(string parent, CatalogItem catalogItem, CancellationToken cancellationToken)

Creates a catalog item.

Parameters
Name Description
parent string

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

catalogItem CatalogItem

Required. The catalog item to create.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
CatalogItem catalogItem = new CatalogItem();
// Make the request
CatalogItem response = await catalogServiceClient.CreateCatalogItemAsync(parent, catalogItem);

DeleteCatalogItem(CatalogItemPathName, CallSettings)

public virtual void DeleteCatalogItem(CatalogItemPathName name, CallSettings callSettings = null)

Deletes a catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
catalogServiceClient.DeleteCatalogItem(name);

DeleteCatalogItem(DeleteCatalogItemRequest, CallSettings)

public virtual void DeleteCatalogItem(DeleteCatalogItemRequest request, CallSettings callSettings = null)

Deletes a catalog item.

Parameters
Name Description
request DeleteCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
DeleteCatalogItemRequest request = new DeleteCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
catalogServiceClient.DeleteCatalogItem(request);

DeleteCatalogItem(string, CallSettings)

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

Deletes a catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
catalogServiceClient.DeleteCatalogItem(name);

DeleteCatalogItemAsync(CatalogItemPathName, CallSettings)

public virtual Task DeleteCatalogItemAsync(CatalogItemPathName name, CallSettings callSettings = null)

Deletes a catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(name);

DeleteCatalogItemAsync(CatalogItemPathName, CancellationToken)

public virtual Task DeleteCatalogItemAsync(CatalogItemPathName name, CancellationToken cancellationToken)

Deletes a catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(name);

DeleteCatalogItemAsync(DeleteCatalogItemRequest, CallSettings)

public virtual Task DeleteCatalogItemAsync(DeleteCatalogItemRequest request, CallSettings callSettings = null)

Deletes a catalog item.

Parameters
Name Description
request DeleteCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteCatalogItemRequest request = new DeleteCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(request);

DeleteCatalogItemAsync(DeleteCatalogItemRequest, CancellationToken)

public virtual Task DeleteCatalogItemAsync(DeleteCatalogItemRequest request, CancellationToken cancellationToken)

Deletes a catalog item.

Parameters
Name Description
request DeleteCatalogItemRequest

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

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteCatalogItemRequest request = new DeleteCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(request);

DeleteCatalogItemAsync(string, CallSettings)

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

Deletes a catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(name);

DeleteCatalogItemAsync(string, CancellationToken)

public virtual Task DeleteCatalogItemAsync(string name, CancellationToken cancellationToken)

Deletes a catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
Task

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
await catalogServiceClient.DeleteCatalogItemAsync(name);

GetCatalogItem(CatalogItemPathName, CallSettings)

public virtual CatalogItem GetCatalogItem(CatalogItemPathName name, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
CatalogItem response = catalogServiceClient.GetCatalogItem(name);

GetCatalogItem(GetCatalogItemRequest, CallSettings)

public virtual CatalogItem GetCatalogItem(GetCatalogItemRequest request, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
request GetCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
GetCatalogItemRequest request = new GetCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
CatalogItem response = catalogServiceClient.GetCatalogItem(request);

GetCatalogItem(string, CallSettings)

public virtual CatalogItem GetCatalogItem(string name, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
CatalogItem response = catalogServiceClient.GetCatalogItem(name);

GetCatalogItemAsync(CatalogItemPathName, CallSettings)

public virtual Task<CatalogItem> GetCatalogItemAsync(CatalogItemPathName name, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(name);

GetCatalogItemAsync(CatalogItemPathName, CancellationToken)

public virtual Task<CatalogItem> GetCatalogItemAsync(CatalogItemPathName name, CancellationToken cancellationToken)

Gets a specific catalog item.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(name);

GetCatalogItemAsync(GetCatalogItemRequest, CallSettings)

public virtual Task<CatalogItem> GetCatalogItemAsync(GetCatalogItemRequest request, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
request GetCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
GetCatalogItemRequest request = new GetCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(request);

GetCatalogItemAsync(GetCatalogItemRequest, CancellationToken)

public virtual Task<CatalogItem> GetCatalogItemAsync(GetCatalogItemRequest request, CancellationToken cancellationToken)

Gets a specific catalog item.

Parameters
Name Description
request GetCatalogItemRequest

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

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
GetCatalogItemRequest request = new GetCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
};
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(request);

GetCatalogItemAsync(string, CallSettings)

public virtual Task<CatalogItem> GetCatalogItemAsync(string name, CallSettings callSettings = null)

Gets a specific catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(name);

GetCatalogItemAsync(string, CancellationToken)

public virtual Task<CatalogItem> GetCatalogItemAsync(string name, CancellationToken cancellationToken)

Gets a specific catalog item.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogitems/some_catalog_item_id.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
// Make the request
CatalogItem response = await catalogServiceClient.GetCatalogItemAsync(name);

ImportCatalogItems(CatalogName, string, InputConfig, ImportErrorsConfig, CallSettings)

public virtual Operation<ImportCatalogItemsResponse, ImportMetadata> ImportCatalogItems(CatalogName parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent CatalogName

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationImportCatalogItemsResponseImportMetadata

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = catalogServiceClient.ImportCatalogItems(parent, requestId, inputConfig, errorsConfig);

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

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

ImportCatalogItems(ImportCatalogItemsRequest, CallSettings)

public virtual Operation<ImportCatalogItemsResponse, ImportMetadata> ImportCatalogItems(ImportCatalogItemsRequest request, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
request ImportCatalogItemsRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationImportCatalogItemsResponseImportMetadata

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
ImportCatalogItemsRequest request = new ImportCatalogItemsRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    RequestId = "",
    InputConfig = new InputConfig(),
    ErrorsConfig = new ImportErrorsConfig(),
};
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = catalogServiceClient.ImportCatalogItems(request);

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

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

ImportCatalogItems(string, string, InputConfig, ImportErrorsConfig, CallSettings)

public virtual Operation<ImportCatalogItemsResponse, ImportMetadata> ImportCatalogItems(string parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent string

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationImportCatalogItemsResponseImportMetadata

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = catalogServiceClient.ImportCatalogItems(parent, requestId, inputConfig, errorsConfig);

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

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

ImportCatalogItemsAsync(CatalogName, string, InputConfig, ImportErrorsConfig, CallSettings)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(CatalogName parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent CatalogName

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(parent, requestId, inputConfig, errorsConfig);

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

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

ImportCatalogItemsAsync(CatalogName, string, InputConfig, ImportErrorsConfig, CancellationToken)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(CatalogName parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CancellationToken cancellationToken)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent CatalogName

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(parent, requestId, inputConfig, errorsConfig);

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

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

ImportCatalogItemsAsync(ImportCatalogItemsRequest, CallSettings)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(ImportCatalogItemsRequest request, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
request ImportCatalogItemsRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
ImportCatalogItemsRequest request = new ImportCatalogItemsRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    RequestId = "",
    InputConfig = new InputConfig(),
    ErrorsConfig = new ImportErrorsConfig(),
};
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(request);

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

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

ImportCatalogItemsAsync(ImportCatalogItemsRequest, CancellationToken)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(ImportCatalogItemsRequest request, CancellationToken cancellationToken)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
request ImportCatalogItemsRequest

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

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
ImportCatalogItemsRequest request = new ImportCatalogItemsRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    RequestId = "",
    InputConfig = new InputConfig(),
    ErrorsConfig = new ImportErrorsConfig(),
};
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(request);

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

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

ImportCatalogItemsAsync(string, string, InputConfig, ImportErrorsConfig, CallSettings)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(string parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CallSettings callSettings = null)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent string

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(parent, requestId, inputConfig, errorsConfig);

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

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

ImportCatalogItemsAsync(string, string, InputConfig, ImportErrorsConfig, CancellationToken)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> ImportCatalogItemsAsync(string parent, string requestId, InputConfig inputConfig, ImportErrorsConfig errorsConfig, CancellationToken cancellationToken)

Bulk import of multiple catalog items. Request processing may be synchronous. No partial updating supported. Non-existing items will be created.

Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully updated.

Parameters
Name Description
parent string

Required. projects/1234/locations/global/catalogs/default_catalog

requestId string

Optional. Unique identifier provided by client, within the ancestor dataset scope. Ensures idempotency and used for request deduplication. Server-generated if unspecified. Up to 128 characters long. This is returned as google.longrunning.Operation.name in the response.

inputConfig InputConfig

Required. The desired input location of the data.

errorsConfig ImportErrorsConfig

Optional. The desired location of errors incurred during the Import.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
string requestId = "";
InputConfig inputConfig = new InputConfig();
ImportErrorsConfig errorsConfig = new ImportErrorsConfig();
// Make the request
Operation<ImportCatalogItemsResponse, ImportMetadata> response = await catalogServiceClient.ImportCatalogItemsAsync(parent, requestId, inputConfig, errorsConfig);

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

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

ListCatalogItems(CatalogName, string, string, int?, CallSettings)

public virtual PagedEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItems(CatalogName parent, string filter, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
parent CatalogName

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

filter string

Optional. A filter to apply on the list results.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

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 CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListCatalogItemsResponseCatalogItem

A pageable sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
string filter = "";
// Make the request
PagedEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItems(parent, filter);

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

ListCatalogItems(ListCatalogItemsRequest, CallSettings)

public virtual PagedEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItems(ListCatalogItemsRequest request, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
request ListCatalogItemsRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListCatalogItemsResponseCatalogItem

A pageable sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
ListCatalogItemsRequest request = new ListCatalogItemsRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    Filter = "",
};
// Make the request
PagedEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItems(request);

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

ListCatalogItems(string, string, string, int?, CallSettings)

public virtual PagedEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItems(string parent, string filter, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
parent string

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

filter string

Optional. A filter to apply on the list results.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

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 CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedEnumerableListCatalogItemsResponseCatalogItem

A pageable sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
string filter = "";
// Make the request
PagedEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItems(parent, filter);

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

ListCatalogItemsAsync(CatalogName, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItemsAsync(CatalogName parent, string filter, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
parent CatalogName

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

filter string

Optional. A filter to apply on the list results.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

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 CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListCatalogItemsResponseCatalogItem

A pageable asynchronous sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogName parent = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]");
string filter = "";
// Make the request
PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItemsAsync(parent, filter);

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

ListCatalogItemsAsync(ListCatalogItemsRequest, CallSettings)

public virtual PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItemsAsync(ListCatalogItemsRequest request, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
request ListCatalogItemsRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListCatalogItemsResponseCatalogItem

A pageable asynchronous sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
ListCatalogItemsRequest request = new ListCatalogItemsRequest
{
    ParentAsCatalogName = CatalogName.FromProjectLocationCatalog("[PROJECT]", "[LOCATION]", "[CATALOG]"),
    Filter = "",
};
// Make the request
PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItemsAsync(request);

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

ListCatalogItemsAsync(string, string, string, int?, CallSettings)

public virtual PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> ListCatalogItemsAsync(string parent, string filter, string pageToken = null, int? pageSize = null, CallSettings callSettings = null)

Gets a list of catalog items.

Parameters
Name Description
parent string

Required. The parent catalog resource name, such as projects/*/locations/global/catalogs/default_catalog.

filter string

Optional. A filter to apply on the list results.

pageToken string

The token returned from the previous request. A value of null or an empty string retrieves the first page.

pageSize int

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 CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
PagedAsyncEnumerableListCatalogItemsResponseCatalogItem

A pageable asynchronous sequence of CatalogItem resources.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string parent = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]";
string filter = "";
// Make the request
PagedAsyncEnumerable<ListCatalogItemsResponse, CatalogItem> response = catalogServiceClient.ListCatalogItemsAsync(parent, filter);

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

PollOnceImportCatalogItems(string, CallSettings)

public virtual Operation<ImportCatalogItemsResponse, ImportMetadata> PollOnceImportCatalogItems(string operationName, CallSettings callSettings = null)

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

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
OperationImportCatalogItemsResponseImportMetadata

The result of polling the operation.

PollOnceImportCatalogItemsAsync(string, CallSettings)

public virtual Task<Operation<ImportCatalogItemsResponse, ImportMetadata>> PollOnceImportCatalogItemsAsync(string operationName, CallSettings callSettings = null)

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

Parameters
Name Description
operationName string

The name of a previously invoked operation. Must not be null or empty.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskOperationImportCatalogItemsResponseImportMetadata

A task representing the result of polling the operation.

ShutdownDefaultChannelsAsync()

public static Task ShutdownDefaultChannelsAsync()

Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.

Returns
Type Description
Task

A task representing the asynchronous shutdown operation.

Remarks

After calling this method, further calls to Create() and CreateAsync(CancellationToken) will create new channels, which could in turn be shut down by another call to this method.

UpdateCatalogItem(CatalogItemPathName, CatalogItem, FieldMask, CallSettings)

public virtual CatalogItem UpdateCatalogItem(CatalogItemPathName name, CatalogItem catalogItem, FieldMask updateMask, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = catalogServiceClient.UpdateCatalogItem(name, catalogItem, updateMask);

UpdateCatalogItem(UpdateCatalogItemRequest, CallSettings)

public virtual CatalogItem UpdateCatalogItem(UpdateCatalogItemRequest request, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
request UpdateCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
UpdateCatalogItemRequest request = new UpdateCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
    CatalogItem = new CatalogItem(),
    UpdateMask = new FieldMask(),
};
// Make the request
CatalogItem response = catalogServiceClient.UpdateCatalogItem(request);

UpdateCatalogItem(string, CatalogItem, FieldMask, CallSettings)

public virtual CatalogItem UpdateCatalogItem(string name, CatalogItem catalogItem, FieldMask updateMask, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
CatalogItem

The RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = CatalogServiceClient.Create();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = catalogServiceClient.UpdateCatalogItem(name, catalogItem, updateMask);

UpdateCatalogItemAsync(CatalogItemPathName, CatalogItem, FieldMask, CallSettings)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(CatalogItemPathName name, CatalogItem catalogItem, FieldMask updateMask, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(name, catalogItem, updateMask);

UpdateCatalogItemAsync(CatalogItemPathName, CatalogItem, FieldMask, CancellationToken)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(CatalogItemPathName name, CatalogItem catalogItem, FieldMask updateMask, CancellationToken cancellationToken)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name CatalogItemPathName

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
CatalogItemPathName name = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]");
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(name, catalogItem, updateMask);

UpdateCatalogItemAsync(UpdateCatalogItemRequest, CallSettings)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(UpdateCatalogItemRequest request, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
request UpdateCatalogItemRequest

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

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateCatalogItemRequest request = new UpdateCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
    CatalogItem = new CatalogItem(),
    UpdateMask = new FieldMask(),
};
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(request);

UpdateCatalogItemAsync(UpdateCatalogItemRequest, CancellationToken)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(UpdateCatalogItemRequest request, CancellationToken cancellationToken)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
request UpdateCatalogItemRequest

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

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
UpdateCatalogItemRequest request = new UpdateCatalogItemRequest
{
    CatalogItemPathName = CatalogItemPathName.FromProjectLocationCatalogCatalogItemPath("[PROJECT]", "[LOCATION]", "[CATALOG]", "[CATALOG_ITEM_PATH]"),
    CatalogItem = new CatalogItem(),
    UpdateMask = new FieldMask(),
};
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(request);

UpdateCatalogItemAsync(string, CatalogItem, FieldMask, CallSettings)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(string name, CatalogItem catalogItem, FieldMask updateMask, CallSettings callSettings = null)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

callSettings CallSettings

If not null, applies overrides to this RPC call.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(name, catalogItem, updateMask);

UpdateCatalogItemAsync(string, CatalogItem, FieldMask, CancellationToken)

public virtual Task<CatalogItem> UpdateCatalogItemAsync(string name, CatalogItem catalogItem, FieldMask updateMask, CancellationToken cancellationToken)

Updates a catalog item. Partial updating is supported. Non-existing items will be created.

Parameters
Name Description
name string

Required. Full resource name of catalog item, such as projects/*/locations/global/catalogs/default_catalog/catalogItems/some_catalog_item_id.

catalogItem CatalogItem

Required. The catalog item to update/create. The 'catalog_item_id' field has to match that in the 'name'.

updateMask FieldMask

Optional. Indicates which fields in the provided 'item' to update. If not set, will by default update all fields.

cancellationToken CancellationToken

A CancellationToken to use for this RPC.

Returns
Type Description
TaskCatalogItem

A Task containing the RPC response.

Example
// Create client
CatalogServiceClient catalogServiceClient = await CatalogServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "projects/[PROJECT]/locations/[LOCATION]/catalogs/[CATALOG]/catalogItems/[CATALOG_ITEM_PATH]";
CatalogItem catalogItem = new CatalogItem();
FieldMask updateMask = new FieldMask();
// Make the request
CatalogItem response = await catalogServiceClient.UpdateCatalogItemAsync(name, catalogItem, updateMask);