Hi Joel, I am able to retrieve units correctly in my tests. Something to be aware of is that for the InfoService to work correctly the MCC user that owns the developer token must be the one to make the request. Requests made by other MCCs or AdWords accounts will not return any information. We are in the processes of update the documentation to reflect this.
Best, - Eric Koleda, AdWords API Team On Dec 17, 2:17 pm, joel <[email protected]> wrote: > I'm not sure if this is related, but I'm also seeing 0 returned as the > cost for all calls I made to the InfoService. I'm still in the process > of migrating from v13, so should v13 API units used still show up > under UNIT_COUNT? Here's the sanitized SOAP I'm sending that's > returning 0 cost: > > <?xml version="1.0" encoding="UTF-8"?><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 > soapenv:actor="http://schemas.xmlsoap.org/soap/actor/next" > soapenv:mustUnderstand="0" xmlns:ns1="https://adwords.google.com/api/ > adwords/info/v200909"><ns2:applicationToken xmlns:ns2="https:// > adwords.google.com/api/adwords/cm/v200909">TOKEN</ > ns2:applicationToken><ns3:authToken xmlns:ns3="https:// > adwords.google.com/api/adwords/cm/v200909">******</ > ns3:authToken><ns4:clientCustomerId xmlns:ns4="https:// > adwords.google.com/api/adwords/cm/v200909">ID</ > ns4:clientCustomerId><ns5:developerToken xmlns:ns5="https:// > adwords.google.com/api/adwords/cm/v200909">TOKEN</ > ns5:developerToken><ns6:userAgent xmlns:ns6="https:// > adwords.google.com/api/adwords/cm/v200909">AGENT</ > ns6:userAgent><ns7:validateOnly xmlns:ns7="https://adwords.google.com/ > api/adwords/cm/v200909">false</ns7:validateOnly></ns1:RequestHeader></ > soapenv:Header><soapenv:Body><get xmlns="https://adwords.google.com/ > api/adwords/info/v200909"><selector><dateRange><ns8:min > xmlns:ns8="https://adwords.google.com/api/adwords/cm/ > v200909">20091201</ns8:min><ns9:max xmlns:ns9="https:// > adwords.google.com/api/adwords/cm/v200909">20091216</ns9:max></ > dateRange><apiUsageType>UNIT_COUNT</apiUsageType></selector></get></ > soapenv:Body></soapenv:Envelope> <main> (handleRequest.159) > > DEBUG [soap_xml] <?xml version="1.0" encoding="UTF-8"?><soap:Envelope > xmlns:soap="http://schemas.xmlsoap.org/soap/ > envelope/"><soap:Header><ns2:ResponseHeader xmlns:ns2="https:// > adwords.google.com/api/adwords/info/v200909" xmlns="https:// > adwords.google.com/api/adwords/cm/ > v200909"><requestId>37b605d5b1f0f2d70b2451589608ea58</ > requestId><operations>1</operations><responseTime>489</ > responseTime><units>1</units></ns2:ResponseHeader></ > soap:Header><soap:Body><ns2:getResponse xmlns="https:// > adwords.google.com/api/adwords/cm/v200909" xmlns:ns2="https:// > adwords.google.com/api/adwords/info/v200909"><ns2:rval><ns2:cost>0</ > ns2:cost></ns2:rval></ns2:getResponse></soap:Body></soap:Envelope> > <main> (handleResponse.219) > > Thanks! > > -Joel > > On Dec 2, 12:25 pm, AdWords API Advisor <[email protected]> > wrote: > > > > > Hi James, > > > Your request looks correctly formatted, and I am seeing the same > > behavior on my end. I've reported the issue to the core engineering > > team and I'll update this thread when I have more information. > > > Best, > > - Eric Koleda, AdWords API Team > > > On Dec 1, 8:35 pm, James <[email protected]> wrote: > > > > Hello, > > > We are migrating our code to v2009. We have a job which gets the quota > > > used per method for a specified date range, and am having trouble > > > getting this working in v2009. I get the total quota for a date range > > > without any trouble, but when I add a service/method to the selector > > > it always returns 0. > > > Now in the migration > > > guidehttp://code.google.com/apis/adwords/v2009/docs/callguide.html#infoser... > > > It does not mention the getUnitCountForMethod call. Does that mean it > > > is not supported in v2009? > > > I have tried using both v13 and v2009 service/method filters. SOAP is > > > below. > > > > As I said, it seems to be working fine without the service/method tags > > > in the SOAP. > > > Thanks in advance > > > James > > > > -------------------------- v13 --------------------------------- > > > <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/ > > > envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" > > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > > > xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns1="https:// > > > adwords.google.com/api/adwords/info/v200909" xmlns:ns2="https:// > > > adwords.google.com/api/adwords/cm/v200909" > > > > <SOAP-ENV:Header> > > > <ns1:RequestHeader SOAP-ENC:arrayType="xsd:string[4]"> > > > <ns2:authToken xsi:type="xsd:string">aaaa</ns2:authToken> > > > <ns2:useragent xsi:type="xsd:string">bbbb</ns2:useragent> > > > <ns2:developerToken xsi:type="xsd:string">cccc</ns2:developerToken> > > > <ns2:applicationToken xsi:type="xsd:string">dddd</ > > > ns2:applicationToken> > > > </ns1:RequestHeader> > > > </SOAP-ENV:Header> > > > <SOAP-ENV:Body> > > > <get xmlns="https://adwords.google.com/api/adwords/info/v200909" > > > xmlns:cm="https://adwords.google.com/api/adwords/cm/v200909"> > > > <selector> > > > <serviceName>CriterionService</serviceName> > > > <methodName>getAllCriteria</methodName> > > > <dateRange> > > > <cm:min>20091101</cm:min> > > > <cm:max>20091130</cm:max> > > > </dateRange> > > > <apiUsageType>UNIT_COUNT</apiUsageType> > > > </selector> > > > </get> > > > </SOAP-ENV:Body> > > > </SOAP-ENV:Envelope> > > > > <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> > > > <soap:Header> > > > <ns2:ResponseHeader xmlns:ns2="https://adwords.google.com/api/adwords/ > > > info/v200909" xmlns="https://adwords.google.com/api/adwords/cm/ > > > v200909"> > > > <requestId>1075aba1906b64e2ca628dc5d8d5a3e0</requestId> > > > <operations>1</operations> > > > <responseTime>3503</responseTime> > > > <units>1</units> > > > </ns2:ResponseHeader> > > > </soap:Header> > > > <soap:Body> > > > <ns2:getResponse xmlns="https://adwords.google.com/api/adwords/cm/ > > > v200909" xmlns:ns2="https://adwords.google.com/api/adwords/info/ > > > v200909"> > > > <ns2:rval> > > > <ns2:cost>0</ns2:cost> > > > </ns2:rval> > > > </ns2:getResponse> > > > </soap:Body> > > > </soap:Envelope> > > > > -------------------------- v2009 --------------------------------- > > > <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/ > > > envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" > > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > > > xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns1="https:// > > > adwords.google.com/api/adwords/info/v200909" xmlns:ns2="https:// > > > adwords.google.com/api/adwords/cm/v200909" > > > > <SOAP-ENV:Header> > > > <ns1:RequestHeader SOAP-ENC:arrayType="xsd:string[4]"> > > > <ns2:authToken xsi:type="xsd:string">aaaa</ns2:authToken> > > > <ns2:useragent xsi:type="xsd:string">bbbb</ns2:useragent> > > > <ns2:developerToken xsi:type="xsd:string">cccc</ns2:developerToken> > > > <ns2:applicationToken xsi:type="xsd:string">dddd</ > > > ns2:applicationToken> > > > </ns1:RequestHeader> > > > </SOAP-ENV:Header> > > > <SOAP-ENV:Body> > > > <get xmlns="https://adwords.google.com/api/adwords/info/v200909" > > > xmlns:cm="https://adwords.google.com/api/adwords/cm/v200909"> > > > <selector> > > > <serviceName>AdGroupCriterionService</serviceName> > > > <methodName>get</methodName> > > > <dateRange> > > > <cm:min>20091101</cm:min> > > > <cm:max>20091130</cm:max> > > > </dateRange> > > > <apiUsageType>UNIT_COUNT</apiUsageType> > > > </selector> > > > </get> > > > </SOAP-ENV:Body> > > > </SOAP-ENV:Envelope> > > > > <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> > > > <soap:Header> > > > <ResponseHeader xmlns:ns2="https://adwords.google.com/api/adwords/cm/ > > > v200909" xmlns="https://adwords.google.com/api/adwords/info/v200909"> > > > <ns2:requestId>349eb305ee75b5a20f7cb45f5e809431</ns2:requestId> > > > <ns2:operations>1</ns2:operations> > > > <ns2:responseTime>2601</ns2:responseTime> > > > <ns2:units>1</ns2:units> > > > </ResponseHeader> > > > </soap:Header> > > > <soap:Body> > > > <getResponse xmlns="https://adwords.google.com/api/adwords/info/ > > > v200909" xmlns:ns2="https://adwords.google.com/api/adwords/cm/ > > > v200909"> > > > <rval> > > > <cost>0</cost> > > > </rval> > > > </getResponse> > > > </soap:Body> > > > </soap:Envelope> -- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en.
