Re: AddAdGroups.php gives error

2012-06-12 Thread Roy Roes
Hi Kevin,
 
I enabled logging and used the LogAll function, but nothing is logged.
Even the SOAP request isn't logged.
 
I've also tested the log with the AddCampaign.php and that's working fine.
So the log is configured properly.

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Adwords API pending approval, Can I use my developer Token?

2012-06-12 Thread Paul Harvey


> Anash,
>

We also started our application several months back.  Could you please add 
us to the list?

Customer ID: 374-841-8440

Paul Harvey

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: cannot add Enabled, Deleted, Paused predicates to keyword report - [SelectorError.INVALID_PREDICATE_ENUM_VALUE @ selector; trigger:'Enabled'; errorDetails:Enabled, SelectorError.INVALID_PREDICATE_

2012-06-12 Thread Kevin Winter
Hi,
  You need to use the Predicate Values - which are upper-cased.  The Report 
Types documentation page lists the values: 
https://developers.google.com/adwords/api/docs/appendix/reports#keywords


  Status
  IN
  ACTIVE
  DELETED
  PAUSED


- Kevin Winter
AdWords API Team

On Friday, June 8, 2012 10:37:10 PM UTC-4, iateadonut wrote:
>
> My keyword and campaign report totals are not matching up.  It seems to be 
> a problem with keywords that are paused not showing up in the keyword 
> report.
>
> Here is the log and the error I'm getting:
>
> short version:
>
> 
>   Status
>   IN
>   Enabled
>   Deleted
>   Paused
> 
> Response Code: 400
> Error Message: [SelectorError.INVALID_PREDICATE_ENUM_VALUE @ selector; 
> trigger:'Enabled'; errorDetails:Enabled, 
> SelectorError.INVALID_PREDICATE_ENUM_VALUE @ selector; trigger:'Deleted'; 
> errorDetails:Deleted, SelectorError.INVALID_PREDICATE_ENUM_VALUE @ 
> selector; trigger:'Paused'; errorDetails:Paused]
>
>
> full version:
>
> [Jun 08 2012 13:50:10.00 - ERROR] POST 
> /api/adwords/reportdownload/v201109 HTTP/1.1 
> User-Agent: curl, gzip 
> Host: adwords.google.com 
> Accept: */* 
> Accept-Encoding: gzip 
> Authorization: GoogleLogin auth=+++
> developerToken: +++
> clientCustomerId: +++
> returnMoneyInMicros: false 
> Content-Length: 1308 
> Expect: 100-continue 
> Content-Type: multipart/form-data; 
> boundary=4dd383e4f197
>
> Parameters:
> __rdxml: 
> 
>   
> Date
> ExternalCustomerId
> Id
> CampaignId
> AdGroupId
> Status
> KeywordText
> AdNetworkType2
> Impressions
> Clicks
> ConversionRate
> Conversions
> Cost
> CostPerConversion
> AverageCpc
> AverageCpm
> AveragePosition
> 
>   Status
>   IN
>   Enabled
>   Deleted
>   Paused
> 
> 
>   20120501
>   20120531
> 
>   
>   KEYWORDS performance report #1339177808
>   KEYWORDS_PERFORMANCE_REPORT
>   CUSTOM_DATE
>   CSV
>   false
> 
>
> Response Code: 400
> Error Message: [SelectorError.INVALID_PREDICATE_ENUM_VALUE @ selector; 
> trigger:'Enabled'; errorDetails:Enabled, 
> SelectorError.INVALID_PREDICATE_ENUM_VALUE @ selector; trigger:'Deleted'; 
> errorDetails:Deleted, SelectorError.INVALID_PREDICATE_ENUM_VALUE @ 
> selector; trigger:'Paused'; errorDetails:Paused]
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Get a fault string this way? (google-api-adwords-perl)

2012-06-12 Thread Kevin Winter
Hi Grant,
  Yes, this is the right approach.  See this example:  
http://code.google.com/p/google-api-adwords-perl/source/browse/trunk/examples/v201109_1/error_handling/handle_server_faults.pl#80

- Kevin Winter
AdWords API Team

On Friday, June 8, 2012 11:52:12 AM UTC-4, Grant wrote:
>
> Is this a good way to get a fault string in google-api-adwords-perl?
>
> if ( $response->isa("SOAP::WSDL::SOAP::Typelib::Fault11") ) {
>my $error_response = $response->get_faultstring();
> }
>
> - Grant
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Reports taking forever to load

2012-06-12 Thread Kevin Winter
Hi Reed,
  Are you still seeing this problem?  Can you provide an example 
ReportDefintion XML and CID so that I can try to reproduce?

- Kevin Winter
AdWords API Team

On Thursday, June 7, 2012 9:32:10 AM UTC-4, Reed wrote:
>
> Anyone else seeing problem with reports taking forever to load today?  We 
> upgraded to the 201109_01 library yesterday, and now every report we pull 
> (keyword perf, criteria perf, campaign perf, etc etc) is taking 25+ minutes 
> to load - even the small ones that usually take only a second.  We rolled 
> back to the 201109 library, still  see the same problem.  Not sure what 
> debugging info to include since this is the adhoc reporting.
> thanks
> -reed
>  
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: AddAdGroups.php gives error

2012-06-12 Thread Kevin Winter
Hi,
  It sounds like you may be seeing a SOAP fault and that prevents your PHP 
code from writing a response.  Could you please enable logging (check the 
README) and see if there's an error message?

- Kevin Winter
AdWords API Team

On Friday, June 8, 2012 9:03:52 AM UTC-4, Roy Roes wrote:
>
> I'm testing the Adwords API in the sandbox.
>  
> When I try to add AdGroups to a campaign with the AddAdGroups.php from the 
> PHP client library, I get the following error in Chrome: Error 324 
> (net::ERR_EMPTY_RESPONSE)
>
>  
>
> With a bit of debugging the line causing the error: $result = 
> $adGroupService->mutate($operations);
>
>  
>
> The content of $operations:
>
>  
> Array ( [0] => AdGroupOperation Object ( [operand] => AdGroup Object ( 
> [id] => [campaignId] => 123456 [campaignName] => [name] => Earth to Mars 
> Cruise #4fd1e737a9007 [status] => ENABLED [bids] => ManualCPCAdGroupBids 
> Object ( [keywordMaxCpc] => Bid Object ( [amount] => Money Object ( 
> [microAmount] => 100 [ComparableValueType] => [_parameterMap:private] 
> => Array ( [ComparableValue.Type] => ComparableValueType ) ) ) 
> [keywordContentMaxCpc] => Bid Object ( [amount] => Money Object ( 
> [microAmount] => 75 [ComparableValueType] => [_parameterMap:private] => 
> Array ( [ComparableValue.Type] => ComparableValueType ) ) ) [siteMaxCpc] => 
> [enhancedCpcEnabled] => [interactionBids] => [AdGroupBidsType] => 
> [_parameterMap:private] => Array ( [AdGroupBids.Type] => AdGroupBidsType ) 
> ) [experimentData] => [stats] => ) [operator] => ADD [OperationType] => 
> [_parameterMap:private] => Array ( [Operation.Type] => OperationType ) ) 
> [1] => AdGroupOperation Object ( [operand] => AdGroup Object ( [id] => 
> [campaignId] => 123456 [campaignName] => [name] => Earth to Mars Cruise 
> #4fd1e737a9035 [status] => ENABLED [bids] => ManualCPCAdGroupBids Object ( 
> [keywordMaxCpc] => Bid Object ( [amount] => Money Object ( [microAmount] => 
> 100 [ComparableValueType] => [_parameterMap:private] => Array ( 
> [ComparableValue.Type] => ComparableValueType ) ) ) [keywordContentMaxCpc] 
> => Bid Object ( [amount] => Money Object ( [microAmount] => 75 
> [ComparableValueType] => [_parameterMap:private] => Array ( 
> [ComparableValue.Type] => ComparableValueType ) ) ) [siteMaxCpc] => 
> [enhancedCpcEnabled] => [interactionBids] => [AdGroupBidsType] => 
> [_parameterMap:private] => Array ( [AdGroupBids.Type] => AdGroupBidsType ) 
> ) [experimentData] => [stats] => ) [operator] => ADD [OperationType] => 
> [_parameterMap:private] => Array ( [Operation.Type] => OperationType ) ) )
>  
> Can anyone tell me what I'm doing wrong?
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Does $client->set_die_on_faults(1); still work?

2012-06-12 Thread Kevin Winter
Hi Grant,
  Yes, this should still work.  Please file an issue on the Perl projects 
issue tracker if it isn't: 
http://code.google.com/p/google-api-adwords-perl/issues/list

- Kevin Winter
AdWords API Team

On Friday, June 8, 2012 3:46:10 AM UTC-4, Grant wrote:
>
> Does $client->set_die_on_faults(1); still work in google-api-adwords-perl? 
>  It worked in v200909 but I'm not sure about v201109_1.
>
> - Grant
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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


Get Click date and time

2012-06-12 Thread Tom Kessler
Hello,

Is it possible to get Click detailed information such as date and time of a 
click? I read over the AdWords API and it seems there is no Click entity 
with date and time properties available.

Thank you,

Tom

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: How to receive the logged in user info

2012-06-12 Thread PatrickvKleef
 Forgot to mention, I'm using OAuth 2.0.


Op dinsdag 12 juni 2012 21:18:24 UTC+2 schreef PatrickvKleef het volgende:
>
> Hi!
>
> I'm new with using the Google Adwords API. I'm using OAuth to authenticate 
> users.
> I would like to receive user information (emailaddress, name, etc.) when 
> the user is authenticated with OAuth.
>
> Can somebody help me with this?
>
>
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Any server configuration required to run OAuth 1.0a - getting OAUTH_TOKEN_HEADER_INVALID error on server where as running successfully on local setup and one server.

2012-06-12 Thread Eric Koleda
Hi Chirag,

I would encourage you to set the timezone on that server in the php.ini
file, to ensure the timestamps are accurate. Can you try replacing the
CampaignService.get() call in the UseOAuth.php example with a report
download request, and then run that on both servers?

Best,
- Eric

On Tue, Jun 12, 2012 at 3:51 AM, Chirag  wrote:

> Hello Eric,
> Sorry for late reply.
>
> Finally i got access from server to run command line example
> "UseOAuth.php".
> Yes on both server it works fine, but on server where adhoc report is not
> working there i got php warning for date.
>
> PHP Warning:  date(): It is not safe to rely on the system's timezone
> settings. You are *required* to use the date.timezone setting or the
> date_default_timezone_set() function. In case you used any of those methods
> and you are still getting this warning, you most likely misspelled the
> timezone identifier. We selected 'Asia/Calcutta' for 'IST/5.0/no DST'
> instead in /var/www/html/src/Google/Api/Ads/Common/Util/Logger.php on line
> 234
>
> Thanks,
> chirag
>
>
> On Monday, June 4, 2012 11:27:57 PM UTC+5:30, Eric Koleda wrote:
>>
>> Hi Chirag,
>>
>> Certainly a tricky problem. As a baseline, can you try running the
>> command line example "UseOAuth.php" on both servers, to see if that works?
>>
>> - Eric
>>
>>  On Mon, Jun 4, 2012 at 12:28 PM, Chirag wrote:
>>
>>> Hi Eric,
>>>
>>> Are these new OAuth tokens or are you using the same token on both
>>> servers?
>>> I am using same Oauth tokens for both servers.
>>>
>>> Can you double check that you are using the same consumer key and secret
>>> on both servers?
>>> Yes, I am using same consumer key and secret.
>>>
>>> Thanks,
>>> chirag
>>>
>>> On Monday, June 4, 2012 7:11:25 PM UTC+5:30, Eric Koleda wrote:

 Hi Chirag,

 I didn't see any problems or noticeable differences with the broken
 request. Are these new OAuth tokens or are you using the same token on both
 servers? Can you double check that you are using the same consumer key and
 secret on both servers?

 - Eric

 On Mon, Jun 4, 2012 at 7:23 AM, Chirag wrote:

> Hi Eric,
>
> Sorry for late reply.
> Please find both server's response.
>
> Thanks,
> chirag
>
>
> On Friday, June 1, 2012 11:56:15 PM UTC+5:30, Eric Koleda wrote:
>>
>> My apologies again, I was parsing it as milliseconds and not seconds.
>> That does appear to be correct.
>>
>> Regarding my other point, it would be helpful to compare the
>> Authorization header from the server that is working with the one from 
>> the
>> server that is not working. Can you post the sanitized version of both?
>>
>> - Eric
>>
>> On Fri, Jun 1, 2012 at 1:33 PM, Chirag wrote:
>>
>>> Hello Eric,
>>>
>>> I think timestamp is correct.
>>>
>>> oauth_timestamp="1338338512" is refers to the Wed, 30 May 2012
>>> 00:41:52 GMT
>>>
>>> What are the timestamps like for working requests?
>>> I am not getting this. I am working with timezone 'Asia/Calcutta'.
>>>
>>> Thanks,
>>> Chirag
>>>
>>>
>>> On Friday, June 1, 2012 10:19:58 PM UTC+5:30, Eric Koleda wrote:

 Hi Chirag,

 My apologies, I forgot this was for report downloads, so you should
 only get a log with the report request. For report requests the OAuth
 parameters are passed in the Authorization header.  The value of the
 timestamp used seems to be wrong:

 oauth_timestamp="1338338512"

 This corresponds to Fri Jan 16 1970 06:45:38 GMT-0500 (EST), which
 is not correct.  What are the timestamps like for working requests?

 Best,
 - Eric

 On Fri, Jun 1, 2012 at 12:32 PM, Chirag 
 wrote:

> Hello Eric,
>
> Thanks for reply.
> Yes i will look into date and time suggestion you mentioned.
> But,for logging, I have $user->LogAll(); is set.
> but i am not getting any log. I just got logs for reporting and it
> is attached.
>
> Thanks,
> chirag
>
>
>
> On Friday, June 1, 2012 9:37:09 PM UTC+5:30, Eric Koleda wrote:
>>
>> Hi Chirag,
>>
>> It's strange that the error is only appearing on specific server
>> environments. The next step in debugging this issue would be to take 
>> a look
>> at the URL the SOAP request is being made to, since the PHP client 
>> library
>> appends the OAuth parameters to the URL.  If you enable SOAP XML 
>> logging
>> the URL is recorded in the logs.  Perhaps a visual inspection of the 
>> URL
>> will show a difference between the environments.
>>
>> One possible cause to investigate is whether the date and time is
>> configured co

Re: v201109_1 CALL_METRICS_CALL_DETAILS_REPORT error

2012-06-12 Thread Sean


Dim ReportFields as string = 
"AdGroupId,AdGroupName,CallDuration,CallEndTime,CallerNationalDesignatedCode,CallStartTime,CallStatus,CampaignId,CampaignName"

 Dim headers As New Dictionary(Of String, String)()
   
 headers.Add("email", Email)
headers.Add("password", Password)
headers.Add("useragent", engineAccountName)
headers.Add("developerToken", devToken)
headers.Add("applicationToken", authToken)
headers.Add("ClientCustomerId", acct_id)

Dim user As New AdWordsUser(headers)

Dim fields() As String = ReportFields.Split(",")
Dim s As Integer = 0

Dim selector As New Selector()

Dim rd As ReportDefinition = New ReportDefinition()
rd.reportName = ReportName & " " & Date.Today() 
rd.dateRangeType = ReportDefinitionDateRangeType.YESTERDAY
   
selector.fields = fields


rd.reportType = 
ReportDefinitionReportType.CALL_METRICS_CALL_DETAILS_REPORT
rd.downloadFormat = DownloadFormat.CSV
rd.selector = selector


Dim ed As Date = DateAdd(DateInterval.Day, -1, Date.Today())
Dim reportMo As String = ed.Month
Dim ReportDy As String = ed.Day
If Len(reportMo) = 1 Then
reportMo = "0" & reportMo
End If
If Len(ReportDy) = 1 Then
ReportDy = "0" & ReportDy
End If
Dim endDate As String = Year(ed) & "-" & reportMo & "-" & ReportDy

Dim reportId As String = ""

' Add report definition.
Dim process_time As DateTime = DateTime.Now()
Dim conv1 As String = "N"

rd.includeZeroImpressions = False

fileName = engine & "-"c & 15 & "-"c & site_id & "-"c & 
Replace(acct_id, "-"c, "_") & "-"c & "1" & "-"c & endDate.ToString 
& conv1 & ".csv"

 

Try
Dim utilities As New ReportUtilities(user)
utilities.DownloadClientReport(Of ReportDefinition)(rd, 
ReportDir & fileName)

  
Catch ex As Google.Api.Ads.AdWords.Lib.AdWordsApiException
If Not ex.Message.ToString.Contains("Email cannot be null") Then
AddAPIError(site_id, Processor_id, ex.Message.ToString, 
acct_id)
End If
Catch ex As Google.Api.Ads.AdWords.Lib.AdWordsException
If Not ex.Message.ToString.Contains("Email cannot be null") Then
'AddAPIError(site_id, Processor_id, ex.Message.ToString + 
"-" + ex.InnerException.Message.ToString, acct_id)
End If
Catch ex As Exception
If Not ex.Message.ToString.Contains("Email cannot be null") Then
AddAPIError(site_id, Processor_id, ex.Message.ToString, 
acct_id)
'MailError(site_id, queryid & "-" & ex.Message.ToString, 
ex.InnerException.ToString, "Error: " & ex.Message, Date.Now())
End If
End Try

On Wednesday, June 6, 2012 11:39:51 AM UTC-4, Sean wrote:

> Hi, I'm using the .NET libraries. v14.5 dll. I get this error when trying 
> to call the new report. The code works on all other report types.
> The fields included are:
>
> AdGroupId,AdGroupName,CallDuration,CallEndTime,CallerNationalDesignatedCode,CallStartTime,CallStatus,CampaignId,CampaignName
>  
> !!!2|||-1|||cvc-complex-type.2.4.a: Invalid content was found starting 
> with element 'selector'. One of '{"
> https://adwords.google.com/api/adwords/cm/v201109":id, "
> https://adwords.google.com/api/adwords/cm/v201109":selector}' is 
> expected.???
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 the Adwords Ruby Library -> AdwordsApi::Errors::ReportError: AdwordsApi::Errors::ReportError

2012-06-12 Thread bulletshot60
For anyone else that is suffering from this problem, try the following =>

begin
   ... work through gem ...
rescue Exception => e
puts "#{e.message}"
end

I discovered my problem was that I had an invalid column name and that 
customer_client_id is required.

On Tuesday, June 12, 2012 12:59:53 PM UTC-4, bulletshot60 wrote:
>
> just an edit to the original.  I changed library version hoping that would 
> fix the issue.  My requirements also specify that I use a custom date range 
> so that has been added.  Still no luck on figuring out what is going on 
> with the 500 error in production.
>
> http://pastie.org/4074706
>
> On Tuesday, June 12, 2012 10:37:06 AM UTC-4, bulletshot60 wrote:
>>
>> I am attempting to download a keywords performance report using the Ruby 
>> library for adwords and all I get is this generic error.  Not sure what I 
>> am doing wrong, so would anyone be able to offer any insight?
>>
>> Code => http://pastie.org/4073904
>>
>> Notes: The connection(nil) method is the same as doing Adwords::API.new 
>> without a client_customer_id.
>>
>> Thanks for any insight that is provided.  This is really starting to 
>> stump me.
>>
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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


Ruby API: problems with template for YouTube Promoted Videos

2012-06-12 Thread Dave Seidel
Hi, using google-ads-common 0.7.2, google-adwords-api 0.6.1, API version 
 v201109_1.

I'm reworking some old code written by someone else that worked with an 
earlier version of the gems and the API, and I'm having trouble using the 
YouTube Promoted Videos temple. Here's what my operation hash looks like: 
http://pastebin.com/t67FSut2. When I pass this to AdGroupService.mutate I 
get

Parameter error: AdsCommon::Errors::UnexpectedParametersError: [:image_url, 
> :headline, :description1, :description2, :video_id, :channel_name]


 The names seem to be correct as per 
https://developers.google.com/adwords/api/docs/appendix/templateads#pyv_ad.

Can anyone tell what I'm doing wrong? 

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 the Adwords Ruby Library -> AdwordsApi::Errors::ReportError: AdwordsApi::Errors::ReportError

2012-06-12 Thread bulletshot60
just an edit to the original.  I changed library version hoping that would 
fix the issue.  My requirements also specify that I use a custom date range 
so that has been added.  Still no luck on figuring out what is going on 
with the 500 error in production.

http://pastie.org/4074706

On Tuesday, June 12, 2012 10:37:06 AM UTC-4, bulletshot60 wrote:
>
> I am attempting to download a keywords performance report using the Ruby 
> library for adwords and all I get is this generic error.  Not sure what I 
> am doing wrong, so would anyone be able to offer any insight?
>
> Code => http://pastie.org/4073904
>
> Notes: The connection(nil) method is the same as doing Adwords::API.new 
> without a client_customer_id.
>
> Thanks for any insight that is provided.  This is really starting to stump 
> me.
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 the Adwords Ruby Library -> AdwordsApi::Errors::ReportError: AdwordsApi::Errors::ReportError

2012-06-12 Thread bulletshot60
Just an edit to the original.  Error still occurring.

The report needs to pull via a date range.

New Code => http://pastie.org/4074666

On Tuesday, June 12, 2012 10:37:06 AM UTC-4, bulletshot60 wrote:
>
> I am attempting to download a keywords performance report using the Ruby 
> library for adwords and all I get is this generic error.  Not sure what I 
> am doing wrong, so would anyone be able to offer any insight?
>
> Code => http://pastie.org/4073904
>
> Notes: The connection(nil) method is the same as doing Adwords::API.new 
> without a client_customer_id.
>
> Thanks for any insight that is provided.  This is really starting to stump 
> me.
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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


What is the correct way to link Merchant Center to Adwords account via API?

2012-06-12 Thread API2Go
Actually I have a two part question - what is the best way to link the 
Merchant Center to the appropriate adwords account via the API and how 
should we enable the adwords campaign to access the merchant center via the 
API?

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 the Adwords Ruby Library -> AdwordsApi::Errors::ReportError: AdwordsApi::Errors::ReportError

2012-06-12 Thread bulletshot60
I am attempting to download a keywords performance report using the Ruby 
library for adwords and all I get is this generic error.  Not sure what I 
am doing wrong, so would anyone be able to offer any insight?

Code => http://pastie.org/4073904

Notes: The connection(nil) method is the same as doing Adwords::API.new 
without a client_customer_id.

Thanks for any insight that is provided.  This is really starting to stump 
me.

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: How can i Get Account Balance ?

2012-06-12 Thread Freddie Leeman
I've created a curl/php script to retreive you Adwords balance using 
php/curl. I hope this is usefull for you.



> // 
> --
> // FUNCTION TO RETREIVE ADWORDS PREPAID BALANCE USING CURL by Freddie 
> Leeman
> // 
> --
>
> $USERNAME = "";
> $PASSWORD = "";
> $COOKIE = "/tmp/adwords.cookie";
>
> // 
> -
> // DO NOT CHANGE ANYTHING BELOW THIS LINE
> // 
> -
>
> $cookiehandle = fopen($COOKIE, 'w');
> fclose($cookiehandle);
>
> $ch = curl_init();
> curl_setopt($ch, CURLOPT_URL, 'https://adwords.google.com');
> curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
> curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
> curl_setopt($ch, CURLOPT_COOKIEFILE, $COOKIE);
> $loginpage = curl_exec ($ch);
>
> $startpos = strpos($loginpage,"name=\"GALX\"")+11;
> $startpos = strpos($loginpage, "\"", $startpos)+1;
> $stoppos = strpos($loginpage, "\"", $startpos);
> $GALXvalue = substr($loginpage,$startpos,$stoppos-$startpos);
>
> $postData = "continue=https://adwords.google.com/um/gaiaauth";;
> $postData .= "&Email=" . $USERNAME;
> $postData .= "&Passwd=" . $PASSWORD;
> $postData .= "&GALX=" . $GALXvalue;
>
> curl_setopt($ch, CURLOPT_URL, 
> 'https://accounts.google.com/ServiceLoginAuth');
> curl_setopt ($ch, CURLOPT_POST, 1);
> curl_setopt ($ch, CURLOPT_POSTFIELDS, $postData);
> curl_exec ($ch);
> curl_setopt($ch, CURLOPT_URL, 
> 'https://adwords.google.com/select/MakePayments?hl=en');
> $content = curl_exec ($ch);
> curl_close ($ch);
> unlink($COOKIE);
>
> $startpos = strpos($content,"€ ")+12;
> $stoppos = strpos($content, "", $startpos);
> $balance = substr($content,$startpos,$stoppos-$startpos);
>
> $balance = 
> floatval(str_replace(",",".",str_replace(".","",$balance)));
>
> echo $balance;
>
> ?>
>

Op vrijdag 14 januari 2011 06:26:34 UTC+1 schreef Joe Chan het volgende:
>
> I read the reference abt account service but it seems there is no way to 
> get the balance of the adword account
>
> Are there any way to get Account Balance via adword API?
>
> Regards,
>
> JOE
>
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Show customer balance

2012-06-12 Thread Freddie Leeman
I've created a php/curl script to retreive the prepaid balance of and 
Google Adwords account. It's a shame this isn't available in the API.


> // 
> --
> // FUNCTION TO RETREIVE ADWORDS PREPAID BALANCE USING CURL by Freddie 
> Leeman
> // 
> --
>
> $USERNAME = "";
> $PASSWORD = "";
> $COOKIE = "/tmp/adwords.cookie";
>
> // 
> -
> // DO NOT CHANGE ANYTHING BELOW THIS LINE
> // 
> -
>
> $cookiehandle = fopen($COOKIE, 'w');
> fclose($cookiehandle);
>
> $ch = curl_init();
> curl_setopt($ch, CURLOPT_URL, 'https://adwords.google.com');
> curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
> curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
> curl_setopt($ch, CURLOPT_COOKIEFILE, $COOKIE);
> $loginpage = curl_exec ($ch);
>
> $startpos = strpos($loginpage,"name=\"GALX\"")+11;
> $startpos = strpos($loginpage, "\"", $startpos)+1;
> $stoppos = strpos($loginpage, "\"", $startpos);
> $GALXvalue = substr($loginpage,$startpos,$stoppos-$startpos);
>
> $postData = "continue=https://adwords.google.com/um/gaiaauth";;
> $postData .= "&Email=" . $USERNAME;
> $postData .= "&Passwd=" . $PASSWORD;
> $postData .= "&GALX=" . $GALXvalue;
>
> curl_setopt($ch, CURLOPT_URL, 
> 'https://accounts.google.com/ServiceLoginAuth');
> curl_setopt ($ch, CURLOPT_POST, 1);
> curl_setopt ($ch, CURLOPT_POSTFIELDS, $postData);
> curl_exec ($ch);
> curl_setopt($ch, CURLOPT_URL, 
> 'https://adwords.google.com/select/MakePayments?hl=en');
> $content = curl_exec ($ch);
> curl_close ($ch);
> unlink($COOKIE);
>
> $startpos = strpos($content,"€ ")+12;
> $stoppos = strpos($content, "", $startpos);
> $balance = substr($content,$startpos,$stoppos-$startpos);
>
> $balance = 
> floatval(str_replace(",",".",str_replace(".","",$balance)));
>
> echo $balance;
>
> ?>
>

Op donderdag 19 mei 2011 15:10:10 UTC+2 schreef Marcelo Diegues het 
volgende:
>
> How can I show the customer balance using google adwords api? 
>
>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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: Any server configuration required to run OAuth 1.0a - getting OAUTH_TOKEN_HEADER_INVALID error on server where as running successfully on local setup and one server.

2012-06-12 Thread Chirag
Hello Eric,
Sorry for late reply.

Finally i got access from server to run command line example "UseOAuth.php".
Yes on both server it works fine, but on server where adhoc report is not 
working there i got php warning for date.

PHP Warning:  date(): It is not safe to rely on the system's timezone 
settings. You are *required* to use the date.timezone setting or the 
date_default_timezone_set() function. In case you used any of those methods 
and you are still getting this warning, you most likely misspelled the 
timezone identifier. We selected 'Asia/Calcutta' for 'IST/5.0/no DST' 
instead in /var/www/html/src/Google/Api/Ads/Common/Util/Logger.php on line 
234

Thanks,
chirag

On Monday, June 4, 2012 11:27:57 PM UTC+5:30, Eric Koleda wrote:
>
> Hi Chirag,
>
> Certainly a tricky problem. As a baseline, can you try running the command 
> line example "UseOAuth.php" on both servers, to see if that works?
>
> - Eric
>
> On Mon, Jun 4, 2012 at 12:28 PM, Chirag  wrote:
>
>> Hi Eric,
>>
>> Are these new OAuth tokens or are you using the same token on both 
>> servers?
>> I am using same Oauth tokens for both servers.
>>
>> Can you double check that you are using the same consumer key and secret 
>> on both servers?
>> Yes, I am using same consumer key and secret.
>>
>> Thanks,
>> chirag
>>
>> On Monday, June 4, 2012 7:11:25 PM UTC+5:30, Eric Koleda wrote:
>>>
>>> Hi Chirag,
>>>
>>> I didn't see any problems or noticeable differences with the broken 
>>> request. Are these new OAuth tokens or are you using the same token on both 
>>> servers? Can you double check that you are using the same consumer key and 
>>> secret on both servers?
>>>
>>> - Eric
>>>
>>> On Mon, Jun 4, 2012 at 7:23 AM, Chirag  wrote:
>>>
 Hi Eric,

 Sorry for late reply.
 Please find both server's response.

 Thanks,
 chirag


 On Friday, June 1, 2012 11:56:15 PM UTC+5:30, Eric Koleda wrote:
>
> My apologies again, I was parsing it as milliseconds and not seconds. 
> That does appear to be correct.
>
> Regarding my other point, it would be helpful to compare the 
> Authorization header from the server that is working with the one from 
> the 
> server that is not working. Can you post the sanitized version of both?
>
> - Eric
>
> On Fri, Jun 1, 2012 at 1:33 PM, Chirag wrote:
>
>> Hello Eric,
>>
>> I think timestamp is correct.
>>
>> oauth_timestamp="1338338512" is refers to the Wed, 30 May 2012 
>> 00:41:52 GMT
>>
>> What are the timestamps like for working requests?
>> I am not getting this. I am working with timezone 'Asia/Calcutta'.
>>
>> Thanks,
>> Chirag
>>
>>
>> On Friday, June 1, 2012 10:19:58 PM UTC+5:30, Eric Koleda wrote:
>>>
>>> Hi Chirag,
>>>
>>> My apologies, I forgot this was for report downloads, so you should 
>>> only get a log with the report request. For report requests the OAuth 
>>> parameters are passed in the Authorization header.  The value of the 
>>> timestamp used seems to be wrong:
>>>
>>> oauth_timestamp="1338338512"
>>>
>>> This corresponds to Fri Jan 16 1970 06:45:38 GMT-0500 (EST), which 
>>> is not correct.  What are the timestamps like for working requests?
>>>
>>> Best,
>>> - Eric
>>>
>>> On Fri, Jun 1, 2012 at 12:32 PM, Chirag wrote:
>>>
 Hello Eric,

 Thanks for reply.
 Yes i will look into date and time suggestion you mentioned.
 But,for logging, I have $user->LogAll(); is set.
 but i am not getting any log. I just got logs for reporting and it 
 is attached.

 Thanks,
 chirag



 On Friday, June 1, 2012 9:37:09 PM UTC+5:30, Eric Koleda wrote:
>
> Hi Chirag,
>
> It's strange that the error is only appearing on specific server 
> environments. The next step in debugging this issue would be to take 
> a look 
> at the URL the SOAP request is being made to, since the PHP client 
> library 
> appends the OAuth parameters to the URL.  If you enable SOAP XML 
> logging 
> the URL is recorded in the logs.  Perhaps a visual inspection of the 
> URL 
> will show a difference between the environments.
>
> One possible cause to investigate is whether the date and time is 
> configured correctly on the server. When signing the OAuth parameters 
> the 
> current date/time is used, and if this is incorrect the AdWords API 
> server 
> may reject the request.
>
> Best,
> - Eric Koleda, AdWords API Team
>
> On Friday, June 1, 2012 2:32:08 AM UTC-4, Chirag wrote:
>>
>> Hello Danial,
>> Any update i am waiting for your reply otherwise i need to change 
>> server co