Sam Ruby (a smart honest guy with a big heart who is overworked): On SOAP-bashing. [The following example] is not only WSDL compliant and but it also actually works with the live Google server.
<SOAP:Envelope
xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP:Body>
<gs:doGoogleSearch xmlns:gs="urn:GoogleSearch">
<key>00000000000000000000000000000000</key>
<q>absurd obfuscation</q>
<start>0</start>
<maxResults>10</maxResults>
<filter>true</filter>
<restrict/>
<safeSearch>false</safeSearch>
<lr/>
<ie>latin1</ie>
<oe>latin1</oe>
</gs:doGoogleSearch>
</SOAP:Body>
</SOAP:Envelope>
Sam asks for someone to run the same search through the XML-RPC Google gateway. Here is a working request generated by a modified version of xmlrpclib.py, hacked to produce optimized output. (Don’t specify string datatype; use short form for empty XML tags.) Please note that the XML-RPC gateway is missing one parameter (filter, for filtering out duplicate pages), so the number of parameters doesn’t match the SOAP call.
<methodCall>
<methodName>googleGateway.search</methodName>
<params>
<param>
<value>absurd obfuscation</value>
</param>
<param>
<value>
<int>0</int>
</value>
</param>
<param>
<value>
<int>10</int>
</value>
</param>
<param>
<value/>
</param>
<param>
<value/>
</param>
<param>
<value>
<boolean>0</boolean>
</value>
</param>
<param>
<value>latin1</value>
</param>
<param>
<value>latin1</value>
</param>
<param>
<value>00000000000000000000000000000000</value>
</param>
</params>
</methodCall>
§
I am no longer accepting public comments on this post, but you can use this form to contact me privately. (Your message will not be published.)
§
firehose ‧ code ‧ music ‧ planet
© 2001-8 Mark Pilgrim