import googleads
client = googleads.adwords.AdWordsClient.LoadFromStorage()
client.SetClientCustomerId('841-135-3369')
service = client.GetService('ConversionTrackerService')
operations = [
{'operand': {
'alwaysUseDefaultRevenueValue': False,
'attributionModelType': 'LAST_CLICK',
'category': 'DEFAULT',
'countingType': 'MANY_PER_CLICK',
'ctcLookbackWindow': 90,
'defaultRevenueCurrencyCode': 'USD',
'defaultRevenueValue': 0.0,
'excludeFromBidding': True,
'name': 'Foo Website Conversion',
'status': 'ENABLED',
'trackingCodeType': 'WEBPAGE',
'viewthroughLookbackWindow': 30,
'xsi_type': 'AdWordsConversionTracker'
},
'operator': 'ADD'}
]
service.mutate(operations)
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<ResponseHeader xmlns="https://adwords.google.com/api/adwords/cm/v201710">
<requestId>00056d549ed9bad80a620b522f0faee9</requestId>
<serviceName>ConversionTrackerService</serviceName>
<methodName>mutate</methodName>
<operations>1</operations>
<responseTime>401</responseTime>
</ResponseHeader>
</soap:Header>
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>[RequestError.UNKNOWN @ operations[0]]</faultstring>
<detail>
<ApiExceptionFault xmlns="https://adwords.google.com/api/adwords/cm/v201710">
<message>[RequestError.UNKNOWN @ operations[0]]</message>
<ApplicationException.Type>ApiException</ApplicationException.Type>
<errors xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="RequestError">
<fieldPath>operations[0]</fieldPath>
<fieldPathElements>
<field>operations</field>
<index>0</index>
</fieldPathElements>
<trigger/>
<errorString>RequestError.UNKNOWN</errorString>
<ApiError.Type>RequestError</ApiError.Type>
<reason>UNKNOWN</reason>
</errors>
</ApiExceptionFault>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>