Java API: list of managed customer accounts in some date range

22 views
Skip to first unread message

Łukasz Gaża

unread,
May 24, 2016, 5:37:06 AM5/24/16
to AdWords API Forum
Hi,
I wanted to get a list of managed customer accounts which existed in some date range (I wanted to do it using Java API).

I was using ManagedCustomerServiceInterface and SelectorBuilder. The code was as the following:

LocalDateTime from = LocalDateTime.parse("1980/05/15", DateTimeFormat.forPattern("yyyy/MM/dd"));
LocalDateTime to = LocalDateTime.parse("1981/05/15", DateTimeFormat.forPattern("yyyy/MM/dd"));

// Create selector builder.
SelectorBuilder selectorBuilder =
new SelectorBuilder()
.fields(ManagedCustomerField.CustomerId, ManagedCustomerField.Name)
.forDateRange(from.toDateTime(), to.toDateTime())
.orderAscBy(ManagedCustomerField.Name);


ManagedCustomerPage page = managedCustomerService.get(selectorBuilder.build());

However it seems that this date range is not applied - I was getting a list of all the account available right now even though I was using as a date range some date in the 80'.

Is there something missing in my approach?

Thanks,
Lukasz

Dorian Kind

unread,
May 24, 2016, 7:14:36 AM5/24/16
to AdWords API Forum
Hi Lukasz,

to the best of my knowledge, what you want to do is not possible. Structural information is not availably historically, only performance data is. You'll have to save that information yourself.

Cheers,
Dorian

Łukasz Gaża

unread,
May 31, 2016, 11:11:30 AM5/31/16
to AdWords API Forum
Thanks Dorian.
Reply all
Reply to author
Forward
0 new messages