Did you know 10% of your products generate 80% of your revenue? Protect your top performers with our free automated monitoring script.
Your best sellers get disapproved without you knowing
Your conversions drop suddenly
You lose sales for hours or days

A Google Ads script that quietly monitors your important products 24/7
Automatically checks approval status and availability of your top products
Receive detailed emails with product title, link and solution when issues are detected
No more manual monitoring - focus on growing your business
Let our experts set up this script for you in 30 minutes
When a best seller gets disapproved or goes out of stock in Merchant Center, your conversions drop... often without you realizing it immediately.

The script can be added from a Google Ads account (MCC or individual): Tools → Bulk actions → Scripts, then paste the code.
At the beginning of the script, modify: EMAIL – alert recipient address, SUBJECT – email subject, merchants – list of Merchant Center accounts and their productIds
ProductId format: online:language:country:ID (ex. online:en:UK:123456)
Enable Shopping Content API via Advanced APIs in the editor

Click 'Authorize' to grant permissions to the script
In settings, choose hourly execution to be alerted quickly
/**
* Best Sellers Monitoring Script for Google Merchant Center
* Author: Hana Kobzová
* Website: https://ppcnewsfeed.com/
* Adapted by: RedCorp Agency
*
* Description:
* This Google Ads script checks selected products across one or more Google Merchant Center accounts.
* It flags products that are either:
* - Not approved for the "Shopping" destination
* - Marked as not in stock
*
* When issues are found, the script sends an email alert.
*
* Instructions:
* - Can be run from an MCC Google Ads account or an individual account
* - Shopping Content API under Advanced APIs must be enabled
* - Recommended frequency: Hourly
*/
var EMAIL = "you@example.com"; // Replace with your email address
var SUBJECT = "[Script Alert] Best sellers not eligible for Shopping";
function main() {
var merchants = [ // This example checks two Merchant Center accounts
{
merchantId: "12345678", // Replace with your Merchant Center ID
productIds: [
"online:en:UK:111111", // Add product IDs you want to monitor
"online:en:UK:222222"
]
},
{
merchantId: "87654321", // Replace with another Merchant Center ID if needed
productIds: [
"online:en:UK:333333"
]
}
];
for (var i = 0; i < merchants.length; i++) {
var merchant = merchants[i];
checkStatus(merchant.merchantId, merchant.productIds);
}
}
function checkStatus(merchantId, productIds) {
var badStatus = [];
for (var i = 0; i < productIds.length; i++) {
var productId = productIds[i];
try {
var status = ShoppingContent.Productstatuses.get(merchantId, productId);
var product = ShoppingContent.Products.get(merchantId, productId);
var availability = product.availability || "Unknown";
var title = status.title || "Unknown title";
var link = status.link || "No link available";
var destinationStatuses = status.destinationStatuses || [];
var itemIssues = status.itemLevelIssues || [];
var disapproved = false;
if (availability.toLowerCase() !== "in stock") {
Logger.log("Product " + productId + " is out of stock.");
badStatus.push({
id: productId,
title: title,
link: link,
reason: "<strong style='color:red'>" + availability + "</strong>"
});
}
for (var j = 0; j < destinationStatuses.length; j++) {
var entry = destinationStatuses[j];
if (entry.destination === 'Shopping') {
if (entry.hasOwnProperty('disapprovedCountries')) {
disapproved = true;
break;
}
}
}
if (disapproved) {
Logger.log("Product " + productId + " is NOT APPROVED in Shopping.");
var reasons = [];
var seen = {};
for (var k = 0; k < itemIssues.length; k++) {
var reason = itemIssues[k].description || "Unknown reason";
var doc = itemIssues[k].documentation || "";
if (!seen[reason]) {
seen[reason] = true;
reasons.push("<strong style='color:red'>" + reason + "</strong>" +
(doc ? " <a href='" + doc + "'>(documentation)</a>" : ""));
}
}
badStatus.push({
id: productId,
title: title,
link: link,
reason: reasons.length > 0 ? reasons.join(", ") : "Unknown reason"
});
}
} catch (e) {
Logger.log("Error retrieving product " + productId + ": " + e.message);
}
}
if (badStatus.length > 0) {
var website = ShoppingContent.Accounts.get(merchantId, merchantId).websiteUrl || "Unknown website";
sendEmail(badStatus, website);
}
}
function sendEmail(products, websiteUrl) {
var output = products.map(function(p) {
return "<p><strong>ID:</strong> " + p.id +
"<br><strong>Title:</strong> " + p.title +
"<br><strong>Link:</strong> <a href='" + p.link + "'>" + p.link + "</a>" +
"<br><strong>Reason(s):</strong> " + p.reason +
"</p>";
}).join("<hr>");
var html = [
"<html>",
"<body>",
"<p>" + SUBJECT + "</p>",
"<p>Merchant website: " + websiteUrl + "</p>",
"<p>-------------</p>",
output,
"</body>",
"</html>"
];
MailApp.sendEmail(EMAIL, SUBJECT + " - " + websiteUrl, "", {
htmlBody: html.join("\n")
});
Logger.log("Email sent.");
}Our RedCorp Agency experts can set up this script for you in 30 minutes and show you how to optimize it for your business.
Questions? Need help?
manager@redcorpagency.com