关于 google-shopping-feed
google-shopping-feed 是面向电商商家的技能,帮助将商品数据提交到 Google Merchant Center,并改善 Shopping 广告的商品信息质量。内容涵盖平台集成、信息流优化和商品拒登排查。
主要功能
- 01连接商店与 Merchant Center
- 02生成并同步商品信息流
- 03优化标题、GTIN 和商品类别
- 04排查商品拒登与信息错误
适用场景
- 01首次设置 Google Shopping Ads
- 02解决 Merchant Center 中的商品拒登
- 03改善商品标题以匹配搜索查询
- 04管理多国家或多币种商品信息流
安装
复制下面的命令,在终端中运行。
npx skills add https:/ / github.com/ finsilabs/ awesome-ecommerce-skills --skill google-shopping-feed安装后在 Claude Code 中输入/google-shopping-feed确认已加载。
包含的文件
除 SKILL.md 外,安装时一起下载的参考资料和脚本。
tile.jsonevals/content-api-batch-updates-and-supplement/criteria.jsontask.mdevals/feed-audit-multi-country-setup-and-varia/criteria.jsontask.mdevals/xml-feed-structure-and-title-optimizatio/criteria.jsontask.md详细介绍
Google 购物 Feed
概述
Google Merchant Center 要求产品数据 Feed 包含特定属性,才能投放购物广告。Shopify、WooCommerce 和 BigCommerce 均提供官方 Google 集成,可自动生成 Feed。本技能介绍如何设置集成、优化 Feed 质量(这是影响购物排名的首要因素),以及解决常见的商品拒登问题。
何时使用此技能
- 首次设置 Google 购物广告时
- 商品因 Feed 质量问题在 Merchant Center 中被拒登时
- Feed 中的价格或库存状况未能及时与网站实时信息同步时
- 优化 Feed 标题和说明,以匹配更多相关搜索查询时
- 管理面向多个国家或货币的 Feed 时
核心说明
第 1 步:设置 Google Merchant Center 账号
- 前往 merchants.google.com 并创建账号
- 在 商家信息 → 网站 下验证并认领商店的域名(向商店添加元标记或上传文件)
- 接受 Merchant Center 的条款和政策
- 关联 Google Ads 账号:设置 → 已关联的账号 → Google Ads
第 2 步:将平台连接到 Merchant Center
Shopify
- 前往 Shopify 管理后台 → 销售渠道 → + → Google & YouTube
- 安装 Google & YouTube 渠道
- 连接 Google 账号并选择 Merchant Center 账号
- 在 产品 Feed 下,Shopify 会自动同步整个目录及所有必需属性(标题、价格、库存状况、图片,以及提供的 GTIN)
- 前往 Google & YouTube → 概览,确认 Feed 同步状态
- 在 Merchant Center 中查看 产品 → 问题,了解是否有商品被拒登
提升 Shopify Feed 质量:
- 确保每件商品都有:清晰的标题(品牌 + 商品名称)、说明、主图和正确的商品类型
- 在 产品 → [商品] → 变体 → 条形码 下为商品添加 GTIN(条形码)——GTIN 可显著提高购物广告的展示份额
- 对于 Google 商品类别,可从 Shopify App Store 安装 Google Shopping Feed 或 Feedonomics 应用,将 Shopify 商品类型映射到 Google 分类法 ID
WooCommerce
- 从 WordPress 插件目录安装 Google Listings & Ads 插件(免费的 Google 官方插件)
- 前往 WooCommerce → Google Listings & Ads 并连接 Google 账号
- 完成设置向导——如果你还没有 Merchant Center 账号,向导会创建一个并提交 Feed
- 商品会从 WooCommerce 自动同步;前往 Google Listings & Ads → Product Feed 查看同步状态
如需更多控制:安装 WooCommerce Product Feed Pro(每年 70 美元)——它可让你全面控制 Feed 属性、自定义标签和促销补充 Feed。
为 WooCommerce 商品添加 Google 商品类别:
- 在 WooCommerce 管理后台中打开各个商品或商品类别
- Google Listings & Ads 插件会添加一个“Google 类别”字段——请使用 Google 的商品分类法填写该字段
BigCommerce
- 前往 BigCommerce 管理后台 → 渠道管理器
- 点击 添加渠道 → Google 购物
- 连接 Google Merchant Center 账号——BigCommerce 会自动在
yourstore.com/xmlfeed.xml创建 Feed - 在 渠道管理器 → Google 购物 → 商品 中查看商品状态和拒登情况
如需增强 Feed 优化功能,可从 BigCommerce App Marketplace 安装 GoDataFeed 或 Feedonomics。
自定义 / 无头架构
生成符合标准的 XML Feed 端点,供 Google 抓取:
import { create } from 'xmlbuilder2';
export async function generateGoogleShoppingFeed(req: Request, res: Response) {
const products = await db.products.findAll({
where: { status: 'active' },
include: ['variants', 'images'],
});
const root = create({ version: '1.0', encoding: 'UTF-8' })
.ele('rss', { version: '2.0', 'xmlns:g': 'http://base.google.com/ns/1.0' })
.ele('channel')
.ele('title').txt(process.env.STORE_NAME!).up()
.ele('link').txt(process.env.STORE_URL!).up();
for (const product of products) {
for (const variant of product.variants) {
const item = root.ele('item');
item.ele('g:id').txt(variant.sku).up();
// Title format: Brand + Product Name + Key Attribute (Color/Size)
item.ele('g:title').txt(
[product.brand, product.name, variant.color, variant.size].filter(Boolean).join(' ').slice(0, 150)
).up();
item.ele('g:description').txt(product.description.slice(0, 5000)).up();
item.ele('g:link').txt(`${process.env.STORE_URL}/products/${product.slug}?variant=${variant.id}`).up();
item.ele('g:image_link').txt(product.images[0]?.url ?? '').up();
item.ele('g:condition').txt('new').up();
item.ele('g:availability').txt(variant.inventory > 0 ? 'in_stock' : 'out_of_stock').up();
item.ele('g:price').txt(`${(variant.priceInCents / 100).toFixed(2)} USD`).up();
item.ele('g:brand').txt(product.brand ?? process.env.STORE_NAME!).up();
item.ele('g:google_product_category').txt(product.googleProductCategory).up();
item.ele('g:item_group_id').txt(product.id).up(); // groups variants together
if (variant.color) item.ele('g:color').txt(variant.color).up();
if (variant.size) item.ele('g:size').txt(variant.size).up();
if (product.gtin) item.ele('g:gtin').txt(product.gtin).up();
item.ele('g:identifier_exists').txt(product.gtin ? 'yes' : 'no').up();
}
}
res.setHeader('Content-Type', 'application/xml; charset=utf-8');
res.setHeader('Cache-Control', 'public, max-age=3600');
res.send(root.end({ prettyPrint: false }));
}
在 Merchant Center 的 产品 → Feed → 添加主要 Feed 下注册此 Feed URL。
使用 Content API 推送实时价格和库存更新,而不是等待 Google 按计划抓取:
import { google } from 'googleapis';
const content = google.content({ version: 'v2.1', auth: await new google.auth.GoogleAuth({
keyFile: process.env.GOOGLE_SERVICE_ACCOUNT_KEY_PATH,
scopes: ['https://www.googleapis.com/auth/content'],
}).getClient() });
// Push updated product when inventory or price changes
await content.products.insert({
merchantId: process.env.GOOGLE_MERCHANT_ID,
requestBody: {
offerId: variant.sku,
availability: variant.inventory > 0 ? 'in_stock' : 'out_of_stock',
price: { value: (variant.priceInCents / 100).toFixed(2), currency: 'USD' },
contentLanguage: 'en',
targetCountry: 'US',
channel: 'online',
},
});
第 3 步:优化商品 Feed 质量
Feed 质量是 Shopping 排名的首要因素。请按影响程度依次解决以下问题:
-
优化商品标题 — 将品牌和关键属性放在前面(Google 会在约 70 个字符后截断):
- 好:"Nike Air Max 90 White Men's Size 10"
- 不好:"Air Max 90 - Various Colors Available"
-
添加 GTIN/条形码 — 缺少 GTIN 是导致展示份额下降的最常见原因;为每件有条形码的商品添加条形码
-
设置 Google 商品类别 — 使用 Google 的分类体系(搜索 "Google Product Taxonomy")并为每种商品类型设置映射;使用数字 ID 以实现精确匹配
-
确保着陆页价格与 Feed 价格一致 — 即使相差 $0.01,也会因价格不匹配而被拒登;每周检查 Merchant Center → Diagnostics
-
添加多张商品图片 — 有 3 张或更多图片的商品质量评分更高;生活场景图片和白底图片都有帮助
第 4 步:解决常见的拒登问题
在 Merchant Center 中,前往 Products → Diagnostics 查看所有问题:
| 拒登原因 | 解决方法 |
|---|---|
| 价格不匹配 | 确保 Feed 价格与商品页面上的 schema.org 价格完全一致 |
| 缺少必填属性 | 添加缺失字段:通常是 brand、gtin 或 google_product_category |
| 图片尺寸过小 | 使用至少为 500×500px 的图片;建议使用 1000×1000px |
| 着陆页错误 | 确认 Feed 中的商品 URL 返回 200 状态码 |
| 违反政策 | 阅读具体政策 — 常见问题包括:药品宣传、版权图片、假冒商品 |
最佳实践
- 将关键词前置到标题中 — Google 会在界面中截断超过约 70 个字符的标题;将品牌和商品名称放在前面
- 为促销活动注册补充 Feed — 无需修改主 Feed 即可叠加促销价;可降低促销期间的拒登风险
- 将 Feed 响应缓存 1 小时 — Merchant Center 会频繁抓取;避免每次请求都给数据库造成过大压力
- 每天监控拒登率 — 拒登率突然上升通常意味着最近的部署更改了 URL 格式或价格格式
- 仅对确实没有任何 GTIN/MPN 的自有品牌商品设置
identifier_exists: no— 误用会导致实际具有商品标识符的商品被拒登
常见问题
| 问题 | 解决方法 |
|---|---|
| 商品已获批准,却未出现在 Shopping 广告中 | 检查 targetCountry 和 contentLanguage 是否与关联的 Google Ads 广告系列定位设置一致 |
| 部署后 Feed 抓取返回 404 | Feed URL 已在 Merchant Center 中注册 — 确保部署后路由仍然存在 |
| 自有品牌商品提示需要 GTIN | 设置 identifier_exists: no,并改为提供品牌和 MPN |
| 多个变体显示为不同商品 | 确保所有变体使用相同的 item_group_id,且仅在 color、size 或 pattern 上有所不同 |
| Shopify Feed 同步卡住 | 在 Shopify 中,前往 Google & YouTube → 断开连接并重新连接集成;或使用 Simprosys 等第三方 Feed 应用 |
相关技能
- @google-ads-ecommerce
- @ecommerce-seo
- @meta-ads-integration
- @marketing-attribution-dashboard