Perl SessionID

From Rackspace Email & Apps API
Revision as of 15:57, 25 August 2008 by APIAdmin (talk | contribs) (New page: == Getting a SessionID == <nowiki> #!/usr/bin/perl -w</nowiki><br> <br> use strict "vars";<br> use warnings;<br> use SOAP::Lite;<br> <br> <nowiki>my $service = "https://secure.webmail.us/s...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Getting a SessionID

#!/usr/bin/perl -w

use strict "vars";
use warnings;
use SOAP::Lite;

my $service = "https://secure.webmail.us/soap/soap_server.php?wsdl";

my $resellerUsername = "myadminuser";
my $resellerPassword = "somepassword";

my $hostName = "mydomain.com";
my $userID = "someperson";
my $sessionID = "";

my @results = SOAP::Lite
  -> service($service)
  -> LoginUserWebmail($resellerUsername, $resellerPassword, $hostName, $userID, $sessionID);

print $results[0]." is the result code\n";
print "\n";
print $results[1]." is the SessionID\n";
print "\n";