Google Shopping Merchant Lfp V1beta Client - Class LfpSale (0.1.2)

Reference documentation and code samples for the Google Shopping Merchant Lfp V1beta Client class LfpSale.

A sale for the merchant.

Generated from protobuf message google.shopping.merchant.lfp.v1beta.LfpSale

Namespace

Google \ Shopping \ Merchant \ Lfp \ V1beta

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ name string

Output only. Identifier. The name of the LfpSale resource. Format: accounts/{account}/lfpSales/{sale}

↳ target_account int|string

Required. The Merchant Center ID of the merchant to submit the sale for.

↳ store_code string

Required. The identifier of the merchant's store. Either a storeCode inserted through the API or the code of the store in the Business Profile.

↳ offer_id string

Required. A unique identifier for the product. If both inventories and sales are submitted for a merchant, this id should match for the same product. Note: if the merchant sells the same product new and used, they should have different IDs.

↳ region_code string

Required. The CLDR territory code for the country where the product is sold.

↳ content_language string

Required. The two-letter ISO 639-1 language code for the item.

↳ gtin string

Required. The Global Trade Item Number of the sold product.

↳ price Google\Shopping\Type\Price

Required. The unit price of the product.

↳ quantity int|string

Required. The relative change of the available quantity. Negative for items returned.

↳ sale_time Google\Protobuf\Timestamp

Required. The timestamp for the sale.

↳ uid string

Output only. System generated globally unique ID for the LfpSale.

↳ feed_label string

Optional. The feed label for the product. If this is not set, it will default to regionCode.

getName

Output only. Identifier. The name of the LfpSale resource.

Format: accounts/{account}/lfpSales/{sale}

Returns
Type Description
string

setName

Output only. Identifier. The name of the LfpSale resource.

Format: accounts/{account}/lfpSales/{sale}

Parameter
Name Description
var string
Returns
Type Description
$this

getTargetAccount

Required. The Merchant Center ID of the merchant to submit the sale for.

Returns
Type Description
int|string

setTargetAccount

Required. The Merchant Center ID of the merchant to submit the sale for.

Parameter
Name Description
var int|string
Returns
Type Description
$this

getStoreCode

Required. The identifier of the merchant's store. Either a storeCode inserted through the API or the code of the store in the Business Profile.

Returns
Type Description
string

setStoreCode

Required. The identifier of the merchant's store. Either a storeCode inserted through the API or the code of the store in the Business Profile.

Parameter
Name Description
var string
Returns
Type Description
$this

getOfferId

Required. A unique identifier for the product. If both inventories and sales are submitted for a merchant, this id should match for the same product.

Note: if the merchant sells the same product new and used, they should have different IDs.

Returns
Type Description
string

setOfferId

Required. A unique identifier for the product. If both inventories and sales are submitted for a merchant, this id should match for the same product.

Note: if the merchant sells the same product new and used, they should have different IDs.

Parameter
Name Description
var string
Returns
Type Description
$this

getRegionCode

Required. The CLDR territory code for the country where the product is sold.

Returns
Type Description
string

setRegionCode

Required. The CLDR territory code for the country where the product is sold.

Parameter
Name Description
var string
Returns
Type Description
$this

getContentLanguage

Required. The two-letter ISO 639-1 language code for the item.

Returns
Type Description
string

setContentLanguage

Required. The two-letter ISO 639-1 language code for the item.

Parameter
Name Description
var string
Returns
Type Description
$this

getGtin

Required. The Global Trade Item Number of the sold product.

Returns
Type Description
string

setGtin

Required. The Global Trade Item Number of the sold product.

Parameter
Name Description
var string
Returns
Type Description
$this

getPrice

Required. The unit price of the product.

Returns
Type Description
Google\Shopping\Type\Price|null

hasPrice

clearPrice

setPrice

Required. The unit price of the product.

Parameter
Name Description
var Google\Shopping\Type\Price
Returns
Type Description
$this

getQuantity

Required. The relative change of the available quantity. Negative for items returned.

Returns
Type Description
int|string

setQuantity

Required. The relative change of the available quantity. Negative for items returned.

Parameter
Name Description
var int|string
Returns
Type Description
$this

getSaleTime

Required. The timestamp for the sale.

Returns
Type Description
Google\Protobuf\Timestamp|null

hasSaleTime

clearSaleTime

setSaleTime

Required. The timestamp for the sale.

Parameter
Name Description
var Google\Protobuf\Timestamp
Returns
Type Description
$this

getUid

Output only. System generated globally unique ID for the LfpSale.

Returns
Type Description
string

hasUid

clearUid

setUid

Output only. System generated globally unique ID for the LfpSale.

Parameter
Name Description
var string
Returns
Type Description
$this

getFeedLabel

Optional. The feed label for the product. If this is not set, it will default to regionCode.

Returns
Type Description
string

hasFeedLabel

clearFeedLabel

setFeedLabel

Optional. The feed label for the product. If this is not set, it will default to regionCode.

Parameter
Name Description
var string
Returns
Type Description
$this