HI,
I tried to use 
googleads-java-lib(https://github.com/googleads/googleads-java-lib) to 
access adwords data,but got the ERROR 
AuthorizationError.SERVICE_ACCESS_DENIED.I am very confused about this 
problem´╝îcause I am the admin user on my MCC account and I have got correct 
Credentials in google concole account with admin permission. Also I got 
refresh_token with auth_code.Our developerToken on MCC account is the basic 
access level.

Here is some urls and scope which I have used:
*https://accounts.google.com/o/oauth2/v2/auth*
*https://accounts.google.com/o/oauth2/token*
*https://www.googleapis.com/auth/adwords*

Best regards.

*This is the soap request and response:*

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance";>
    <soapenv:Header>
        <ns1:RequestHeader xmlns:ns1="
https://adwords.google.com/api/adwords/cm/v201802"; 
soapenv:mustUnderstand="0">
            <ns1:clientCustomerId>706-805-9323</ns1:clientCustomerId>
            <ns1:developerToken>REDACTED</ns1:developerToken>
            <ns1:userAgent>unknown (AwApi-Java, AdWords-Axis/3.13.0, 
Common-Java/3.13.0, Axis/1.4, Java/1.7.0_65, jars, SelectorBuilder, 
SelectorField)</ns1:userAgent>
            <ns1:validateOnly>false</ns1:validateOnly>
            <ns1:partialFailure>false</ns1:partialFailure>
        </ns1:RequestHeader>
    </soapenv:Header>
    <soapenv:Body>
        <get xmlns="https://adwords.google.com/api/adwords/cm/v201802";>
            <serviceSelector>
                <fields>Id</fields>
                <fields>Name</fields>
                <ordering>
                    <field>Name</field>
                    <sortOrder>ASCENDING</sortOrder>
                </ordering>
                <paging>
                    <startIndex>0</startIndex>
                    <numberResults>100</numberResults>
                </paging>
            </serviceSelector>
        </get>
    </soapenv:Body>
</soapenv:Envelope>
 

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
    <soap:Header>
        <ResponseHeader xmlns="
https://adwords.google.com/api/adwords/cm/v201802";>
            <requestId>0005698c139ffbd90a620f1b130b7439</requestId>
            <serviceName>CampaignService</serviceName>
            <methodName>get</methodName>
            <operations>1</operations>
            <responseTime>166</responseTime>
        </ResponseHeader>
    </soap:Header>
    <soap:Body>
        <soap:Fault>
            <faultcode>soap:Client</faultcode>
            <faultstring>[AuthorizationError.SERVICE_ACCESS_DENIED @ 
]</faultstring>
            <detail>
                <ApiExceptionFault xmlns="
https://adwords.google.com/api/adwords/cm/v201802";>
                    <message>[AuthorizationError.SERVICE_ACCESS_DENIED @ 
]</message>
                    
<ApplicationException.Type>ApiException</ApplicationException.Type>
                    <errors xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"; xsi:type="AuthorizationError">
                        <fieldPath/>
                        <trigger/>
                        
<errorString>AuthorizationError.SERVICE_ACCESS_DENIED</errorString>
                        <ApiError.Type>AuthorizationError</ApiError.Type>
                        <reason>SERVICE_ACCESS_DENIED</reason>
                    </errors>
                </ApiExceptionFault>
            </detail>
        </soap:Fault>
    </soap:Body>
</soap:Envelope>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and Google+:
https://googleadsdeveloper.blogspot.com/
https://plus.google.com/+GoogleAdsDevelopers/posts
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords 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 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/251d8360-2e2c-4f90-92d2-1aa57642fadc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • HELP: Authorizat... Kevin Tian
    • Re: HELP: A... 'Vincent Racaza (AdWords API Team)' via AdWords API Forum
    • Re: HELP: A... 'Vincent Racaza (AdWords API Team)' via AdWords API Forum
      • Re: HEL... Kevin Tian
        • Re:... 'Vincent Racaza (AdWords API Team)' via AdWords API Forum

Reply via email to