login_customer_id issue

44 views
Skip to first unread message

charles lerasan

unread,
Mar 17, 2022, 3:46:43 AM3/17/22
to Google Ads API and AdWords API Forum
hi I have been reading a lot of answers and googled a few solutions. but none is working

To start.
I have a manager account : 123-456-7890
I have multiple client accounts under that manager account:
client_1 : 111-111-111-1
client_2: 222-222-222-2

Now, I am lost what is the login customer id. I tried using the ID 101.JPG
But none of the IDs are working. When I used the Customer ID i am getting this:
"User doesn\'t have permission to access customer. Note: If you\'re accessing a client customer, the manager\'s customer id must be set in the \'login-customer-id\' header. See https://developers.google.com/google-ads/api/docs/concepts/call-structure#cid"

I was able to get reports properly using the AdwordsClient but now that I am migrating to GoogleAdsClient I am getting this issue :(

Please help.

Google Ads API Forum Advisor

unread,
Mar 17, 2022, 9:09:33 AM3/17/22
to charles.anth...@gmail.com, adwor...@googlegroups.com

Hi there,

Thanks for reaching out to the Google Ads API Forum.

You may double check if the user / email address you used to generate the credentials indeed has access to the account in your request( your login-customer-id field). The USER_PERMISSION_DENIED error usually indicates that you are authenticating as a user that does not have access to the target account specified in your API request.

To avoid the said error, you will need to ensure that the user / email address you used to generate the credentials indeed has access to the account in your request. If the user / email address has access or is associated to the MCC / manager account, you will need to specify the said MCC / manager account's ID without hyphen(-) as the value of the login-customer-id field.

If you still persist with the error, you may provide us with the complete request and response logs, with the request-id along with the email address used to generate the OAuth2 credentials via Reply to Autor Privately option, so that I can continue to investigate further.

Regards,

Google Logo
Yasar
Google Ads API Team
 


ref:_00D1U1174p._5004Q2Yoly2:ref
Reply all
Reply to author
Forward
0 new messages