Hello,
I am trying to get information about the directly authorized user.
API docs state calling CustomerService.getCustomers() can be used without clientCustomerId, but if I try to do it, I get this error:
> AuthenticationError.CUSTOMER_NOT_FOUND
I am using Python client library:
client = adwords.AdWordsClient(developer_token, oauth2_client, cache=googleads.common.ZeepServiceProxy.NO_CACHE)
customers = client.GetService('CustomerService', version='v201809').getCustomers()
This is the outgoing SOAP request:
{'SOAPAction': '\"\"', 'Content-Type': 'text/xml; charset=utf-8', 'authorization': 'REDACTED'}\n
<soap-env:Envelope
<soap-env:Header>\n
<ns0:RequestHeader
<ns1:developerToken
</ns1:developerToken>\n
<ns2:userAgent
</ns2:userAgent>\n
<ns3:validateOnly
</ns3:validateOnly>\n
<ns4:partialFailure
</ns4:partialFailure>\n
</ns0:RequestHeader>\n
</soap-env:Header>\n
<soap-env:Body>\n
<ns0:getCustomers
</soap-env:Body>\n
</soap-env:Envelope>\n
And this is the response:
<soap:Envelope
<soap:Header>\\n
<ResponseHeader
<ns2:requestId>000590c5fcc1335c0a1b99d657098956</ns2:requestId>\\n
<ns2:serviceName>CustomerService</ns2:serviceName>\\n
<ns2:methodName>getCustomers</ns2:methodName>\\n
<ns2:operations>1</ns2:operations>\\n
<ns2:responseTime>229</ns2:responseTime>\\n
</ResponseHeader>\\n
</soap:Header>\\n
<soap:Body>\\n
<soap:Fault>\\n
<faultcode>soap:Server</faultcode>\\n
<faultstring>[AuthenticationError.CUSTOMER_NOT_FOUND @ ]</faultstring>\\n
<detail>\\n
<ApiExceptionFault
<ns2:message>[AuthenticationError.CUSTOMER_NOT_FOUND @ ]</ns2:message>\\n
<ns2:ApplicationException.Type>ApiException</ns2:ApplicationException.Type>\\n
<ns2:errors
<ns2:fieldPath/>\\n
<ns2:trigger/>\\n
<ns2:errorString>AuthenticationError.CUSTOMER_NOT_FOUND</ns2:errorString>\\n
<ns2:ApiError.Type>AuthenticationError</ns2:ApiError.Type>\\n
<ns2:reason>CUSTOMER_NOT_FOUND</ns2:reason>\\n
</ns2:errors>\\n
</ApiExceptionFault>\\n
</detail>\\n
</soap:Fault>\\n
</soap:Body>\\n
</soap:Envelope>\\n