Thanks. It is ok using java client liabrary, but got error with python liabrary.
On 12月1日, 上午7时06分, AdWords API Advisor <adwordsapiadvi...@google.com> wrote: > Hi, > > The sandbox sometimes has trouble with image formats. In our examples > we always use the following image, which uploads without error: > > https://sandbox.google.com/sandboximages/image.jpg > > Best, > - Eric Koleda, AdWords API Team > > On Nov 28, 9:41 pm, faqing wu <wfqz...@gmail.com> wrote: > > > HI, > > I got ImageError.INVALID_IMAGEerror when new image ad (test.jpeg) > > and i use python client library. > > anyone can help me? > > > here is log, > > > requestId=13a67b0681454d8034adb36e4aa55378 > > > [2010-11-29 10:29:51,875::DEBUG::AwApi-Python-12.1.0] StartTime: > > 2010-11-29 10:29:50 > > *** Outgoing HTTP headers > > ********************************************** > > POST /api/adwords/cm/v201003/AdGroupAdService HTTP/1.0 > > Host: adwords-sandbox.google.com > > User-agent: SOAPpy 0.12.0 (http://pywebsvcs.sf.net) > > XML-parser: PyXML v0.8.3 > > Content-type: text/xml; charset="UTF-8" > > Content-length: 1679 > > SOAPAction: "None" > > ************************************************************************ > > *** Outgoing SOAP > > ****************************************************** > > <?xml version="1.0" encoding="UTF-8"?> > > <SOAP-ENV:Envelope SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/ > > soap/encoding/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/ > > envelope/" xmlns:xsd3="http://www.w3.org/2001/XMLSchema" > > xmlns:xsi3="http://www.w3.org/2001/XMLSchema-instance"> > > <SOAP-ENV:Header xmlns="https://adwords.google.com/api/adwords/cm/ > > v201003"> > > <RequestHeader> > > <authToken xsi3:type="xsd3:string">xxxxxx</authToken> > > <userAgent xsi3:type="xsd3:string">AwApi-Python-12.1.0|mt</ > > userAgent> > > <developerToken xsi3:type="xsd3:string">zhgl...@gmail.com++cny</ > > developerToken> > > <clientEmail xsi3:type="xsd3:string">client_1+zhgl...@gmail.com</ > > clientEmail> > > </RequestHeader> > > </SOAP-ENV:Header> > > <SOAP-ENV:Body xmlns="https://adwords.google.com/api/adwords/cm/ > > v201003"> > > <mutate xmlns="https://adwords.google.com/api/adwords/cm/v201003"> > > <operations> > > <operator>ADD</operator> > > <operand xsi3:type="AdGroupAd"> > > <adGroupId>3000043659</adGroupId> > > <ad xsi3:type="ImageAd"> > > <url>http://www.macrotarget.com/index.html</url> > > <displayUrl>www.macrotarget.com</displayUrl> > > <image xsi3:type="Image"> > > <dimensions> > > <key>FULL</key> > > <value xsi3:type="Dimensions"> > > <width>200</width> > > <height>200</height> > > </value> > > </dimensions> > > <name>pic1</name> > > <data>/9j/4AAQSkZJRgABAgEASABIAAD/ > > 4RnCRXhpZgAATU0AKgAAAAgABwESAAMAAAABAAEAAAE=</data> > > </image> > > <name>图片广告1</name> > > </ad> > > <status>ENABLED</status> > > </operand> > > </operations> > > </mutate> > > </SOAP-ENV:Body> > > </SOAP-ENV:Envelope> > > ************************************************************************ > > *** Incoming HTTP headers > > ********************************************** > > HTTP/1.? 500 Internal Server Error > > Content-Type: text/xml; charset=UTF-8 > > Date: Mon, 29 Nov 2010 02:29:54 GMT > > Expires: Mon, 29 Nov 2010 02:29:54 GMT > > Cache-Control: private, max-age=0 > > X-Content-Type-Options: nosniff > > X-Frame-Options: SAMEORIGIN > > X-XSS-Protection: 1; mode=block > > Server: GSE > > ************************************************************************ > > *** Incoming SOAP > > ****************************************************** > > <?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/ > > v201003"> > > <requestId>13a67b0681454d8034adb36e4aa55378</requestId> > > <operations>1</operations> > > <responseTime>232</responseTime> > > <units>40</units> > > </ResponseHeader> > > </soap:Header> > > <soap:Body> > > <soap:Fault> > > <faultcode>soap:Server</faultcode> > > <faultstring>[ImageError.INVALID_IMAGE@ > > operations[0].operand.ad.image.data]</faultstring> > > <detail> > > <ApiExceptionFault xmlns="https://adwords.google.com/api/adwords/ > > cm/v201003"> > > <message>[ImageError.INVALID_IMAGE@ > > operations[0].operand.ad.image.data]</message> > > <ApplicationException.Type>ApiException</ > > ApplicationException.Type> > > <errors xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > > xsi:type="ImageError"> > > <fieldPath>operations[0].operand.ad.image.data</fieldPath> > > <trigger/> > > <errorString>ImageError.INVALID_IMAGE</errorString> > > <ApiError.Type>ImageError</ApiError.Type> > > <reason>INVALID_IMAGE</reason> > > </errors> > > </ApiExceptionFault> > > </detail> > > </soap:Fault> > > </soap:Body> > > </soap:Envelope> > > ************************************************************************ > > EndTime: 2010-11-29 10:29:51 > > > Best regards, -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and discussion group: http://adwordsapi.blogspot.com http://groups.google.com/group/adwords-api =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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