Class ProductInputsServiceClient
ProductInputsService client wrapper, for convenient use.
Namespace: Google.Shopping.Merchant.Products.V1Beta
Assembly: Google.Shopping.Merchant.Products.V1Beta.dll
Syntax
public abstract class ProductInputsServiceClient
Remarks
Service to use ProductInput resource. This service works for products with online channel only.
Properties
DefaultEndpoint
The default endpoint for the ProductInputsService service, which is a host of "merchantapi.googleapis.com" and a port of 443.
Declaration
public static string DefaultEndpoint { get; }
Property Value
Type | Description |
---|---|
string |
DefaultScopes
The default ProductInputsService scopes.
Declaration
public static IReadOnlyList<string> DefaultScopes { get; }
Property Value
Type | Description |
---|---|
IReadOnlyList<string> |
Remarks
The default ProductInputsService scopes are:
- https://www.googleapis.com/auth/content
GrpcClient
The underlying gRPC ProductInputsService client
Declaration
public virtual ProductInputsService.ProductInputsServiceClient GrpcClient { get; }
Property Value
Type | Description |
---|---|
ProductInputsService.ProductInputsServiceClient |
ServiceMetadata
The service metadata associated with this client type.
Declaration
public static ServiceMetadata ServiceMetadata { get; }
Property Value
Type | Description |
---|---|
ServiceMetadata |
Methods
Create()
Synchronously creates a ProductInputsServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ProductInputsServiceClientBuilder.
Declaration
public static ProductInputsServiceClient Create()
Returns
Type | Description |
---|---|
ProductInputsServiceClient | The created ProductInputsServiceClient. |
CreateAsync(CancellationToken)
Asynchronously creates a ProductInputsServiceClient using the default credentials, endpoint and settings. To specify custom credentials or other settings, use ProductInputsServiceClientBuilder.
Declaration
public static Task<ProductInputsServiceClient> CreateAsync(CancellationToken cancellationToken = default)
Parameters
Type | Name | Description |
---|---|---|
CancellationToken | cancellationToken | The CancellationToken to use while creating the client. |
Returns
Type | Description |
---|---|
Task<ProductInputsServiceClient> | The task representing the created ProductInputsServiceClient. |
DeleteProductInput(DeleteProductInputRequest, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual void DeleteProductInput(DeleteProductInputRequest request, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
DeleteProductInputRequest | request | The request object containing all of the parameters for the API call. |
CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = ProductInputsServiceClient.Create();
// Initialize request argument(s)
DeleteProductInputRequest request = new DeleteProductInputRequest
{
ProductInputName = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]"),
DataSource = "",
};
// Make the request
productInputsServiceClient.DeleteProductInput(request);
DeleteProductInput(ProductInputName, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual void DeleteProductInput(ProductInputName name, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
ProductInputName | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = ProductInputsServiceClient.Create();
// Initialize request argument(s)
ProductInputName name = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]");
// Make the request
productInputsServiceClient.DeleteProductInput(name);
DeleteProductInput(string, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual void DeleteProductInput(string name, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
string | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = ProductInputsServiceClient.Create();
// Initialize request argument(s)
string name = "accounts/[ACCOUNT]/productInputs/[PRODUCTINPUT]";
// Make the request
productInputsServiceClient.DeleteProductInput(name);
DeleteProductInputAsync(DeleteProductInputRequest, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(DeleteProductInputRequest request, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
DeleteProductInputRequest | request | 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. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteProductInputRequest request = new DeleteProductInputRequest
{
ProductInputName = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]"),
DataSource = "",
};
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(request);
DeleteProductInputAsync(DeleteProductInputRequest, CancellationToken)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(DeleteProductInputRequest request, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
DeleteProductInputRequest | request | 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. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
DeleteProductInputRequest request = new DeleteProductInputRequest
{
ProductInputName = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]"),
DataSource = "",
};
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(request);
DeleteProductInputAsync(ProductInputName, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(ProductInputName name, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
ProductInputName | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
Type | Description |
---|---|
Task | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
ProductInputName name = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]");
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(name);
DeleteProductInputAsync(ProductInputName, CancellationToken)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(ProductInputName name, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
ProductInputName | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
Type | Description |
---|---|
Task | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
ProductInputName name = ProductInputName.FromAccountProductinput("[ACCOUNT]", "[PRODUCTINPUT]");
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(name);
DeleteProductInputAsync(string, CallSettings)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(string name, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
string | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CallSettings | callSettings | If not null, applies overrides to this RPC call. |
Returns
Type | Description |
---|---|
Task | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "accounts/[ACCOUNT]/productInputs/[PRODUCTINPUT]";
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(name);
DeleteProductInputAsync(string, CancellationToken)
Deletes a product input from your Merchant Center account.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task DeleteProductInputAsync(string name, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
string | name | Required. The name of the product input resource to delete. Format: accounts/{account}/productInputs/{product} |
CancellationToken | cancellationToken | A CancellationToken to use for this RPC. |
Returns
Type | Description |
---|---|
Task | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
string name = "accounts/[ACCOUNT]/productInputs/[PRODUCTINPUT]";
// Make the request
await productInputsServiceClient.DeleteProductInputAsync(name);
InsertProductInput(InsertProductInputRequest, CallSettings)
Uploads a product input to your Merchant Center account. If an input with the same contentLanguage, offerId, and dataSource already exists, this method replaces that entry.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual ProductInput InsertProductInput(InsertProductInputRequest request, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
InsertProductInputRequest | request | 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 |
---|---|
ProductInput | The RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = ProductInputsServiceClient.Create();
// Initialize request argument(s)
InsertProductInputRequest request = new InsertProductInputRequest
{
ParentAsAccountName = AccountName.FromAccount("[ACCOUNT]"),
ProductInput = new ProductInput(),
DataSource = "",
};
// Make the request
ProductInput response = productInputsServiceClient.InsertProductInput(request);
InsertProductInputAsync(InsertProductInputRequest, CallSettings)
Uploads a product input to your Merchant Center account. If an input with the same contentLanguage, offerId, and dataSource already exists, this method replaces that entry.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task<ProductInput> InsertProductInputAsync(InsertProductInputRequest request, CallSettings callSettings = null)
Parameters
Type | Name | Description |
---|---|---|
InsertProductInputRequest | request | 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<ProductInput> | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
InsertProductInputRequest request = new InsertProductInputRequest
{
ParentAsAccountName = AccountName.FromAccount("[ACCOUNT]"),
ProductInput = new ProductInput(),
DataSource = "",
};
// Make the request
ProductInput response = await productInputsServiceClient.InsertProductInputAsync(request);
InsertProductInputAsync(InsertProductInputRequest, CancellationToken)
Uploads a product input to your Merchant Center account. If an input with the same contentLanguage, offerId, and dataSource already exists, this method replaces that entry.
After inserting, updating, or deleting a product input, it may take several minutes before the processed product can be retrieved.
Declaration
public virtual Task<ProductInput> InsertProductInputAsync(InsertProductInputRequest request, CancellationToken cancellationToken)
Parameters
Type | Name | Description |
---|---|---|
InsertProductInputRequest | request | 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<ProductInput> | A Task containing the RPC response. |
Sample code
// Create client
ProductInputsServiceClient productInputsServiceClient = await ProductInputsServiceClient.CreateAsync();
// Initialize request argument(s)
InsertProductInputRequest request = new InsertProductInputRequest
{
ParentAsAccountName = AccountName.FromAccount("[ACCOUNT]"),
ProductInput = new ProductInput(),
DataSource = "",
};
// Make the request
ProductInput response = await productInputsServiceClient.InsertProductInputAsync(request);
ShutdownDefaultChannelsAsync()
Shuts down any channels automatically created by Create() and CreateAsync(CancellationToken). Channels which weren't automatically created are not affected.
Declaration
public static Task ShutdownDefaultChannelsAsync()
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.