472,985 Members | 2,942 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,985 software developers and data experts.

SOAPpy / WSDL help... please

I have an Adobe InDesign server running that includes a built-in SOAP
server. The wsdl is located here:
http://www.seanberry.com/IDSP.wsdl.

I have a PHP example that looks like this for calling the SOAP
function runScriptParameters

//---------------------------------------------------------------------------
$scriptArgs = array();
$scriptArgs[] = array("name" ="myVarName", "value" ="myVarValue");
$scriptArgs[] = array("name" ="myVarName2", "value" =>
"myVarValue2");
$runScriptParams = array( "scriptFile" ="/some/path/to/file.jsx",
"scriptArgs" =$scriptArgs, "scriptLanguage" ="javascript");
$scriptData = array("runScriptParameters" =$runScriptParams);
$client = new SoapClient("IDSP.wsdl", $proxy_settings);
$returnedValue = $client->RunScript($scriptData);
//---------------------------------------------------------------------------

This works fine and produces the following as its output XML:
//---------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/
envelope/" xmlns:ns1="http://ns.adobe.com/InDesign/soap/">
<SOAP-ENV:Body>
<ns1:RunScript>
<runScriptParameters>
<scriptLanguage>javascript</scriptLanguage>
<scriptFile>/some/path/to/file.jsx</scriptFile>
<scriptArgs><name>myVarName</name><value>myVarValue</value></
scriptArgs>
<scriptArgs><name>myVarName2</name><value>myVarValue2</value></
scriptArgs>
</runScriptParameters>
</ns1:RunScript>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
---------------------------------------------------------------------------
Now I am writing a client in Python and have tried the following:
//---------------------------------------------------------------------------
#!/usr/bin/python

import SOAPpy

url = "./IDSP.wsdl"

wsdlObject = SOAPpy.WSDL.Proxy(url)
SOAPpy.Config.debug = 1

scriptArgs = []
scriptArgs.append({"name":"myVarName", "value":"myVarValue"})
scriptArgs.append({"name":"myVarName2", "value":"myVarValue2"})
runScriptParams = {}
runScriptParams["scriptFile"] = "/some/path/to/file.jsx"
runScriptParams["scriptLanguage"] = "javascript"
runScriptParams["scriptArgs"] = scriptArgs

result = wsdlObject.RunScript(runScriptParameters=runScript Params)
print result
//---------------------------------------------------------------------------
This errors out and shows the following as the XML.
//---------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope
SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
>
<SOAP-ENV:Body>
<RunScript SOAP-ENC:root="1">
<runScriptParameters>
<scriptArgs SOAP-
ENC:arrayType="ns1:SOAPStruct[2]" xsi:type="SOAP-ENC:Array"
xmlns:ns1="http://soapinterop.org/xsd">
<item>
<name
xsi:type="xsd:string">myVarName</name>
<value
xsi:type="xsd:string">myVarValue</value>
</item>
<item>
<name
xsi:type="xsd:string">myVarName2</name>
<value
xsi:type="xsd:string">myVarValue2</value>
</item>
</scriptArgs>
<scriptLanguage
xsi:type="xsd:string">javascript</scriptLanguage>
<scriptFile xsi:type="xsd:string">/some/
path/to/file.jsx</scriptFile>
</runScriptParameters>
</RunScript>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
//---------------------------------------------------------------------------------

This looks wrong first off because of the RunScript node, but also has
those extra "item" nodes for the scriptArgs instead of each being a
scriptArgs node. Can anyone help? I really need to get this working
and would appreciate any pointers anyone can give.

THANKS!!!

Oct 30 '07 #1
1 3860
On Oct 30, 4:10 pm, sberry <s...@buildingonline.comwrote:
I have an Adobe InDesign server running that includes a built-in SOAP
server. The wsdl is located here:http://www.seanberry.com/IDSP.wsdl.

I have a PHP example that looks like this for calling the SOAP
function runScriptParameters

Sorry, I meant that I was trying to run the SOAP function RunScript...
not runScriptParameters like I posted previously.

Thanks for any help.

Oct 31 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Vivek | last post by:
Hi, Can anyone provide me with sample code that will allow me to use SOAPpy with a WSDL file using HTTP basic authentication? The only thing I've been able to find on the net is...
0
by: Bartas | last post by:
Hi, I'am writting a simple SOAP client in python (2.4) using SOAPpy lib. I've met with this problem: when I want to send a list of complex type using some method from WebService(java,WAS), ...
0
by: benboals | last post by:
Note: this is in reply to a message from August 2 which i found searching for help on my own problem. I couldn't seem to reply to it, but a friend suggested that simply using the same subject...
0
by: Roy Smith | last post by:
I just got SOAPpy 0.11.6 running under Python 2.3.5. I can do some simple stuff like: from SOAPpy import WSDL wsdlFile = 'http://myserver/soap/XPlanner?wsdl' server = WSDL.Proxy(wsdlFile)...
0
by: Steve | last post by:
Hi All, I have a Python script that uses SOAPpy and I'm outputting all of the methods and info about the parameters... I'm having trouble getting information out of the __init__ parameter. ...
1
by: icius | last post by:
Hello all, I am trying to use a web services API with Python and SOAPpy as a client. Some of the method paramters in this web service's WSDL are asking for an "ArrayOfString" type. Here is my...
0
by: marcello lussana | last post by:
Hi, I'm trying to send some xml data to a WSDL server. Here's my code: xmldata = "<oesystem<user login=\"nekhem\" password=\"one5076\" tpoa=\"\"<message id=\"1\"<textTest di messaggio 1...
0
by: pion | last post by:
Hello I'm trying to make a web service client in python, and so to start out, I found this simple example that are supposed to parse an wsdl file using SOAPPy. I'm using Windows and got SOAPPy...
1
by: Christof Winter | last post by:
I am trying to use a webservice with SOAPpy: import SOAPpy intact_wsdl = "http://www.ebi.ac.uk/intact/binary-search-ws/binarysearch?wsdl" intact_serv = SOAPpy.WSDL.Proxy(intact_wsdl) The...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
by: Aliciasmith | last post by:
In an age dominated by smartphones, having a mobile app for your business is no longer an option; it's a necessity. Whether you're a startup or an established enterprise, finding the right mobile app...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.