+-
如何在Google搜索“application / ld + json”脚本中指定产品ID,而不会显示“缺少产品ID(可选)”

如何在Google搜索控制台中的“application / ld + json”脚本中减少“缺少产品ID(可选)”的警告?

在我的示例JSON-LD代码下面

<script type="application/ld+json">
{
  "@context": "http://schema.org/",
  "@type": "Product",
  "name": "done product Name here",
  "url": "done product url here",
  "image": [
      "done image url here"
    ],
  "description": "done description here",
  "sku": "H100000001",
  "productID" : "9876543210",  // Added like this type behaviour
  "brand": {
    "@type": "Thing",
    "name": "cosmetics"
  },
  "offers": [{
        "@type" : "Offer",
        "sku": "H100000002",
        "availability" : "http://schema.org/InStock",
        "price" : "26.0",
        "priceCurrency" : "USD",
        "url" : "product url"
      },
      {
        "@type" : "Offer",
        "sku": "H100000003",
        "availability" : "http://schema.org/InStock",
        "price" : "26.0",
        "priceCurrency" : "USD",
        "url" : "product url"
      },
      {
        "@type" : "Offer",
        "sku": "H099020004",
        "availability" : "http://schema.org/InStock",
        "price" : "26.0",
        "priceCurrency" : "USD",
        "url" : "product url"
      }]
}
</script>

我在下面尝试了不同的产品ID变量

1. "productID" : "9876543210",

2. "productID" : "isbn:9876543210",

3. "product-id" : "isbn:9876543210",

4. "product-id" : "9876543210",

但错误仍然存​​在。

enter image description here

任何人都可以帮助我如何在Google Search Console上解决“缺少产品ID(可选)”的问题?

哪个行为在ld + json中设置产品ID是正确的?

2
投票

来自Google的消息不是很清楚......它正在寻找的是来自https://schema.org/Product(gtin13等)的产品ID之一。添加ProductID后我收到了同样的错误,但是一旦我用gtinxxx值替换了ProductID,警告便消失了。