[ic] SOAP access to interchange - logging on
John1
list_subscriber at yahoo.co.uk
Fri Jun 24 15:33:33 EDT 2005
Sorry to keep answering my own posts, but I *really* am stuck this time. :-)
I have basic SOAP working, e.g. $Tag->session_name->result is correctly
returning a session id, but
$Tag->userdb( $login_opt )->result refuses to log me on.
I have "SOAP_Control Tag/userdb always" in both my catalog.cfg and
interchange.cfg, so I guess there must be something wrong with my logon.pl
script (see below). Please can anyone spot the problem - I have stared at
it for hours and tried everything, but just get a "Service not found" error
for the userdb call.
========================
#!/usr/bin/perl
use SOAP::Lite;
#no $cat parameter as catalog is
#accessed at root i.e. www.mydomain.com/
my $host = 'www.mydomain.com';
my $Tag = SOAP::Lite
-> uri("http://$host/Vend/SOAP")
-> proxy("http://$host:7780/")
-> on_debug (sub {print @_});
my $id = $Tag -> session_name ()->result;
my $proxy = "http://$host:7780/$id";
$Tag->proxy($proxy);
my $login_opt = {
username => 'myusername',
password => 'mypassword',
function => 'login'
};
my $ok = $Tag->userdb( $login_opt )->result;
========================
Output showing the error:
...
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode>SOAP-ENV:Client.NotFound</faultcode>
<faultstring>Service not found</faultstring>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
...
More information about the interchange-users
mailing list