SAP::WAS::SOAP - SOAP encoded RFC calls against SAP R/3 / Web Application Server (WAS)


# Setup up a service in the SAP WAS server for an RFC-XML based call to RFC_READ_REPORT # called test:ReadReport to make this example work

  use SAP::WAS::SOAP;
  use Data::Dumper;

  my $url = 'http://localhost:8080/sap/bc/soap/rfc';
  my $rfcname = 'RFC_READ_REPORT';

  # build the connecting object
  my $sapsoap = new SAP::WAS::SOAP( URL => $url );

  #  Discover the interface definition for a function module
  my $i = $sapsoap->Iface( $rfcname );

  #  set a parameter value of the interface

  # call the WAS soap service with an interface object
  $sapsoap->soaprfc( $i );

  print "Name:", $i->TRDIR->structure->NAME, "\n";

  print "Array of Code Lines ( a hash per line including struture fieldnames ):\n";
  print Dumper ( $i->Tab('QTAB')->rows );


Enabler for HTTP based SOAP calls to SAP using the WAS ( Web Application Server ) using the ICMAN interface ( SAP's Internet Connection MANager ). You need to ensure that login to the /sap/bc/soap/rfc service has been configured correctly using SAP transaction SICF, first, or this will not work ( under the version 6.10 WAS that I used the only thing I had to change was the settings for the auto login user ) - this corresponds directly to the URL that is supplied to the SAP::WAS::SOAP constructor.


        my $rfc = new SAP::WAS::SOAP( URL => <url to my WAS SOAP interface > );

        my $i = $rfc->Iface( <some RFC name> );

        < set some parameters in the interface object > .....

        $rfc->soaprfc( $i ); # execute the rfc call encoded in SOAP via the WAS


Piers Harding,

But Credit must go to all those that have helped.


perl(1), SAP::WAS::SOAP(3), SAP::WAS::Iface(3)