Re: .Exception in thread main java.lang.NoClassDefFoundError: AddCampaign Caused by: java.lang.ClassNotFoundException: AddCampaign
Hi, Thanks for the quick reply according to your answers,I could run the following ways,still i am getting same error. Exception in thread main java.lang.NoClassDefFoundError: v200909/AddCampaign Caused by: java.lang.ClassNotFoundException: v200909.AddCampaign at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) Could not find the main class: v200909.AddCampaign. Program will exit. java -classpath .:../../lib/adwords-api-8.1.0.jar v200909.AddCampaign (and) java -classpath .:../../lib/adwords-api-8.1.0.jar C:/ykrao/adwords-api-8.1.0/examples/v200909/AddCampaign (and) java -classpath .:../../lib/adwords-api-8.1.0.jar AddCampaign My Class file located in this path C:\ykrao\adwords-api-8.1.0\examples\v200909\AddCampaign.class Please provide me any alternative solution for the above, i have to spend so much time for this. Thanks. Y.Kondalarao. On Fri, Aug 27, 2010 at 12:10 AM, AdWords API Advisor adwordsapiadvi...@google.com wrote: Hi, I think you need to specify the complete class path, not just the class name, when running the example: java -classpath .:../../lib/adwords-api-8.1.0.jar v200909.AddCampaign Best, - Eric Koleda, AdWords API Team On Aug 26, 6:19 am, kondalaraoy kondalar...@gmail.com wrote: I am using javaclient library for sandbox I downloaded adwords-api-8.1.0.tar, for windows 7 operating system and jdk 1.6.0 software for java extract the adwords-api-8.1.0.tar in my desktop C:\ykrao\adwords- api-8.1.0 and i compile the AddCampaign program in C:\ykrao\adwords- api-8.1.0\examples\v200909\AddCampaign.java using the following command like C:\ykrao\adwords-api-8.1.0\examples\v200909javac -classpath ../../lib/ adwords-api-8.1.0.jar AddCampaign.java after compiling the above program i got AddCampaign class file,After i run the AddCampaign.class file i got the above error,when i run the class file i was using the following command like C:\ykrao\adwords-api-8.1.0\examples\v200909java -classpath ../.:../ lib/adwords-api-8.1.0.jar AddCampaign (and) C:\ykrao\adwords-api-8.1.0\examples\v200909java -classpath .:../../ lib/adwords-api-8.1.0.jar AddCampaign at java.net.URLClassLoader $1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) Please provide me solution what is the problem for above error i mentioned. Thanks, Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.comadwords-api%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en
Re: Using Sandbox v2009,How to get geographic data
Hi Eric, Thanks for Your reply,i request to get clicks,impressions,avgcpc,ctr,maxcpc,avgposition using sandbox api v2009.which service i can use,and how can i set the start-date and end-date to get these values. . Please provide me some code examples in php. Thanks and Regards, Y.Kondalarao. On Thu, Jul 15, 2010 at 3:36 AM, AdWords API Advisor adwordsapiadvi...@google.com wrote: Hi, You can use the CampaignTargetService to get the geo targets for the campaign: http://code.google.com/p/google-api-adwords-php/source/browse/trunk/examples/v200909/GetAllCampaignTargets.php Best, - Eric Koleda, AdWords API Team On Jul 13, 1:18 am, kondalarao yarragunta kondalar...@gmail.com wrote: Hi, I have done get the results of campaingn,adgroups and keyword using sandbox api v2009, but along with how to get geographic data using v2009 in PHP. please provide me some code examples in php. Thanks and Regards, Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.comadwords-api%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en
Using Sandbox v2009,How to get geographic data
Hi, I have done get the results of campaingn,adgroups and keyword using sandbox api v2009, but along with how to get geographic data using v2009 in PHP. please provide me some code examples in php. Thanks and Regards, Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en
UndeclaredPrefix: Cannot resolve 'ns1:CampaignOperation' as a QName: the prefix 'ns1' is not declared
Hi, Just installed aw_api_php_lib_2.2.0 for sandbox. My PHP version is 5.2.5 version v200909. SOAP support is there. and linux server. when I try to use examples/v200909/GetAllCampaigns.php , I get this error. SoapFault Object ( [message:protected] = Unmarshalling Error: UndeclaredPrefix: Cannot resolve 'ns1:CampaignSelector' as a QName: the prefix 'ns1' is not declared. [string:private] = [code:protected] = 0 [file:protected] = /usr/local/apache/htdocs/aw_api_php_lib_2.2.0/src/Google/Api/Ads/Common/Lib/AdsSoapClient.php [line:protected] = 179 [trace:private] = Array ( [0] = Array ( [file] = /usr/local/apache/htdocs/aw_api_php_lib_2.2.0/src/Google/Api/Ads/Common/Lib/AdsSoapClient.php [line] = 179 [function] = __soapCall [class] = SoapClient [type] = - [args] = Array ( [0] = get [1] = Array ( [0] = CampaignServiceGet Object ( [selector] = CampaignSelector Object ( [ids] = [campaignStatuses] = [statsSelector] = [paging] = ) ) ) [2] = [3] = Array ( [0] = SoapHeader Object ( [namespace] = https://adwords.google.com/api/adwords/cm/v200909 [name] = RequestHeader [data] = SoapVar Object ( [enc_type] = 301 [enc_value] = SoapRequestHeader Object ( [applicationToken] = ignored [authToken] = DQAAAJMAAADGMOiRhXKf5SrKCsfFN5v2EWYXltCLL42sk_Zwa1sSDeTLJKcHcB6j-1ocn1OB9czl6nOtE6lCbWGLmsGcKgE1xEMsjIkhCqxevp3Uw7tpfAcWVBSUcAe1l91rxa9wzAuVlkg5rs5b11eHcr9bfnEsqxvHwBvbW2gFmPDkwY8u36o7bRxsPKNLNdM08KnYDcAm_wXQ6ZBuoIiWlLtbk-Nz [clientCustomerId] = [clientEmail] = client_1+kondalar...@gmail.comclient_1%2bkondalar...@gmail.com[developerToken] = kondalar...@gmail.com++usd [userAgent] = AwApi-PHP-2.2.0-bluesoft [validateOnly] = ) [enc_stype] = RequestHeader [enc_ns] = https://adwords.google.com/api/adwords/cm/v200909 ) [mustUnderstand] = ) ) [4] = Array ( ) ) ) [1] = Array ( [file] = /usr/local/apache/htdocs/aw_api_php_lib_2.2.0/src/Google/Api/Ads/AdWords/v200909/cm/CampaignService.php [line] = 4303 [function] = __soapCall [class] = AdsSoapClient [type] = - [args] = Array ( [0] = get [1] = Array ( [0] = CampaignServiceGet Object ( [selector] = CampaignSelector Object ( [ids] = [campaignStatuses] = [statsSelector] = [paging] = ) ) ) ) ) [2] = Array ( [file] = /usr/local/apache/htdocs/aw_api_php_lib_2.2.0/examples/v200909/GetAllCampaigns.php [line] = 58 [function] = get [class] = CampaignService [type] = - [args] = Array ( [0] = CampaignSelector Object ( [ids] = [campaignStatuses] = [statsSelector] = [paging] = ) ) ) ) [faultstring] = Unmarshalling Error: UndeclaredPrefix: Cannot resolve 'ns1:CampaignSelector' as a QName: the prefix 'ns1' is not declared. [faultcode] = soap:Server ) Please provide the solution. Thanks in advance. Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en
Re: BadAuthentication v200909 Sandbox
'; set_include_path(get_include_path() . PATH_SEPARATOR . $path); require_once 'Google/Api/Ads/AdWords/Lib/AdWordsUser.php'; $user = new AdWordsUser(); // Log SOAP XML request and response. $user-LogDefaults(); // Get the CampaignService. $campaignService = $user-GetCampaignService('v200909','https:// adwords-sandbox.google.com'); are you actually doing it before calling the getAllCAmpaigns example? On Jun 8, 1:14 pm, kondalarao yarragunta kondalar...@gmail.com wrote: HI, I tried to run the PHP ClientLibrary(aw_api_php_lib_2.2.0) on my localhost. I changed the auth.ini like that: email = myacco...@google.com password = mypassword userAgent = My Sandbox API Tool applicationToken = ignored developerToken = myacco...@google.com++usd ; Uncomment to make requests against a client account. clientId = client_1++myacco...@google.comclient_1%2b%2bmyacco...@google.com client_1%2b%2bmyacco...@google.comclient_1%252b%252bmyacco...@google.com client_1%2b%2bmyacco...@google.comclient_1%252b%252bmyacco...@google.com client_1%252b%252bmyacco...@google.comclient_1%25252b%25252bmyacco...@google.com I set the DEFAULT_SERVER = https://adwords-sandbox.google.com; in the file settings.ini Now when I try to run aw_api_php_lib_2.2.0/examples/v200909/GetAllCampaigns.php i got the following error: AuthTokenException Object ( [error:AuthTokenException:private] = BadAuthentication [url:AuthTokenException:private] = [captchaToken:AuthTokenException:private] = [captchaUrl:AuthTokenException:private] = [message:protected] = Failed to get authToken. Reason: BadAuthentication [string:Exception:private] = [code:protected] = 0 [file:protected] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\Common\Util\AuthTok en.php [line:protected] = 88 [trace:Exception:private] = Array ( [0] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\AdWords\Lib\AdWords User.php [line] = 503 [function] = GetAuthToken [class] = AuthToken [type] = - [args] = Array ( ) ) [1] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\AdWords\Lib\AdWords User.php [line] = 141 [function] = RegenerateAuthToken [class] = AdWordsUser [type] = - [args] = Array ( ) ) [2] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\examples\v200909\GetAllCampaigns.php [line] = 46 [function] = __construct [class] = AdWordsUser [type] = - [args] = Array ( ) ) ) [previous:Exception:private] = ) The account-information are correct. I tried it many times. And I can use the Sandbox Account View without any auth-error. Thank you for any help please, Thanks and Regards, Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.comadwords-api%2bunsubscr...@googlegroups.com adwords-api%2bunsubscr...@googlegr oups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.comadwords-api%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group
BadAuthentication v200909 Sandbox
HI, I tried to run the PHP ClientLibrary(aw_api_php_lib_2.2.0) on my localhost. I changed the auth.ini like that: email = myacco...@google.com password = mypassword userAgent = My Sandbox API Tool applicationToken = ignored developerToken = myacco...@google.com++usd ; Uncomment to make requests against a client account. clientId = client_1++myacco...@google.comclient_1%2b%2bmyacco...@google.com I set the DEFAULT_SERVER = https://adwords-sandbox.google.com; in the file settings.ini Now when I try to run aw_api_php_lib_2.2.0/examples/v200909/GetAllCampaigns.php i got the following error: AuthTokenException Object ( [error:AuthTokenException:private] = BadAuthentication [url:AuthTokenException:private] = [captchaToken:AuthTokenException:private] = [captchaUrl:AuthTokenException:private] = [message:protected] = Failed to get authToken. Reason: BadAuthentication [string:Exception:private] = [code:protected] = 0 [file:protected] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\Common\Util\AuthToken.php [line:protected] = 88 [trace:Exception:private] = Array ( [0] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\AdWords\Lib\AdWordsUser.php [line] = 503 [function] = GetAuthToken [class] = AuthToken [type] = - [args] = Array ( ) ) [1] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\src\Google\Api\Ads\AdWords\Lib\AdWordsUser.php [line] = 141 [function] = RegenerateAuthToken [class] = AdWordsUser [type] = - [args] = Array ( ) ) [2] = Array ( [file] = C:\xampp\htdocs\aw_api_php_lib_2.2.0\examples\v200909\GetAllCampaigns.php [line] = 46 [function] = __construct [class] = AdWordsUser [type] = - [args] = Array ( ) ) ) [previous:Exception:private] = ) The account-information are correct. I tried it many times. And I can use the Sandbox Account View without any auth-error. Thank you for any help please, Thanks and Regards, Y.Kondalarao. -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups AdWords API Forum group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en