Mail::Karmasphere::Client - Client for Karmasphere Reputation Server
use Mail::Karmasphere::Client qw(:all); my $client = new Mail::Karmasphere::Client( PeerAddr => '123.45.6.7', PeerPort => 8666, ); my $query = new Mail::Karmasphere::Query(); $query->identity('123.45.6.7', IDT_IP4_ADDRESS); $query->combiner('karmasphere.emailchecker'); my $response = $client->ask($query); print $response->as_string; my $response = $client->query(...);
The Perl Karma Client API consists of three objects: The Query, the Response and the Client. The user constructs a Query and passes it to a Client, which returns a Response.
The class method new(...) constructs a new Client object. All arguments are optional. The following parameters are recognised as arguments to new():
The IP address or hostname to contact. See IO::Socket::INET. The default is 'slave.karmasphere.com'.
The TCP or UDP to contact. See IO::Socket::INET. The default is 8666.
Either 'udp' or 'tcp'. The default is 'udp' because it is faster.
Set to 1 to enable some wire-level debugging.
Returns a Mail::Karmasphere::Response to a Mail::Karmasphere::Query.
A convenience method, equivalent to
$client->ask(new Mail::Karmasphere::Query(...));
See Mail::Karmasphere::Query for more details.
Identity type constants.
This document is incomplete.
Mail::Karmasphere::Query Mail::Karmasphere::Response http://www.karmasphere.com/
Copyright (c) 2005 Shevek, Karmasphere. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install Mail::Karmasphere::Client, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Mail::Karmasphere::Client
CPAN shell
perl -MCPAN -e shell install Mail::Karmasphere::Client
For more information on module installation, please visit the detailed CPAN module installation guide.