REST Resource: accounts.products

Resource: Product

The processed product, built from multiple product inputs after applying rules and supplemental data sources. This processed product matches what is shown in your Merchant Center account and in Shopping ads and other surfaces across Google. Each product is built from exactly one primary data source product input, and multiple supplemental data source inputs. After inserting, updating, or deleting a product input, it may take several minutes before the updated processed product can be retrieved.

All fields in the processed product and its sub-messages match the name of their corresponding attribute in the Product data specification with some exceptions.

JSON representation
{
  "name": string,
  "channel": enum (ChannelEnum),
  "offerId": string,
  "contentLanguage": string,
  "feedLabel": string,
  "dataSource": string,
  "attributes": {
    object (Attributes)
  },
  "customAttributes": [
    {
      object (CustomAttribute)
    }
  ],
  "productStatus": {
    object (ProductStatus)
  },
  "versionNumber": string
}
Fields
name

string

The name of the product. Format: "{product.name=accounts/{account}/products/{product}}" where the last section product consists of 4 parts: channel~contentLanguage~feedLabel~offerId example for product name is "accounts/123/products/online~en~US~sku123"

channel

enum (ChannelEnum)

Output only. The channel of the product.

offerId

string

Output only. Your unique identifier for the product. This is the same for the product input and processed product. Leading and trailing whitespaces are stripped and multiple whitespaces are replaced by a single whitespace upon submission. See the product data specification for details.

contentLanguage

string

Output only. The two-letter ISO 639-1 language code for the product.

feedLabel

string

Output only. The feed label for the product.

dataSource

string

Output only. The primary data source of the product.

attributes

object (Attributes)

Output only. A list of product attributes.

customAttributes[]

object (CustomAttribute)

Output only. A list of custom (merchant-provided) attributes. It can also be used to submit any attribute of the data specification in its generic form (for example, { "name": "size type", "value": "regular" }). This is useful for submitting attributes not explicitly exposed by the API, such as additional attributes used for Buy on Google.

productStatus

object (ProductStatus)

Output only. The status of a product, data validation issues, that is, information about a product computed asynchronously.

versionNumber

string (int64 format)

Output only. Represents the existing version (freshness) of the product, which can be used to preserve the right order when multiple updates are done at the same time.

If set, the insertion is prevented when version number is lower than the current version number of the existing product. Re-insertion (for example, product refresh after 30 days) can be performed with the current versionNumber.

Only supported for insertions into primary data sources.

If the operation is prevented, the aborted exception will be thrown.

ProductStatus

The status of a product, data validation issues, that is, information about a product computed asynchronously.

JSON representation
{
  "destinationStatuses": [
    {
      object (DestinationStatus)
    }
  ],
  "itemLevelIssues": [
    {
      object (ItemLevelIssue)
    }
  ],
  "creationDate": string,
  "lastUpdateDate": string,
  "googleExpirationDate": string
}
Fields
destinationStatuses[]

object (DestinationStatus)

The intended destinations for the product.

itemLevelIssues[]

object (ItemLevelIssue)

A list of all issues associated with the product.

creationDate

string (Timestamp format)

Date on which the item has been created, in ISO 8601 format.

lastUpdateDate

string (Timestamp format)

Date on which the item has been last updated, in ISO 8601 format.

googleExpirationDate

string (Timestamp format)

Date on which the item expires, in ISO 8601 format.

DestinationStatus

The destination status of the product status.

JSON representation
{
  "reportingContext": enum (ReportingContextEnum),
  "approvedCountries": [
    string
  ],
  "pendingCountries": [
    string
  ],
  "disapprovedCountries": [
    string
  ]
}
Fields
reportingContext

enum (ReportingContextEnum)

The name of the reporting context.

approvedCountries[]

string

List of country codes (ISO 3166-1 alpha-2) where the offer is approved.

pendingCountries[]

string

List of country codes (ISO 3166-1 alpha-2) where the offer is pending approval.

disapprovedCountries[]

string

List of country codes (ISO 3166-1 alpha-2) where the offer is disapproved.

ItemLevelIssue

The ItemLevelIssue of the product status.

JSON representation
{
  "code": string,
  "severity": enum (Severity),
  "resolution": string,
  "attribute": string,
  "reportingContext": enum (ReportingContextEnum),
  "description": string,
  "detail": string,
  "documentation": string,
  "applicableCountries": [
    string
  ]
}
Fields
code

string

The error code of the issue.

severity

enum (Severity)

How this issue affects serving of the offer.

resolution

string

Whether the issue can be resolved by the merchant.

attribute

string

The attribute's name, if the issue is caused by a single attribute.

reportingContext

enum (ReportingContextEnum)

The reporting context the issue applies to.

description

string

A short issue description in English.

detail

string

A detailed issue description in English.

documentation

string

The URL of a web page to help with resolving this issue.

applicableCountries[]

string

List of country codes (ISO 3166-1 alpha-2) where issue applies to the offer.

Severity

How the issue affects the serving of the product.

Enums
SEVERITY_UNSPECIFIED Not specified.
NOT_IMPACTED This issue represents a warning and does not have a direct affect on the product.
DEMOTED The product is demoted and most likely have limited performance in search results
DISAPPROVED Issue disapproves the product.

Methods

get

Retrieves the processed product from your Merchant Center account.

list

Lists the processed products in your Merchant Center account.