error when i create image ad on group

20 views
Skip to first unread message

dian...@everstring.com

unread,
Mar 27, 2015, 2:50:40 PM3/27/15
to adwor...@googlegroups.com
the errer:

suds.WebFault: Server raised fault: 'Unmarshalling Error: cvc-complex-type.2.4.a: Invalid content was found starting with element 'ns0:adGroupId'. One of '{"https://adwords.google.com/api/adwords/cm/v201409":ad, "https://adwords.google.com/api/adwords/cm/v201409":experimentData, "https://adwords.google.com/api/adwords/cm/v201409":status, "https://adwords.google.com/api/adwords/cm/v201409":approvalStatus, "https://adwords.google.com/api/adwords/cm/v201409":disapprovalReasons, "https://adwords.google.com/api/adwords/cm/v201409":trademarkDisapproved, "https://adwords.google.com/api/adwords/cm/v201409":labels, "https://adwords.google.com/api/adwords/cm/v201409":forwardCompatibilityMap}' is expected. '

mycode:

operations = [
            {
                'operator': 'ADD',
                'operand': {
                    'xsi_type': 'AdGroupAd',
                    'adGroupId': ad_group_id,
                    'ad': {
                        'xsi_type': 'ImageAd',
                        'displayUrl': display_url,
                        'url': url,
                        # 'description1': desc1,
                        # 'description2': desc2,
                        # 'headline': headline
                        'image': {
                            'xsi_type': 'Image',
                            'data': image_data
                        #    'type': 'IMAGE'
                        },
                        'name': image_name
                    },
                    # Optional fields.
                    'status': 'ENABLED'
                }
            }
        ]
        text_ads = self.ad_group_ad_service.mutate(operations)



If you can help me, thank you very much.

Josh Radcliff (AdWords API Team)

unread,
Mar 30, 2015, 11:12:40 AM3/30/15
to adwor...@googlegroups.com
Hi,

Are you still having trouble with this request? If so, could you post your SOAP request with sensitive information removed?

Thanks,
Josh, AdWords API Team
Reply all
Reply to author
Forward
0 new messages