Net::Fluidinfo - A Perl interface to Fluidinfo
use Net::Fluidinfo; # Predefined Fluidinfo client for playing around, points # to the sandbox with user test/test $fin = Net::Fluidinfo->new_for_testing; $fin = Net::Fluidinfo->new_for_testing(trace_http => 1); # Fluidinfo client pointing to production $fin = Net::Fluidinfo->new(username => 'username', password => 'password'); # Fluidinfo taking credentials from environment variables # FLUIDINFO_USERNAME and FLUIDINFO_PASSWORD $fin = Net::Fluidinfo->new; # Content-MD5 headers with checksums for requests with payload $fin = Net::Fluidinfo->new(md5 => 1) # Resource getters $object = $fin->get_object_by_id($id, about => 1); $object = $fin->get_object_by_about($about); $ns = $fin->get_namespace($path, description => 1); $tag = $fin->get_tag($path, description => 1); $permission = $fin->get_permission($category, $path_or_has_path, $action); $user = $fin->get_user($username); # Object search @ids = $fin->search("has fxn/rating");
Net::Fluidinfo provides an interface to the Fluidinfo API.
Net::Fluidinfo
The documentation of Net::Fluidinfo does not explain Fluidinfo, though there are links to relevant pages in the documentation of each class.
If you want to get familiar with Fluidinfo please check these pages:
http://doc.fluidinfo.com/fluidDB/
http://doc.fluidinfo.com/fluidDB/api/
http://api.fluidinfo.com/fluidDB/api/*/*/*
http://blogs.fluidinfo.com/fluidDB/category/essence/
Returns an object for communicating with Fluidinfo.
This is a wrapper around LWP::UserAgent and does not validate credentials in the very constructor. If they are wrong requests will fail when performed.
Attributes and options are:
Your username in Fluidinfo. If not present uses the value of the environment variable FLUIDINFO_USERNAME.
Your password in Fluidinfo. If not present uses the value of the environment variable FLUIDINFO_PASSWORD.
Either 'HTTP' or 'HTTPS'. Defaults to 'HTTP'.
The Fluidinfo host. Defaults to fluiddb.fluidinfo.com.
If this flag is true requests with payload get a Content-MD5 header with a checksum.
A flag, logs all HTTP requests if true.
A flag, logs all HTTP responses if true.
A flag, logs all HTTP requests and responses if true. (Shorthand for enabling the two above.)
Returns a Net::Fluidinfo instance pointing to the sandbox with "test"/"test". The host of the sandbox can be checked in the package variable $Net::Fluidinfo::SANDBOX_HOST.
$Net::Fluidinfo::SANDBOX_HOST
Gets/sets the username.
Gets/sets the password.
Gets/sets the protocol, either 'HTTP' or 'HTTPS'.
Returns the instance of LWP::UserAgent used to communicate with Fluidinfo.
Returns the user on behalf of whom fin is doing calls. This attribute is lazy loaded.
Convenience shortcut for Net::Fluidinfo::Object::get_by_id, see Net::Fluidinfo::Object.
Net::Fluidinfo::Object::get_by_id
Convenience shortcut for Net::Fluidinfo::Object::get_by_about, see Net::Fluidinfo::Object.
Net::Fluidinfo::Object::get_by_about
Convenience shortcut for Net::Fluidinfo::Object::search, see Net::Fluidinfo::Object.
Net::Fluidinfo::Object::search
Convenience shortcut for Net::Fluidinfo::Namespace::get, see Net::Fluidinfo::Namespace.
Net::Fluidinfo::Namespace::get
Convenience shortcut for Net::Fluidinfo::Tag::get, see Net::Fluidinfo::Tag.
Net::Fluidinfo::Tag::get
Convenience shortcut for Net::Fluidinfo::Permission::get, see Net::Fluidinfo::Permission.
Net::Fluidinfo::Permission::get
Convenience shortcut for Net::Fluidinfo::User::get, see Net::Fluidinfo::User.
Net::Fluidinfo::User::get
Xavier Noria (FXN), <fxn@cpan.org>
Copyright (C) 2009-2012 Xavier Noria
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.
1 POD Error
The following errors were encountered while parsing the POD:
You forgot a '=back' before '=head1'
To install Net::Fluidinfo, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::Fluidinfo
CPAN shell
perl -MCPAN -e shell install Net::Fluidinfo
For more information on module installation, please visit the detailed CPAN module installation guide.