Hello, I've written a function to create a new campaign. By default, all newly created campaigns are set to 'Presence or interest'. I need assistance with creating and uploading a campaign with the 'Presence' setting. I tried the following method, but it didn't work. Thanks for your time!
-----------------
function queueCampaignForCreation(upload, name, city, state) {
var locationSetting = generateLocationSetting(city, state);
var budget = 1; // Default budget for all campaigns
upload.append({
'Campaign': name,
'Budget': budget,
'Bid Strategy type': 'Maximize Conversions',
'Campaign type': 'Search Only',
'Networks': 'Google Search', // Only Google Search, exclude Search Partners and Display Network
'Location': locationSetting,
'Location Options': 'Presence' // Location option setting
});
Logger.log('Campaign queued for creation with location setting: ' + locationSetting + ' and budget: ' + budget);
}
function generateLocationSetting(city, state) {
return '10 | mi | ' + city + ', ' + state;
}
--------------