Retail V2 API - Class Google::Cloud::Retail::V2::ProductService::Rest::ServiceStub (v0.21.0)

Reference documentation and code samples for the Retail V2 API class Google::Cloud::Retail::V2::ProductService::Rest::ServiceStub.

REST service stub for the ProductService service. Service stub contains baseline method implementations including transcoding, making the REST call, and deserialing the response.

Inherits

  • Object

Methods

#add_fulfillment_places

def add_fulfillment_places(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the add_fulfillment_places REST call

Parameters
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#add_local_inventories

def add_local_inventories(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the add_local_inventories REST call

Parameters
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#create_product

def create_product(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::Retail::V2::Product

Baseline implementation for the create_product REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::CreateProductRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#delete_product

def delete_product(request_pb, options = nil) { |result, operation| ... } -> ::Google::Protobuf::Empty

Baseline implementation for the delete_product REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::DeleteProductRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#endpoint

def endpoint() -> String

The effective endpoint

Returns
  • (String)

#get_product

def get_product(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::Retail::V2::Product

Baseline implementation for the get_product REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::GetProductRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#import_products

def import_products(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the import_products REST call

Parameters
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#initialize

def initialize(endpoint:, endpoint_template:, universe_domain:, credentials:) -> ServiceStub
Returns

#list_products

def list_products(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::Retail::V2::ListProductsResponse

Baseline implementation for the list_products REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::ListProductsRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#purge_products

def purge_products(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the purge_products REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::PurgeProductsRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#remove_fulfillment_places

def remove_fulfillment_places(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the remove_fulfillment_places REST call

Parameters
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#remove_local_inventories

def remove_local_inventories(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the remove_local_inventories REST call

Parameters
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#set_inventory

def set_inventory(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the set_inventory REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::SetInventoryRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)

#universe_domain

def universe_domain() -> String

The effective universe domain

Returns
  • (String)

#update_product

def update_product(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::Retail::V2::Product

Baseline implementation for the update_product REST call

Parameters
  • request_pb (::Google::Cloud::Retail::V2::UpdateProductRequest) — A request object representing the call parameters. Required.
  • options (::Gapic::CallOptions) — Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
Yields
  • (result, operation) — Access the result along with the TransportOperation object
Yield Parameters
Returns
Raises
  • (::ArgumentError)