Hello,
Unfortunately, it's currently not possible to get the customer names of the
accounts under your manager using Google Ads API. Our team is currently
working on adding this feature.
Please follow our blog
<http://googleadsdeveloper.blogspot.com/search/label/adwords_scripts> for
any updates.
Regards,
Anthony
Google Ads API Team
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
https://ads-developers.googleblog.com/search/label/google_ads_api
https://developers.google.com/adwords/api/community/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
On 04/23/19 01:49:44 [email protected] wrote:
There's so much information online for AdWords API but almost nothing for
the Google Ads.
Everywhere I look I see suggestions to use CustomerService.getCustomers()
but this command is meaningless when working with Google Ads api, because
you need an AdWordsSession instance.
WIth the code below I can manage to extract their ID somehow off the
GoogleAdsRow but can't find their name:
try (GoogleAdsServiceClient googleAdsServiceClient =
googleAdsClient.getLatestVersion().createGoogleAdsServiceClient()) {
String query = "SELECT customer.id, customer.descriptive_name,
customer_client.resource_name, customer_client.client_customer,
customer_client.level, customer_client.hidden FROM customer_client";
SearchGoogleAdsRequest request =
SearchGoogleAdsRequest.newBuilder().setCustomerId(Long.toString(customerId)).setPageSize(PAGE_SIZE).setQuery(query).build();
SearchPagedResponse searchPagedResponse =
googleAdsServiceClient.search(request);
for (GoogleAdsRow googleAdsRow : searchPagedResponse.iterateAll()) {
Customer customer = googleAdsRow.getCustomer();
System.out.println(customer.???);
}
}
The information contained in this communication and its attachments is
intended solely for the use of the individual or entity to whom it is
addressed and others authorized to receive it. It is the property of Albert
and may contain confidential or legally privileged information. If you are
not the intended recipient you are hereby notified that any disclosure,
copying, retention, printing or distribution of this communication or any
part thereof, or taking any action in reliance on the contents of this
information is strictly prohibited and may be unlawful. If you have
received this communication in error, please notify us immediately by
responding to this email and then delete all copies of it from your system.
Albert is not liable for the proper and complete transmission of the
information contained in this communication nor for any delay in its
receipt.
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [email protected].
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit
https://groups.google.com/d/msgid/adwords-api/254b24a5-2197-4fdf-8b10-3d1b72c3a26c%40googlegroups.com
<https://groups.google.com/d/msgid/adwords-api/254b24a5-2197-4fdf-8b10-3d1b72c3a26c%40googlegroups.com?utm_medium=email&utm_source=footer>
.
For more options, visit https://groups.google.com/d/optout.
--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit
https://groups.google.com/d/msgid/adwords-api/186sp0o0000000018mo4dm000b3p2cy74mjgchp70o30c1g68r34e1k%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.