Hello Marc,

To get the accessible accounts for a user you can use 
CustomerService.ListAccessibleCustomers 
<https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v0.services#google.ads.googleads.v0.services.CustomerService>
 which 
returns resource names of customers directly accessible by the user 
authenticating the call and then you can use the query specified earlier to 
get the entire hierarchy. I used the same query and got all the accounts 
under my MCC, the sub MCCs and accounts under that sub MCCs as well. 

Also the Customer.id and customer.descriptive_name are same for all as the 
call made with that account and customer object refers to. I am getting in 
touch with the team to see if there is a possibility to get them in a 
single call. I will update you once I have more information. meanwhile you 
can double check whether you are receiving all the accounts in the 
hierarchy under your MCC with that query. If not, please share the query 
and response along with the email address of the user authenticating the 
API call to take a closer look.    

Regards,
Sai Teja, Google Ads API Team


On Thursday, January 3, 2019 at 6:34:16 AM UTC-5, Marc Selman wrote:
>
> I'm trying to retrieve a complete nested tree of all customers (and if 
> it's a manager account, the customers below that etc.)
> To do this I'm using the new Google Ads API (v0.7) to retrieve the 
> CustomerClientLinks recursively and for every link I'm using GetCustomer to 
> retrieve the customer information such as the DescriptiveName.
> But for a simple tree with two levels and a total of 37 customers this 
> takes around a minute.
>
> The API methods seem rather slow. Is that normal?
>
> Also, I need to retrieve the links and the customerdata for every found 
> customerId to check if they have subaccounts and to get the name.
> Because of this I need to perform a lot of calls which could (with a large 
> tree) easily hit the rate limit.
> It would be better if I could retrieve all the available customers (paged) 
> in one call instead of having to recursively find them.
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
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/2bd6f102-4141-44ce-a435-835d3dea8509%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • Retriev... Marc Selman
    • Re... 'Teja Makani' via AdWords API and Google Ads API Forum
    • Re... 'Teja Makani' via AdWords API and Google Ads API Forum
      • ... Marc Selman
    • Re... 'Teja Makani' via AdWords API and Google Ads API Forum
      • ... Marc Selman
    • Re... 'Teja Makani' via AdWords API and Google Ads API Forum
      • ... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum

Reply via email to