function main() {
exportReportToSpreadsheet();
}
function exportReportToSpreadsheet() {
var spreadsheet = SpreadsheetApp.create('Shopping Performance');
var report = AdWordsApp.report(
'SELECT CampaignName, AdGroupName, Clicks, Impressions, Cost, AverageCpc, Conversions, ConversionRate, ConversionValue, OfferId, Brand, ProductTypeL1, ProductTypeL2 ' +
'FROM SHOPPING_PERFORMANCE_REPORT ' +
'WHERE Impressions > 0 ' +
'DURING LAST_7_DAYS');
report.exportToSheet(spreadsheet.getActiveSheet());
}