Echo::StreamServer::Items - Items API
use Echo::StreamServer::Account; use Echo::StreamServer::Items; use Echo::StreamServer::MuxRequest; my $acct = new Echo::StreamServer::Account($appkey, $secret); my $client = new Echo::StreamServer::Items($acct); # Count EQL Query: Trap StreamServer exceptions. eval { my $cnt = $client->count("scope:http://www.example.com/*"); }; print STDERR "Query Count Failed: $@\n" if ($@); # Search EQL Query: my $results = $client->search("scope:http://www.example.com/*"); my @entries = @{$results->{'entries'}}; # Submit Activity Streams XML document to Echo. my $results = $client->submit($activity_streams_xml); # Send @mux_requests to Echo. my $client = new Echo::StreamServer::Items(); my $mux_resp = $client->mux(@mux_requests);
The Items API is Echo::StreamServer::Items and requires an Echo::StreamServer::Account.
Echo Items API is designed for providing interface for working with items in Activity Streams format. Items API is the core component of the Platform, which allows you to submit items and after that build the various data sets using the Echo Query Language.
count
Count the number of items within a dataset generated by a certain query, using Echo Query Language.
search
Search for items using the Echo Query Language.
submit
Submit items $content in Activity Streams XML format.
$content
mux
This single API call can multiplex items search and count requests. @mux_requests is a list of Echo::StreamServer::MuxRequest objects.
multiplex
@mux_requests
Echo::StreamServer::Account Echo::StreamServer::MuxRequest
Andrew Droffner, <adroffne@advance.net>
Copyright (C) 2012 by Andrew Droffner
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.
To install Echo::StreamServer::KVS, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Echo::StreamServer::KVS
CPAN shell
perl -MCPAN -e shell install Echo::StreamServer::KVS
For more information on module installation, please visit the detailed CPAN module installation guide.