I understand that you use .NET. When you get a WebException with HTTP 400, do download the response: take WebException.Response, cast it to HttpWebResponse, then call it's GetResponseStream() method. You will find some XML with more info on the problem with the request.
My guess: your code fails about an hour after the AccessToken was retrieved, and you are using OAuth2. OAuth2 access tokens are only valid for an hour, after that you should obtain a new AccessToken. (Note: I don't use the .NET library for retrieving reports. If you do, the library should parse the WebException and retrieve the info from the WebException. But, I believe the library contains an error that expired AccessTokens will not be renewed automatically.) Hope this helps. On Tuesday, April 8, 2014 8:29:59 PM UTC+2, Brett Rogers wrote: > > Scenario: > > We have a daily task that downloads AdWords AdHoc reports for our MCC > account's accounts, campaigns, ad groups, and ads to synchronize them with > our local database. We have multiple accounts in our MCC and each account > has large quantities of ad groups, so we download quite a bit of data. This > process worked great until a few weeks ago, when we started the following > error part of the way through the process: > > - The remote server returned an error: (400) Bad Request. > > Once this error occurs on the main daily task computer, we see the > following: > > - AdHoc Reports requests initiated from that computer fail after a handful > of requests > - AdWords API requests initiated from that computer fail with this error: > -- An existing connection was forcibly closed by the remote host > > BUT, if we then launch this same daily task from another computer, it will > successfully complete everything and API requests will also work, i.e., the > same auth credentials work elsewhere, just not from that computer. > > Ideas? Are we running into some kind of IP or computer-based quota? > > FYI - we're using the latest API version - v201402, but the problem was > also occurring with v201309 before we recently upgraded. > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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 --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.