查看產品統計資料和問題
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
你可以使用 aggregateProductStatuses.list
方法,取得 Merchant Center 帳戶中產品狀態的高階總覽。這項功能有助於監控產品資料的整體健康狀態,不必擷取每項產品的資料。這個方法會提供產品總數,並依狀態 (已核准、待處理、已拒登) 細分,也會列出影響產品的任何問題。
特殊注意事項
使用 aggregateProductStatuses.list
方法時,請特別留意以下事項。
- 資料可用性:插入或更新產品後,系統可能需要超過 30 分鐘,才會在
aggregateProductStatuses
回應中反映產品狀態。
- 問題一致性:
aggregateProductStatuses.list
方法傳回的問題標題和說明,應與 Products API 傳回的問題一致。不過,這些說明可能與 Merchant Center 使用者介面中顯示的問題說明不同。
查看所有產品狀態的總覽
這個範例說明如何擷取 AggregateProductStatus
資源清單。每個資源代表特定目的地和國家/地區組合的產品狀態。呼叫
aggregateProductStatuses.list
不含任何參數,會傳回帳戶的所有可用狀態。
GET https://merchantapi.googleapis.com/accounts/v1/accounts/{ACCOUNT_ID}/aggregateProductStatuses
以下是成功呼叫的回應範例:
{
"aggregateProductStatuses": [
{
"name": "accounts/12345/aggregateProductStatuses/SHOPPING_ADS~US",
"reportingContext": "SHOPPING_ADS",
"countryCode": "US",
"statistics": {
"approvedCount": "1500",
"pendingCount": "50",
"disapprovedCount": "25"
},
"issues": [
{
"issueType": "missing_image",
"severity": "ERROR",
"numProducts": "15",
"sampleProducts": [
"accounts/12345/products/online~en~US~SKU001",
"accounts/12345/products/online~en~US~SKU002"
]
},
{
"issueType": "invalid_price",
"severity": "CRITICAL",
"numProducts": "10",
"sampleProducts": [
"accounts/12345/products/online~en~US~SKU003"
]
}
]
},
{
"name": "accounts/12345/aggregateProductStatuses/FREE_LISTINGS~US",
"reportingContext": "FREE_LISTINGS",
"countryCode": "US",
"statistics": {
"approvedCount": "1510",
"pendingCount": "50",
"disapprovedCount": "15"
},
"issues": [
{
"issueType": "missing_image",
"severity": "ERROR",
"numProducts": "15",
"sampleProducts": [
"accounts/12345/products/online~en~US~SKU001",
"accounts/12345/products/online~en~US~SKU002"
]
}
]
}
]
}
取得特定國家/地區和目的地的產品狀態
您可以使用 filter
查詢參數和 aggregateProductStatuses.list
方法,篩選結果,查看特定國家/地區和目的地的狀態。例如:country = "US" AND reportingContext = "SHOPPING_ADS"
。詳情請參閱篩選語法。
GET https://merchantapi.googleapis.com/accounts/v1/accounts/{ACCOUNT_ID}/aggregateProductStatuses?filter=countryCode%3D"US"%20AND%20reportingContext%3D"SHOPPING_ADS"
以下是成功呼叫的回應範例:
{
"aggregateProductStatuses": [
{
"name": "accounts/12345/aggregateProductStatuses/SHOPPING_ADS~US",
"reportingContext": "SHOPPING_ADS",
"countryCode": "US",
"statistics": {
"approvedCount": "1500",
"pendingCount": "50",
"disapprovedCount": "25"
},
"issues": [
{
"issueType": "missing_image",
"severity": "ERROR",
"numProducts": "15",
"sampleProducts": [
"accounts/12345/products/online~en~US~SKU001",
"accounts/12345/products/online~en~US~SKU002"
]
},
{
"issueType": "invalid_price",
"severity": "CRITICAL",
"numProducts": "10",
"sampleProducts": [
"accounts/12345/products/online~en~US~SKU003"
]
}
]
}
]
}
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-08-08 (世界標準時間)。
[null,null,["上次更新時間:2025-08-08 (世界標準時間)。"],[],[],null,["# View product statistics and issues\n\nYou can use the `aggregateProductStatuses.list` method to get a high-level\noverview of the status of products in your Merchant Center account. This is\nuseful for monitoring the overall health of your product data without needing to\nfetch every individual product. This method provides the total number of\nproducts you have, broken down by status (approved, pending, disapproved), and\nalso lists any issues that are affecting your products.\n\nSpecial considerations\n----------------------\n\nThere are special considerations when using the `aggregateProductStatuses.list`\nmethod.\n\n- **Data availability** : Expect a delay of more than 30 minutes between when a product is inserted or updated and when its status is reflected in the `aggregateProductStatuses` response.\n- **Issue consistency** : The issue titles and descriptions returned by the `aggregateProductStatuses.list` method are intended to be consistent with the issues returned by the Products API. However, they might differ from the issue descriptions shown in the Merchant Center user interface.\n\nGet an overview of all product statuses\n---------------------------------------\n\nThis example shows how to retrieve a list of `AggregateProductStatus` resources.\nEach resource represents the status of products for a specific combination of\ndestination and country. Calling\n[`aggregateProductStatuses.list`](/merchant/api/reference/rest/accounts_v1/accounts.aggregateproductstatuses/list)\nwithout any parameters returns all available statuses for your account. \n\n GET https://merchantapi.googleapis.com/accounts/v1/accounts/\u003cvar translate=\"no\"\u003e{ACCOUNT_ID}\u003c/var\u003e/aggregateProductStatuses\n\nHere's a sample response from a successful call: \n\n {\n \"aggregateProductStatuses\": [\n {\n \"name\": \"accounts/12345/aggregateProductStatuses/SHOPPING_ADS~US\",\n \"reportingContext\": \"SHOPPING_ADS\",\n \"countryCode\": \"US\",\n \"statistics\": {\n \"approvedCount\": \"1500\",\n \"pendingCount\": \"50\",\n \"disapprovedCount\": \"25\"\n },\n \"issues\": [\n {\n \"issueType\": \"missing_image\",\n \"severity\": \"ERROR\",\n \"numProducts\": \"15\",\n \"sampleProducts\": [\n \"accounts/12345/products/online~en~US~SKU001\",\n \"accounts/12345/products/online~en~US~SKU002\"\n ]\n },\n {\n \"issueType\": \"invalid_price\",\n \"severity\": \"CRITICAL\",\n \"numProducts\": \"10\",\n \"sampleProducts\": [\n \"accounts/12345/products/online~en~US~SKU003\"\n ]\n }\n ]\n },\n {\n \"name\": \"accounts/12345/aggregateProductStatuses/FREE_LISTINGS~US\",\n \"reportingContext\": \"FREE_LISTINGS\",\n \"countryCode\": \"US\",\n \"statistics\": {\n \"approvedCount\": \"1510\",\n \"pendingCount\": \"50\",\n \"disapprovedCount\": \"15\"\n },\n \"issues\": [\n {\n \"issueType\": \"missing_image\",\n \"severity\": \"ERROR\",\n \"numProducts\": \"15\",\n \"sampleProducts\": [\n \"accounts/12345/products/online~en~US~SKU001\",\n \"accounts/12345/products/online~en~US~SKU002\"\n ]\n }\n ]\n }\n ]\n }\n\nGet product statuses for a specific country and destination\n-----------------------------------------------------------\n\nYou can filter the results to see the status for a specific country and\ndestination by using the `filter` query parameter with the\n[`aggregateProductStatuses.list`](/merchant/api/reference/rest/accounts_v1/accounts.aggregateproductstatuses/list)\nmethod. For example: `country = \"US\" AND reportingContext = \"SHOPPING_ADS\"`.\nFor more information, see [Filter syntax](/merchant/api/guides/accounts/filter-syntax). \n\n GET https://merchantapi.googleapis.com/accounts/v1/accounts/\u003cvar translate=\"no\"\u003e{ACCOUNT_ID}\u003c/var\u003e/aggregateProductStatuses?filter=countryCode%3D\"US\"%20AND%20reportingContext%3D\"SHOPPING_ADS\"\n\nHere's a sample response from a successful call: \n\n {\n \"aggregateProductStatuses\": [\n {\n \"name\": \"accounts/12345/aggregateProductStatuses/SHOPPING_ADS~US\",\n \"reportingContext\": \"SHOPPING_ADS\",\n \"countryCode\": \"US\",\n \"statistics\": {\n \"approvedCount\": \"1500\",\n \"pendingCount\": \"50\",\n \"disapprovedCount\": \"25\"\n },\n \"issues\": [\n {\n \"issueType\": \"missing_image\",\n \"severity\": \"ERROR\",\n \"numProducts\": \"15\",\n \"sampleProducts\": [\n \"accounts/12345/products/online~en~US~SKU001\",\n \"accounts/12345/products/online~en~US~SKU002\"\n ]\n },\n {\n \"issueType\": \"invalid_price\",\n \"severity\": \"CRITICAL\",\n \"numProducts\": \"10\",\n \"sampleProducts\": [\n \"accounts/12345/products/online~en~US~SKU003\"\n ]\n }\n ]\n }\n ]\n }"]]