I'm trying to run the get_campaigns.py example code. I created the adwords client object using the correct, client_id, client_secret and refresh_token. When I run it however I get the traceback ending with
Server raised fault:
[QuotaCheckError.INVALID_TOKEN_HEADER @ ; trigger:'6Ji***developer-token****Yg']When I scroll up the logs I see that HEADERS were logged and they don't mention any developerToken that should have been, as per this guide
URL: https://adwords.google.com/api/adwords/cm/v201605/CampaignService
HEADERS: {'Soapaction': b'""', 'Content-Type': 'text/xml; charset=utf-8', 'Content-type': 'text/xml; charset=utf-8', 'Authorization': 'Bearer ya2***access_token***194f3g', 'SOAPAction': b'""'}
MESSAGE: b'<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:tns="https://adwords.google.com/api/adwords/cm/v201605" xmlns:ns1="https://adwords.google.com/api/adwords/cm/v201605" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Header><tns:RequestHeader><tns:clientCustomerId>659-360-1388</tns:clientCustomerId><tns:developerToken>6Ji***developer-token****Yg</tns:developerToken><tns:userAgent>MYM (AwApi-Python, googleads/4.2.0, Python/3.5.1)</tns:userAgent><tns:validateOnly>false</tns:validateOnly><tns:partialFailure>false</tns:partialFailure></tns:RequestHeader></SOAP-ENV:Header><ns0:Body><ns1:get><ns1:serviceSelector><ns1:fields>Id</ns1:fields><ns1:fields>Name</ns1:fields><ns1:fields>Status</ns1:fields><ns1:paging><ns1:startIndex>0</ns1:startIndex><ns1:numberResults>100</ns1:numberResults></ns1:paging></ns1:serviceSelector></ns1:get></ns0:Body></SOAP-ENV:Envelope>'
Also, could you please confirm this: the developer token was granted for in...@mydomain.com while the client_id and client_secret were created with reporting+...@mydomain.com
which is a test manager account that I created for testing the API.
Does this make a difference? Also, the developer_token is in test_account status now.
Can you please tell me what I am doing wrong? I can PM you my credentials and script to try it out at your end. I have been struggling to fix this issue for the last 5 days. If this Python lib is not well supported, please tell me what is the recommended platform so that I can I'll switch to it. Thanks a lot for you help!