I am attempting to access a web service using SOAP through Perl and am having issues calling the service\'s functions that require parameters. The XSD that dictates the SOAP cal
You can use wsdl2perl.pl to generate client stub code from wsdl. This makes things pretty easy. wsdl2perl.pl is part of SOAP::WSDL. Here is the sample code after you have generates client stub.
use MyInterfaces::SoapImplService::SoapPort;
my $soap = MyInterfaces::SoapImplService::SoapPort->new();
#calling method createRecipient which takes 2 parameterss:
#1. Complex type : recipient
#2. Complex type : authentication
my $response=$soap->createRecipient( { # MyTypes::createRecipient
recipient => { # MyTypes::Recipient
address => "test701\@test.com", # string
externalID => "test701\@test.com", # string
sourceDescription => "testing perl", # string
demographics => { # MyTypes::StringCollection
},
},
},,
{ # MyTypes::authentication
username=>'testuser' , password=>'pass'
},,
);
#you can find example code of calling every function in your "MyInterfaces\SoapImplService\SoapPort.pm" file.