the creation date of a campaign to show?

4,177 views
Skip to first unread message

spetz

unread,
Sep 5, 2012, 12:37:30 PM9/5/12
to adwor...@googlegroups.com
hey there,

I query campaigns in "all time" as google adwords does. I know that I could fetch the whole campaign data by setting start date to something 01/01/1900 and it works as I see the same results (amounts and numbers I mean) with adwords. but the question is what is the exact start date of that result set, that is not year 1900 for example. This means Google is able to show the creation date of an account to use it to fetch all data from the beginning, how will we do that using API?

Oliver

unread,
Sep 5, 2012, 3:06:11 PM9/5/12
to adwor...@googlegroups.com
Are you asking about the creation date of a campaign (as in question title) or the creation date of an account (as in your question body)?

If for a campaign, you can find this out by fetching the campaign's "StartDate" from the CampaignService object.

Not sure a start date of an account is available anywhere.

Oliver

spetz

unread,
Sep 7, 2012, 12:21:14 PM9/7/12
to adwor...@googlegroups.com
Actually, what I want to show in my application is the start date that you see when you click on "All time" from the date template list in your Adwords account.

forexample if you've created your account in 1 January 2012, you will see this date and today's date if you click to "All time" reports in Adwords. So I would like to show this date when I attemp to get campaign list for all time (I use "01/01/1970" as starDate in dateRange selector, so I get this date in the campaignStats object as response!)




5 Eylül 2012 Çarşamba 18:06:11 UTC+3 tarihinde Oliver yazdı:

Oliver

unread,
Sep 7, 2012, 1:27:00 PM9/7/12
to adwor...@googlegroups.com
ok, I see what you mean.  I'm not sure if this start date is available anywhere in the API (but I could be wrong).

Oliver

Danial Klimkin

unread,
Sep 10, 2012, 1:19:58 PM9/10/12
to adwor...@googlegroups.com
Hello spetz,


I believe this date comes from the very first row of impressions data ran with no filter rather than from any stored value. The API does not provide the account creation date.


-Danial, AdWords API Team.

Oliver

unread,
Sep 10, 2012, 2:23:59 PM9/10/12
to adwor...@googlegroups.com
Hi Danial,

Can you please elaborate? 

I presume you mean get an account performance report, specifying ALL_TIME as the date range. Correct?  The report returned has this in the first line:

<report name> (All Time)

I can't see the date you were referring to?


Oliver

Danial Klimkin

unread,
Sep 10, 2012, 3:21:11 PM9/10/12
to adwor...@googlegroups.com
Hello Oliver,


I meant the data itself. In a report with the date column the very early date present could be the one you are looking for.


-Danial, AdWords API Team.

Oliver

unread,
Sep 11, 2012, 8:20:00 AM9/11/12
to adwor...@googlegroups.com

Thanks. However, I think the first date in the report will be the date the account started accruing impressions rather than the account creation date (since Date prevents zero impressions).

I tested it in one of our accounts and confirmed this is the case.

Hence, I guess the account creation date cannot be retrieved unless the account started accruing impressions on the same day it was created.

Oliver

Zweitze

unread,
Sep 12, 2012, 8:41:17 AM9/12/12
to adwor...@googlegroups.com
I use a different, slightly better method:
 
Use campaignservice, just get campaigns and make sure you ask for the campaign start date. The campaign start date is NOT the date the campaign was created, still, it is usual earlier than the date of the first impression.
 
To get the earliest date of an account I ask for campaigns sorted on campaign start date and limit the results to 1, costing me 1 unit.
 
Another direction would be the customersyncservice, just get the date of the first change in the account. BTW I never tested this.
 
Hope this helps

J

unread,
Oct 31, 2012, 12:24:24 AM10/31/12
to adwor...@googlegroups.com
I have the same need to know the account creation date.  

In my case, I need to know the account creation date because I'm building a reporting service that queries the CAMPAIGN_PERFORMANCE_REPORT (AdHoc reports).  The algorithm I'm using is to start with today's date, then query backwards (reverse chronologically) one month at a time.  The problem is I need a reliable way to know when to stop querying.  My current method is to stop querying when I get 0 records for a query.  I'm not sure if this is reliable as I'm guessing it's possible that there could be no activity for a month (perhaps when campaigns are paused)?

Knowing the account creation date would give me a reliable way to stop querying since this will ensure that I'm querying the entire period of the account's existence.

Zweitze - I will try your way of using CampaignService.  It's too bad the account creation date is not returned in the CustomerService.get() call.

Any better ideas?

Danial Klimkin

unread,
Oct 31, 2012, 9:01:31 AM10/31/12
to adwor...@googlegroups.com
Hello J,


I actually like the solution provided by Zweitze. Querying the oldest campaign (make sure you include inactive campaigns too) will product the date which is guaranteed to be same or earlier as the first impression date.

This should be more reliable than the empty report case.


-Danial, AdWords API Team.

Kevin Winter

unread,
Nov 7, 2012, 9:52:37 PM11/7/12
to adwor...@googlegroups.com
Another option is to use the Account Performance report with the fields Year, Month and Impressions.  This will give one row per month that you can query separately.

- Kevin Winter
AdWords API Team
Reply all
Reply to author
Forward
0 new messages