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

Viewing HTTP requests / XML

Expand Messages
  • pyuergens
    I am writting a SOAP client to connect to a server I have no access too. Is there a way I can view the HTTP request/XML that SOAP:Lite creates. Thanks Paul
    Message 1 of 2 , May 9, 2003
    • 0 Attachment
      I am writting a SOAP client to connect to a server I have no access too. Is
      there a way I can view the HTTP request/XML that SOAP:Lite creates.

      Thanks

      Paul

      here is my code

      #!/usr/bin/perl

      use SOAP::Lite maptype => ();

      my $soap = SOAP::Lite
      -> uri('http://blah.blah.blah/ws/')
      -> on_action( sub{ join '/', 'http://blah.blah.blah/ws/', $_[1] })
      -> proxy('http://blah.blah.blah/v4.asx');

      my $header = SOAP::Header->name(Cons => {
      password => "passwd",
      id => "id.of.my.client.computer"
      })->uri('http://blah.blah.blah/ws/')->prefix('');
      my @params = (
      $header,
      SOAP::Data->name(book => 3),
      SOAP::Data->name(IpAddr => 4)
      );

      my $method = SOAP::Data->name('VerifySession')
      ->attr({xmlns => 'http://blah.blah.blah/ws/'});


      my $result = $soap->call($method => @params);

      if ($result->fault)
      {
      print $result->faultstring;
      }
      else
      {
      print $result->result;
      }
    • Sadanand Kalasabail
      Use trace use SOAP::Lite +trace= all ; This would show every thing - for more details see the guide on www.soaplite.com Regards Sade ...
      Message 2 of 2 , May 11, 2003
      • 0 Attachment
        Use trace
        use SOAP::Lite +trace=>'all';

        This would show every thing - for more details see
        the guide on www.soaplite.com

        Regards
        Sade

        --- pyuergens <pyuergens@...> wrote:
        > I am writting a SOAP client to connect to a server I
        > have no access too. Is
        > there a way I can view the HTTP request/XML that
        > SOAP:Lite creates.
        >
        > Thanks
        >
        > Paul
        >
        > here is my code
        >
        > #!/usr/bin/perl
        >
        > use SOAP::Lite maptype => ();
        >
        > my $soap = SOAP::Lite
        > -> uri('http://blah.blah.blah/ws/')
        > -> on_action( sub{ join '/',
        > 'http://blah.blah.blah/ws/', $_[1] })
        > -> proxy('http://blah.blah.blah/v4.asx');
        >
        > my $header = SOAP::Header->name(Cons => {
        > password => "passwd",
        > id => "id.of.my.client.computer"
        > })->uri('http://blah.blah.blah/ws/')->prefix('');
        > my @params = (
        > $header,
        > SOAP::Data->name(book => 3),
        > SOAP::Data->name(IpAddr => 4)
        > );
        >
        > my $method = SOAP::Data->name('VerifySession')
        > ->attr({xmlns => 'http://blah.blah.blah/ws/'});
        >
        >
        > my $result = $soap->call($method => @params);
        >
        > if ($result->fault)
        > {
        > print $result->faultstring;
        > }
        > else
        > {
        > print $result->result;
        > }
        >
        >


        __________________________________
        Do you Yahoo!?
        The New Yahoo! Search - Faster. Easier. Bingo.
        http://search.yahoo.com
      Your message has been successfully submitted and would be delivered to recipients shortly.