A SOAPpy question... (Method Parameters)

Discussion in 'Python' started by giblfiz@gmail.com, Apr 22, 2005.

  1. Guest

    I'm having difficulty sending out correctly named method parameters to
    a php soap server that I am running using SOAPpy. Idealy I would like
    to send XML that looks like this (which I cribbed from another client
    that works just fine)


    <SOAP-ENV:Body>
    <ns1:login xmlns:ns1="http://testuri.org">
    <user_auth>
    <user_name xsi:type="xsd:string">
    hpottash
    </user_name>

    <password xsi:type="xsd:string">
    775fd0ac8dcdba0f307e8a2a474f9dce
    </password>
    <version xsi:type="xsd:string">
    .01
    </version>
    </user_auth>
    <application_name xsi:type="xsd:string">
    SoapTest
    </application_name>
    </ns1:login>
    </SOAP-ENV:Body>


    The closest I can come with SOAPpy is by running the following >>>
    remote = SOAPpy.SOAPProxy("http://192.168.0.200/",
    "http://testuri.org")
    remote.login({"user_auth": {'user_name': 'theusername', 'password':
    'thepassword', "version" : ".01"}, "application_name":"SoapTest"});

    Which generates XML that looks like this:
    <SOAP-ENV:Body>
    <ns1:login xmlns:ns1="http://testuri.org" SOAP-ENC:root="1">
    <v1>
    <application_name xsi:type="xsd:string">
    SoapTest
    </application_name>
    <user_auth>
    <password xsi:type="xsd:string">
    thepassword
    </password>
    <user_name xsi:type="xsd:string">
    theusername
    </user_name>
    <version xsi:type="xsd:string">
    .01
    </version>
    </user_auth>
    </v1>
    </ns1:login>
    </SOAP-ENV:Body>

    I believe that the Server is unable to parse this correctly because of
    the <v1> tag, but I don't know how to specify what the names of the
    parameters that are passed to the method should be.

    Any help would be deeply appreciated.
    -Harry
    , Apr 22, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jim
    Replies:
    1
    Views:
    745
    bruno modulix
    Apr 14, 2005
  2. Bartas
    Replies:
    0
    Views:
    1,105
    Bartas
    Oct 5, 2005
  3. Steve
    Replies:
    0
    Views:
    458
    Steve
    Dec 6, 2006
  4. D Unit

    SOAPpy parameters in sequence

    D Unit, May 7, 2007, in forum: Python
    Replies:
    0
    Views:
    324
    D Unit
    May 7, 2007
  5. D Unit
    Replies:
    0
    Views:
    408
    D Unit
    May 7, 2007
Loading...

Share This Page