Google Adwords API adding campaign
May be my question will look dumb but i'm new in using AdWords API hence i got some problems. I'm using 开发者_如何学PythonRuby to add campaigns. So i created my MCC account, there I have a client.I'm using SANDBOX. so i create new API object like this:
creds = {
'developerToken' => 'user@domain.com++USD',
'useragent' => 'Sample User Agent',
'password' => 'password',
'email' => 'user@domain.com',
'clientEmail' => 'client_1+user@domain.com',
'applicationToken' => 'IGNORED',
'environment' => 'SANDBOX',
}
@adwords = AdWords::API.new(AdWords::AdWordsCredentials.new(creds))
then i add some campaigns and finally i get an answer that campaign is added BUT i don't understand where i can see it. I have my my MCC account but i don't understand where these campaigns will appear if i use sandbox not production. Can anybody explain me how to test on SANDBOX? Thanx in advance.
Google doesn't provide a front end for the Sandbox to check that code is working. I usually end up just uploading test campaigns to my own production account.
However, if you don't want to do that then there's a Java application that can be pointed at the sandbox to see what's in an account. It can be found here: http://code.google.com/p/google-api-adwords-java/wiki/SandboxAccountViewer
You can view campaigns in Campaign Performance Report (retrievable in XML).
You have to write script which fetches campaigns from sandbox. Whether you are using adwords4r
or the new google-adwords-api
gem, both of them provide example scripts for various tasks. Here is how to fetch campaigns in google-adwords-api, which is probably what's you're looking for.
精彩评论