TargetingIdeaService v201809 malformed response

79 views
Skip to first unread message

Dmitry Omelyusik

unread,
Nov 7, 2019, 7:41:58 AM11/7/19
to AdWords API and Google Ads API Forum
Hi there!

I'm trying to use the TargetingIdeaService to get best ones keywords for my title, but unfortunately, I get a malformed response.
Here's my SOAP request object:
    <s11:Header>
        <ns1:RequestHeader xmlns:ns1="https://adwords.google.com/api/adwords/o/v201809">
            <ns1:clientCustomerId>xxxxxx</ns1:clientCustomerId>
            <ns1:developerToken>xxxxxx</ns1:developerToken>
            <ns1:userAgent></ns1:userAgent>
            <ns1:validateOnly></ns1:validateOnly>
            <ns1:partialFailure></ns1:partialFailure>
        </ns1:RequestHeader>
    </s11:Header>
    <s11:Body>
        <ns1:get xmlns:ns1="https://adwords.google.com/api/adwords/o/v201809">
            <ns1:selector>
                <ns1:searchParameters xsi:type="ns1:IdeaTextFilterSearchParameter">
                    <ns1:excluded>red herring</ns1:excluded>
                </ns1:searchParameters>
                <ns1:searchParameters xsi:type="ns1:RelatedToQuerySearchParameter">
                    <ns1:queries>Golang Python Developer job</ns1:queries>
                </ns1:searchParameters>
                <ns1:ideaType>KEYWORD</ns1:ideaType>
                <ns1:requestType>IDEAS</ns1:requestType>
                <ns1:requestedAttributeTypes>KEYWORD_TEXT</ns1:requestedAttributeTypes>
                <ns1:paging xmlns:pagingNamespace="https://adwords.google.com/api/adwords/cm/v201809">
                    <pagingNamespace:startIndex>0</pagingNamespace:startIndex>
                    <pagingNamespace:numberResults>10</pagingNamespace:numberResults>
                </ns1:paging>
            </ns1:selector>
        </ns1:get>
    </s11:Body>
</s11:Envelope>

Here's the response:
    <rval>
        <totalNumEntries>350</totalNumEntries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job ff7b00dd</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job e6e1840a</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 82c86e86</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job c9d9bfc</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 6c9a5ced</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 701f7f82</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 7772720c</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 51428aa5</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job 48fe8ca7</value>
                </value>
            </data>
        </entries>
        <entries>
            <data>
                <key>KEYWORD_TEXT</key>
                <value xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="StringAttribute">
                    <Attribute.Type>StringAttribute</Attribute.Type>
                    <value>golang python developer job ca633710</value>
                </value>
            </data>
        </entries>
    </rval>
</getResponse>

I've expected, that it'll return the same objects, but with understandable texts. That adding like "ca633710" looks too weird. When I send it to my Google AdWords ad group keywords, they are added but with "Low search volume" status.

There's an example https://developers.google.com/adwords/api/docs/guides/targeting-idea-service with good response, but there's no raw SOAP request, that I can try to send.
What I'm doing wrong? And maybe you can provide me with the right SOAP request? 

Jacob Peebles

unread,
Nov 7, 2019, 9:43:23 AM11/7/19
to AdWords API and Google Ads API Forum
I have a question, aside from the help Dmitry is requesting (who I work with) - is there a reliable way to produce these soap requests for these type of troubleshooting exercises without having to bother the forum each time :)

- Jake

Google Ads API Forum Advisor Prod

unread,
Nov 7, 2019, 2:31:18 PM11/7/19
to ja...@getitllc.com, adwor...@googlegroups.com

Hi Jacob,

Thank you for reaching the support. From the shared response, it looks like you are trying to generate the keyword ideas against your test accounts. Please note, using the test accounts to fetch keyword ideas might result in the junk data. For your other concern related to generating SOAP requests, you could use this guide and the code samples from the client libraries for reference while creating SOAP requests to make calls against API. Let us know if you have any additional concerns.

Regards,
Nikisha Patel, Google Ads API Team



ref:_00D1U1174p._5001UMWYhI:ref

Jacob Peebles

unread,
Nov 7, 2019, 4:50:38 PM11/7/19
to AdWords API and Google Ads API Forum
Nikisha,

I very much appreciate you taking the time to respond. However, I have a few more questions and asks:

- Yes we are doing this work against our test API account (I assume you mean the API is in test mode). However, you say 'keyword ideas might result in junk data'...does 'might' mean that we will never get a proper response for keywords in test mode? It would be good to know what to expect (and not to expect)
- If we always get junk back for keywords using the API in test mode...how do we test that our code is working as designed? How do we verify functionality prior to going to production?
- Could you form up the SOAP request as you've been generous enough to do the last two times we've asked? The resource you provided are helpful, and we'll use them however our code is in go and it would be really helpful to get the properly formed SOAP if you could provide it.

Thanks Nikisha,

- Jake

Jacob Peebles

unread,
Nov 8, 2019, 8:11:56 AM11/8/19
to AdWords API and Google Ads API Forum
Hello,

Bumping this back up. It would be really helpful to get answers to our questions as well as the get the sample SOAP request Dmitry is asking for.

Thanks again for the assistance.

- Jake

Google Ads API Forum Advisor Prod

unread,
Nov 8, 2019, 11:00:28 AM11/8/19
to ja...@getitllc.com, adwor...@googlegroups.com

Hello Jacob,

Please find my response to your queries below for further clarification.

  • Yes we are doing this work against our test API account (I assume you mean the API is in test mode): By making call against the test account means you are making an API call against the accounts that are not actually serving ads. Please refer to this guide for more information related to the test accounts.

  • However, you say 'keyword ideas might result in junk data'...does 'might' mean that we will never get a proper response for keywords in test mode? It would be good to know what to expect (and not to expect): Yes, you are right. When using the test accounts, the TargetingIdeaService will return dummy data for keyword ideas. 

  • If we always get junk back for keywords using the API in test mode...how do we test that our code is working as designed? How do we verify functionality prior to going to production? When retrieving targeting ideas against a production account, you will be able to compare the results to those from the Keyword Planner as mentioned here

  • Could you form up the SOAP request as you've been generous enough to do the last two times we've asked? The resource you provided are helpful, and we'll use them however our code is in go and it would be really helpful to get the properly formed SOAP if you could provide it: The SOAP request call made against the test account looks perfect. The similar SOAP request shared for investigation could be used to make calls against the production account to retrieve the targeting ideas. If you have difficulty making calls to the production account, please share the complete logs along with the client customer id privately for me to investigate further and assist you better.

Reply all
Reply to author
Forward
0 new messages