PERMISSION_DENIED issue

98 views
Skip to first unread message

omr...@singular.net

unread,
Nov 5, 2020, 5:26:44 AM11/5/20
to AdWords API and Google Ads API Forum
Hi Google Ads API Support,

I'm having trouble migrating a customer from Adwords API to  Google Ads API.
Error response:
`Google Ads API raised the following errors: ["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#login-customer-id"], error_code: StatusCode.PERMISSION_DENIED, request_id: 1uN6Uu1IZnRijoTi8ZrZbg`

Query details:
  • API Version = v5
  • Service = GoogleAdsSearch
  • Query = 'SELECT customer.id, customer.descriptive_name, customer.descriptive_name, customer.currency_code, customer.currency_code, customer.manager, customer.time_zone FROM customer'
  • All the private details will be sent privately when responded.
Best,
Omri G.


Google Ads API Forum Advisor Prod

unread,
Nov 5, 2020, 2:46:36 PM11/5/20
to omr...@singular.net, adwor...@googlegroups.com

Hi Omri,

Thank you for reaching out. The error USER_PERMISSION_DENIED usually occurs when there is no link between the manager account authenticated in the request and the client account specified in the headers. As you are using the Google Ads API you need to include the login-customer_id in the header as mentioned in this blog post. Please use the email that has Standard or Admin Access to the manager account to generate the OAuth2 credentials and make the API call again.

Thanks and regards,
Xiaoming, Google Ads API Team
 

Google Logo
Xiaoming
Google Ads API Team
 


ref:_00D1U1174p._5004Q277LIZ:ref

Omri Gal

unread,
Nov 8, 2020, 9:40:38 AM11/8/20
to adwor...@googlegroups.com
Hi Google Ads Support API,

Attaching here privately the full details on the Permission Error we received for our customer when querying the Google Ads API.
Customer - Kakao Games
Login_cusotmer_id - 363-574-7978
Refresh_token - 1//06zUg9_NWetN_CgYIARAAGAYSNwF-L9Ir6ZZassvAo1JhtuLXq-RGfcvo547iJ9-rNZ6ox4-vf5jb20JzJ4WHHD_C163AwkcsakA
Authenticated user = cro...@nasmedia.co.kr

Request_id - 1uN6Uu1IZnRijoTi8ZrZbg
We use the Python Google Ads API Package to make the API calls, same for all customers and we don't get a similar error for our other customers.

Thanks in advance,
Omri Gal, Singular



On Thu, Nov 5, 2020 at 9:46 PM Google Ads API Forum Advisor Prod via Sales & Orders <notifi...@sales--orders.intercom-mail.com> wrote:

This message was sent to the following 2 people: omr...@singular.net, adwor...@googlegroups.com. Replying to this email will notify them.

omr...@singular.net was added to the conversation by Google Ads API Forum Advisor Prod
adwor...@googlegroups.com was added to the conversation by Google Ads API Forum Advisor Prod

Hi Omri,

Thank you for reaching out. The error USER_PERMISSION_DENIED usually occurs when there is no link between the manager account authenticated in the request and the client account specified in the headers. As you are using the Google Ads API you need to include the login-customer_id in the header as mentioned in this blog post. Please use the email that has Standard or Admin Access to the manager account to generate the OAuth2 credentials and make the API call again.

Thanks and regards,
Xiaoming, Google Ads API Team

https://www.gstatic.com/images/branding/product/1x/googleg_64dp.png Xiaoming Google Ads API Team https://google-dev-relations.my.salesforce.com/servlet/servlet.ImageServer?oid=00D1U000001174p&esid=0184Q00001Ayyb1

ref:_00D1U1174p._5004Q277LIZ:ref --
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api...@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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/0DVSX000000000000000000000000000000000000000000000QJC9KS00iEbI63-LR2O2CvmwH2XPpw%40sfdc.net.
intercom

Google Ads API Forum Advisor Prod

unread,
Nov 9, 2020, 11:52:06 AM11/9/20
to omr...@singular.net, adwor...@googlegroups.com

Hi Omri,

Thank you for reaching out. I noticed that the email you mentioned is not a user for account 363-574-7978. Please use an email that is associated with the account 363-574-7978 to generate the OAuth2 credentials and make the API calls again.



Thanks and regards,
Xiaoming, Google Ads API Team

 

Google Logo
Xiaoming
Google Ads API Team
 


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