GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Metabase::Client::Simple(3) User Contributed Perl Documentation Metabase::Client::Simple(3)
 

Metabase::Client::Simple - a client that submits to Metabase servers

version 0.012

  use Metabase::Client::Simple;
  use Metabase::User::Profile;
  use Metabase::User::Secret;
  my $profile = Metabase::User::Profile->load('user.profile.json');
  my $secret  = Metabase::User::Secret ->load('user.secret.json' );
  my $client = Metabase::Client::Simple->new({
    profile => $profile,
    secret  => $secret,
    uri     => 'http://metabase.example.com/',
  });
  my $fact = generate_metabase_fact;
  $client->submit_fact($fact);

Metabase::Client::Simple provides is extremely simple, lightweight library for submitting facts to a Metabase web server.

  my $client = Metabase::Client::Simple->new(\%arg)
This is the object constructor.
Valid arguments are:
  profile - a Metabase::User::Profile object
  secret  - a Metabase::User::Secret object
  uri     - the root URI for the metabase server
If you use a "uri" argument with the 'https' scheme, you must have IO::Socket::SSL and Net::SSLeay installed. You may also require Mozilla::CA.

  $client->submit_fact($fact);
This method will submit a Metabase::Fact object to the client's server. On success, it will return a true value. On failure, it will raise an exception.

  $client->guid_exists('2f8519c6-24cf-11df-90b1-0018f34ec37c');
This method will check whether the given GUID is found on the metabase server. The GUID must be in lower-case, string form. It will return true or false. Note that a server error will also result in a false value.

  $client->register;
This method will submit the user credentials to the metabase server. It will be called automatically by "submit_fact" if necessary. You generally won't need to use it. On success, it will return a true value. On failure, it will raise an exception.

Please report any bugs or feature requests through the issue tracker at <https://github.com/cpan-testers/Metabase-Client-Simple/issues>. You will be notified automatically of any progress on your issue.

This is open source software. The code repository is available for public review and contribution under the terms of the license.
<https://github.com/cpan-testers/Metabase-Client-Simple>
  git clone https://github.com/cpan-testers/Metabase-Client-Simple.git

David Golden <dagolden@cpan.org>
Ricardo Signes <rjbs@cpan.org>

Alexandr Ciornii <alexchorny@gmail.com>
David Steinbrunner <dsteinbrunner@pobox.com>
James McCoy <vega.james@gmail.com>
Karen Etheridge <ether@cpan.org>

This software is Copyright (c) 2016 by David Golden.
This is free software, licensed under:
  The Apache License, Version 2.0, January 2004
2016-03-03 perl v5.28.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.