Module: Google::Shopping::Merchant::Lfp::V1beta::LfpStoreService::Paths

Extended by:
Paths
Included in:
Client, Paths, Rest::Client
Defined in:
lib/google/shopping/merchant/lfp/v1beta/lfp_store_service/paths.rb

Overview

Path helper methods for the LfpStoreService API.

Instance Method Summary collapse

Instance Method Details

#account_path(account:) ⇒ ::String

Create a fully-qualified Account resource string.

The resource will be in the following format:

accounts/{account}

Parameters:

  • account (String)

Returns:

  • (::String)


38
39
40
# File 'lib/google/shopping/merchant/lfp/v1beta/lfp_store_service/paths.rb', line 38

def  account:
  "accounts/#{}"
end

#lfp_store_path(account:, target_merchant:, store_code:) ⇒ ::String

Create a fully-qualified LfpStore resource string.

The resource will be in the following format:

accounts/{account}/lfpStores/{target_merchant}~{store_code}

Parameters:

  • account (String)
  • target_merchant (String)
  • store_code (String)

Returns:

  • (::String)

Raises:

  • (::ArgumentError)


54
55
56
57
58
59
# File 'lib/google/shopping/merchant/lfp/v1beta/lfp_store_service/paths.rb', line 54

def lfp_store_path account:, target_merchant:, store_code:
  raise ::ArgumentError, "account cannot contain /" if .to_s.include? "/"
  raise ::ArgumentError, "target_merchant cannot contain /" if target_merchant.to_s.include? "/"

  "accounts/#{}/lfpStores/#{target_merchant}~#{store_code}"
end