Loading ...
Sorry, an error occurred while loading the content.

3424Creating client SOAP request with not too complex structure

Expand Messages
  • B
    Mar 17, 2004
    • 0 Attachment
      Hi, how can I create the following request with SOAP::Lite?

      ...
      <SOAP-ENV:Body>
      <m:getAvailableFieldNames xmlns:m="v2"
      SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
      <reportOptions xsi:type="m0:ReportOptions">
      <dataSource xsi:type="xsd:string">MyDataSourceString</dataSource>
      </reportOptions>
      </m:getAvailableFieldNames>
      </SOAP-ENV:Body>
      ...

      My attempt (that fails) is:
      my $fields = SOAP::Lite
      -> service ("http://$server/services/v2/$wsdl")
      -> getAvailableFieldNames( SOAP::Data->name(dataSource => "$ds") ) ;

      which produces:
      ...
      <SOAP-ENV:Body>
      <namesp1:getAvailableFieldNames xmlns:namesp1="v2">
      <dataSource xsi:type="xsd:string">MyDataSourceString</dataSource>
      </namesp1:getAvailableFieldNames>
      </SOAP-ENV:Body></SOAP-ENV:Envelope>
      SOAP::Transport::HTTP::Client::send_receive:
      HTTP::Response=HASH(0x2b0f574)
      SOAP::Transport::HTTP::Client::send_receive: HTTP/1.1 500 Internal
      Server Error

      I've read lots of SOAP::Lite documentation etc, but can't seem to
      figure out how to use more complex objects...

      Any help appreciated,
      Bjorn
    • Show all 2 messages in this topic