view release on metacpan or search on metacpan
lib/ANSI/Heatmap.pm view on Meta::CPAN
=over 4
=item min_x, max_x ( INT )
Specify the smallest and largest X-axis value to include. If not
provided, defaults to the smallest/largest values passed to C<set>
or C<inc>. Can be used to crop the map or ensure it keeps a fixed
size even if some values are unset.
To make automatic again, set to C<undef>.
lib/ANSI/Heatmap.pm view on Meta::CPAN
=item min_z, max_z ( FLOAT )
Ditto for intensity; useful for keeping a fixed intensity across
multiple heatmaps.
The default C<min_z> value is 0, unless negative intensities are
used.
=item swatch ( STR | ARRAYREF )
Set the colour swatch; see C<swatch> below.
lib/ANSI/Heatmap.pm view on Meta::CPAN
A boolean indicating if the map should be rendered in half-height
mode using special characters. On most terminals, this means the
X and Y axis will be scaled identically.
Off by default.
=item width, height ( INT )
Specify the width/height of the map in characters. Defaults to
using the min_I<axis> and max_I<axis> values to determine the
lib/ANSI/Heatmap.pm view on Meta::CPAN
If width/height is not a nice multiple of the input data and
this flag is set, perform bilinear interpolation (instead of
nearest neighbour). This is a trade off; interpolated data is
blurrier, but retains a linear relationship with the original
data. Off by default.
=back
=head2 set ( X, Y, Z )
view all matches for this distribution
view release on metacpan or search on metacpan
lib/AOLserver/CtrlPort.pm view on Meta::CPAN
Number of seconds after which the client will time out if the
server doesn't send a response.
=item User
User name for control port login defaults to the empty string
for non-protected control ports.
=item Password
Password for control port login defaults to the empty string
for non-protected control ports.
=back
=cut
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Assembla.pm view on Meta::CPAN
has '_client' => (
is => 'ro',
isa => 'LWP::UserAgent',
lazy => 1,
default => sub {
my $self = shift;
return LWP::UserAgent->new;
}
);
lib/API/Assembla.pm view on Meta::CPAN
has 'url' => (
is => 'ro',
isa => 'URI',
lazy => 1,
default => sub {
my $self = shift;
return URI->new('https://www.assembla.com/');
}
);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Basecamp.pm view on Meta::CPAN
);
# DEFAULTS
has '+identifier' => (
default => 'API::Basecamp (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Basecamp.pm view on Meta::CPAN
method PREPARE ($ua, $tx, %args) {
my $headers = $tx->req->headers;
my $url = $tx->req->url;
# default headers
$headers->header('Content-Type' => 'application/json');
# append path suffix
$url->path("@{[$url->path]}.json") if $url->path !~ /\.json$/;
lib/API/Basecamp.pm view on Meta::CPAN
$basecamp->retries;
$basecamp->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 0.
=head2 timeout
$basecamp->timeout;
$basecamp->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$basecamp->url;
$basecamp->url(Mojo::URL->new('https://basecamp.com'));
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/BigBlueButton/Requests.pm view on Meta::CPAN
my $data = $self->_generate_data( 'deleteRecordings', \%params );
return $self->abstract_request( $data );
}
=item B<getdefaultconfigxml($self)>
Retrieve the default config.xml.
SEE MORE L<https://code.google.com/p/bigbluebutton/wiki/API#getDefaultConfigXML>
=cut
sub getdefaultconfigxml {
my ( $self ) = @_;
my $data = $self->_generate_data( 'getDefaultConfigXML' );
return $self->abstract_request( $data );
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/CLI/App/Spec.pm view on Meta::CPAN
=item from_openapi
my $spec = API::CLI::App::Spec->from_openapi(
openapi => $openapi,
name => "myclient",
class => "My::API::CLI", # default API::CLI
);
Returns a L<App::Spec> object from an OpenAPI structure.
=item openapi2appspec
view all matches for this distribution
view release on metacpan or search on metacpan
t/01-test.t view on Meta::CPAN
<nameservera4></nameservera4>
<nameserverentry></nameserverentry>
<nameserverentry2></nameserverentry2>
<nameserverentry3></nameserverentry3>
<nameserverentry4></nameserverentry4>
<package>default</package>
</options>
<rawout>
</rawout>
<status>1</status>
<statusmsg>Account Creation Ok</statusmsg>
t/01-test.t view on Meta::CPAN
<BWLIMIT>unlimited</BWLIMIT>
<CONTACTEMAIL></CONTACTEMAIL>
<CONTACTEMAIL2></CONTACTEMAIL2>
<DEMO>0</DEMO>
<DOMAIN>zse1.ru</DOMAIN>
<FEATURELIST>default</FEATURELIST>
<HASCGI>1</HASCGI>
<IP>192.168.123.208</IP>
<LANG>russian</LANG>
<LOCALE>ru</LOCALE>
<MAXADDON>0</MAXADDON>
t/01-test.t view on Meta::CPAN
<MAXSQL>14</MAXSQL>
<MAXSUB>unlimited</MAXSUB>
<MTIME>1269406519</MTIME>
<MXCHECK-zse1.ru>0</MXCHECK-zse1.ru>
<OWNER>root</OWNER>
<PLAN>default</PLAN>
<RS>x</RS>
<STARTDATE>1269406518</STARTDATE>
<USER>zseasd</USER>
</cpuser>
<domain>zse1.ru</domain>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:18</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>14</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/usr/local/cpanel/bin/noshell</shell>
<startdate>10 Mar 24 11:55</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:21</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:18</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>14</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/false</shell>
<startdate>10 Mar 24 11:55</startdate>
<suspended>1</suspended>
<suspendreason>test reason1</suspendreason>
<suspendtime>1269406521</suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:21</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:18</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:21</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
<maxpop>unlimited</maxpop>
<maxsql>unlimited</maxsql>
<maxsub>unlimited</maxsub>
<owner>root</owner>
<partition>home</partition>
<plan>default</plan>
<shell>/bin/bash</shell>
<startdate>10 Mar 22 16:18</startdate>
<suspended>0</suspended>
<suspendreason>not suspended</suspendreason>
<suspendtime></suspendtime>
t/01-test.t view on Meta::CPAN
$API::CPanel::FAKE_ANSWER = ! $ONLINE ? <<THEEND : undef;
<changepackage>
<result>
<rawout><pre>
Changing bwlimit to unlimited Meg
Changing Feature List to default
Changing max pop accounts from unlimited to unlimited
Changing max sql accounts from 14 to 99
Changing max ftp accounts from unlimited to unlimited
Changing max lists from unlimited to unlimited
Changing max sub domains from unlimited to unlimited
Changing language from ru to en
Changing max parked domains from 0 to 0
Changing max addon domains from 0 to 0
Shell Access Set Correctly (noshell)
Changing cPanel theme from x to
Changing plan from default to Host-343
Resetting QUOTA....
Using Quota v3 Support
Bandwidth limit (0) is lower than (unlimited) (all limits removed)<br /><blockquote><div style='float:left;'>Enabling...</div><div style='float:left;'>...zse1.ru...</div><div style='float:left;'>Done</div&...
</rawout>
<status>1</status>
t/01-test.t view on Meta::CPAN
<package>
<name>Host-1</name>
<BWLIMIT>100</BWLIMIT>
<CGI>y</CGI>
<CPMOD>x3</CPMOD>
<FEATURELIST>default</FEATURELIST>
<FRONTPAGE>n</FRONTPAGE>
<HASSHELL>y</HASSHELL>
<IP>n</IP>
<LANG>ru</LANG>
<MAXADDON>0</MAXADDON>
t/01-test.t view on Meta::CPAN
<package>
<name>Host-2</name>
<BWLIMIT>unlimited</BWLIMIT>
<CGI>y</CGI>
<CPMOD>x3</CPMOD>
<FEATURELIST>default</FEATURELIST>
<FRONTPAGE>n</FRONTPAGE>
<HASSHELL>y</HASSHELL>
<IP>n</IP>
<LANG>en</LANG>
<MAXADDON>0</MAXADDON>
t/01-test.t view on Meta::CPAN
<package>
<name>Host-3</name>
<BWLIMIT>unlimited</BWLIMIT>
<CGI>n</CGI>
<CPMOD></CPMOD>
<FEATURELIST>default</FEATURELIST>
<FRONTPAGE>n</FRONTPAGE>
<HASSHELL>n</HASSHELL>
<IP>n</IP>
<LANG>en</LANG>
<MAXADDON>0</MAXADDON>
t/01-test.t view on Meta::CPAN
<package>
<name>Host-343</name>
<BWLIMIT>unlimited</BWLIMIT>
<CGI>n</CGI>
<CPMOD></CPMOD>
<FEATURELIST>default</FEATURELIST>
<FRONTPAGE>n</FRONTPAGE>
<HASSHELL>n</HASSHELL>
<IP>n</IP>
<LANG>en</LANG>
<MAXADDON>0</MAXADDON>
t/01-test.t view on Meta::CPAN
$result = API::CPanel::Mysql::adddb(
{
%correct_params,
do_as_user => 'zsezse5',
dbname => 'default',
}
);
is( $result, 1, 'API::CPanel::Mysql::adddb');
t/01-test.t view on Meta::CPAN
$result = API::CPanel::Mysql::grant_perms(
{
%correct_params,
do_as_user => 'zsezse5',
dbname => 'zsezse5_default',
dbuser => 'zsezse5_test13',
perms_list => 'all',
}
);
is( $result, 1, 'API::CPanel::Mysql::grant_perms');
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/DeutscheBahn/Fahrplan.pm view on Meta::CPAN
=cut
has 'fahrplan_free_url' => (
is => 'ro',
isa => 'Str',
default => 'https://api.deutschebahn.com/freeplan/v1',
);
has 'fahrplan_plus_url' => (
is => 'ro',
isa => 'Str',
default => 'https://api.deutschebahn.com/fahrplan-plus/v1',
);
has 'access_token' => (
is => 'ro',
isa => 'Str',
lib/API/DeutscheBahn/Fahrplan.pm view on Meta::CPAN
push @args, 'Authorization' => sprintf( 'Bearer %s', $self->access_token )
if $self->access_token;
return HTTP::Tiny->new(
default_headers => {
'Accept' => 'application/json',
'User-Agent' => sprintf( 'Perl-%s::%s', __PACKAGE__, $VERSION ),
@args,
},
);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/DirectAdmin.pm view on Meta::CPAN
# init
my $da = API::DirectAdmin->new(%auth);
my $result = $da->mysql->adddb( {
name => 'default', # will be 'customer_default'
user => 'default', # will be 'customer_default'
passwd => 'password',
passwd2 => 'password',
} );
=item deldb
view all matches for this distribution
view release on metacpan or search on metacpan
bin/drip_client.pl view on Meta::CPAN
Be verbose about something. Specify it more than once to be even more verbose.
=item B<-conf>
Specify the location of a configuration file. Otherwise, defaults to location
specified in the DRIP_CLIENT_CONF environment variable or ~/.drip.conf. Data
in the configuration file must be encoded in YAML format. See
L<API::Drip::Request/"CONFIGURATION"> for the specific data that may be stored.
Each configuration item may also be overriden by setting an environment
bin/drip_client.pl view on Meta::CPAN
use Data::Printer;
use Getopt::Long;
use Pod::Usage;
use Readonly;
my %OPT = ( # Add defaults here.
);
GetOptions( \%OPT,
'help|h|?',
'man',
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Eulerian/EDW/Request.pm view on Meta::CPAN
my ( $class, $method, $url, $headers, $what, $type, $file ) = @_;
my $status = API::Eulerian::EDW::Status->new();
my $endpoint;
my $request;
# Ensure default type
$type = $type || 'application/json';
# Sanity check POST arguments
if( $method eq 'POST' ) {
if( ! ( defined( $what ) && defined( $type ) ) ) {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Facebook.pm view on Meta::CPAN
);
# DEFAULTS
has '+identifier' => (
default => 'API::Facebook (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Facebook.pm view on Meta::CPAN
method PREPARE ($ua, $tx, %args) {
my $headers = $tx->req->headers;
my $url = $tx->req->url;
# default headers
$headers->header('Content-Type' => 'application/json');
# access token parameter
$url->query->merge(access_token => $self->access_token) if $self->access_token;
lib/API/Facebook.pm view on Meta::CPAN
$facebook->retries;
$facebook->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 1.
=head2 timeout
$facebook->timeout;
$facebook->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$facebook->url;
$facebook->url(Mojo::URL->new('https://graph.facebook.com'));
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/GitForge.pm view on Meta::CPAN
=head2 forge_access_token $domain
Return access token for forge at C<$domain>, assumed to be stored
under C<$ENV{XDG_CONFIG_HOME}/gitforge/access_tokens/$domain> where
the environment variable defaults to C<~/.config> if unset.
=head2 remote_forge_info $remote
Look at the URL for git remote C<$remote>, as returned by C<git remote
get-url>, assume that this remote is a git forge, and return the
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Github.pm view on Meta::CPAN
);
# DEFAULTS
has '+identifier' => (
default => 'API::Github (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Github.pm view on Meta::CPAN
method PREPARE ($ua, $tx, %args) {
my $headers = $tx->req->headers;
my $url = $tx->req->url;
# default headers
$headers->header('Content-Type' => 'application/json');
return $self;
}
lib/API/Github.pm view on Meta::CPAN
$github->retries;
$github->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 0.
=head2 timeout
$github->timeout;
$github->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$github->url;
$github->url(Mojo::URL->new('https://api.github.com'));
view all matches for this distribution
view release on metacpan or search on metacpan
=head1 SYNOPSIS
goauth [tokens.json]
By default if will create config.json in current directory
Structure of config will be like
{ "gapi":
{
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Handle.pm view on Meta::CPAN
is => 'rw'
, isa => 'Nour::Config'
, handles => [ qw/config/ ]
, required => 1
, lazy => 1
, default => sub {
require Nour::Config;
return new Nour::Config ( -base => 'config' );
}
);
lib/API/Handle.pm view on Meta::CPAN
is => 'rw'
, isa => 'Nour::Printer'
, handles => [ qw/verbose debug info warn warning error fatal dumper/ ]
, required => 1
, lazy => 1
, default => sub {
my $self = shift;
my %conf = $self->config->{printer} ? %{ $self->config->{printer} } : (
timestamp => 1
, verbose => 1
, dumper => 1
lib/API/Handle.pm view on Meta::CPAN
has _database => (
is => 'rw'
, isa => 'Nour::Database'
, required => 1
, lazy => 1
, default => sub {
my $self = shift;
my %conf = $self->config->{database} ? %{ $self->config->{database} } : (
# default options here
);
%conf = ();
require Nour::Database;
return new Nour::Database ( %conf );
}
lib/API/Handle.pm view on Meta::CPAN
has _json => (
is => 'rw'
, isa => 'JSON::XS'
, lazy => 1
, required => 1
, default => sub {
require JSON::XS;
return JSON::XS->new->utf8->ascii->relaxed;
}
);
has _xml => (
is => 'rw'
, isa => 'XML::TreePP'
, lazy => 1
, required => 1
, default => sub {
require XML::TreePP;
return new XML::TreePP (
output_encoding => 'UTF-8'
, utf8_flag => 1
, attr_prefix => '-'
lib/API/Handle.pm view on Meta::CPAN
has ua => (
is => 'rw'
, isa => 'LWP::UserAgent'
, lazy => 1
, required => 1
, default => sub {
require LWP::UserAgent;
return new LWP::UserAgent;
}
);
has uri => (
is => 'rw'
, isa => 'Str'
, required => 1
, lazy => 1
, default => sub { '' }
);
sub BUILD {
my $self = shift;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/INSEE/Sirene.pm view on Meta::CPAN
my $self = shift;
$self->{'user_agent'} = LWP::UserAgent->new(protocols_allowed => [ 'http', 'https' ]);
$self->{'user_agent'}->agent("Perl API::INSEE::Sirene V$VERSION");
$self->{'user_agent'}->default_header('Accept' => 'application/json');
}
sub _getToken {
my $self = shift;
lib/API/INSEE/Sirene.pm view on Meta::CPAN
}
switch ($response->code) {
case HTTP_OK {
$self->{'token_expiration'} = time + $json_obj->{'expires_in'};
$self->{'user_agent'}->default_header( Authorization => "Bearer $json_obj->{'access_token'}" );
return 0;
}
case HTTP_UNAUTHORIZED { # wrong credentials
return 1 , $json_obj->{'error_description'};
}
lib/API/INSEE/Sirene.pm view on Meta::CPAN
=head1 CONSTANTS
=head2 DEFAULT_MAX_RESULTS
The API's default number of results for each request. You can override it with the C<< setMaxResults >> method. A too big value may impact response time and general performances.
This constant is set to 20 results.
=head2 DEFAULT_TIMEOUT
lib/API/INSEE/Sirene.pm view on Meta::CPAN
$sirene->setMaxResults(30);
=head2 setProxy
You can define which proxy server must be used to send requests. The system's proxy settings are used by default.
$sirene->setProxy('https://myproxy.com:1234');
=head2 setTimeout
view all matches for this distribution
view release on metacpan or search on metacpan
add_database.pl view on Meta::CPAN
my $db_creation_result = API::ISPManager::db::create( {
%connection_params,
name => $db_name,
dbtype => 'MySQL',
dbencoding => 'default',
dbuser => 'newuser',
dbusername => $db_user,
dbpassword => $db_pass,
dbconfirm => $db_pass,
} );
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Instagram.pm view on Meta::CPAN
use API::Instagram::Search;
has client_id => ( is => 'ro', required => 1 );
has client_secret => ( is => 'ro', required => 1 );
has redirect_uri => ( is => 'ro', required => 1 );
has scope => ( is => 'ro', default => sub { 'basic' } );
has response_type => ( is => 'ro', default => sub { 'code' } );
has grant_type => ( is => 'ro', default => sub { 'authorization_code' } );
has code => ( is => 'rw', isa => sub { confess "Code not provided" unless $_[0] } );
has access_token => ( is => 'rw', isa => sub { confess "No access token provided" unless $_[0] } );
has no_cache => ( is => 'rw', default => sub { 0 } );
has _ua => ( is => 'ro', default => sub { Furl->new() } );
has _obj_cache => ( is => 'ro', default => sub { { User => {}, Media => {}, Location => {}, Tag => {}, 'Media::Comment' => {} } } );
has _endpoint_url => ( is => 'ro', default => sub { 'https://api.instagram.com/v1' } );
has _authorize_url => ( is => 'ro', default => sub { 'https://api.instagram.com/oauth/authorize' } );
has _access_token_url => ( is => 'ro', default => sub { 'https://api.instagram.com/oauth/access_token' } );
has _debug => ( is => 'rw', lazy => 1 );
my $instance;
sub BUILD { $instance = shift }
lib/API/Instagram.pm view on Meta::CPAN
C<scope> is the scope of access. See L<http://instagram.com/developer/authentication/#scope>.
C<response_type> and C<granty_type> do no vary. See L<http://instagram.com/developer/authentication/>.
By default, L<API::Instagram> caches created objects to avoid duplications. You can disable
this feature setting a true value to C<no_chace> parameter.
=head2 instance
my $instagram = API::Instagram->instance;
view all matches for this distribution
view release on metacpan or search on metacpan
API/Intis/lib/API/Intis.pm view on Meta::CPAN
BEGIN {
use Exporter ();
use vars qw($VERSION @ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
$VERSION = '1.00';
@ISA = qw(Exporter);
#Give a hoot don't pollute, do not export more than needed by default
@EXPORT = qw();
@EXPORT_OK = qw();
%EXPORT_TAGS = ();
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/MailboxOrg.pm view on Meta::CPAN
our $VERSION = '1.0.2'; # VERSION
has user => ( is => 'ro', isa => Str, required => 1 );
has password => ( is => 'ro', isa => Str, required => 1 );
has token => ( is => 'rwp', isa => Str );
has host => ( is => 'ro', isa => MojoURL["https?"], default => sub { 'https://api.mailbox.org' }, coerce => 1 );
has base_uri => ( is => 'ro', isa => Str, default => sub { 'v1/' } );
has client => (
is => 'ro',
lazy => 1,
isa => MojoUserAgent,
default => sub {
Mojo::UserAgent->new
}
);
sub _load_namespace ($package) {
lib/API/MailboxOrg.pm view on Meta::CPAN
I<(optional)> Default: C</v1>
=item * client
I<(optional)> A C<Mojo::UserAgent> compatible user agent. By default a new object of C<Mojo::UserAgent>
is created.
=item * host
I<(optional)> This is the URL to Mailbox.org API. Defaults to C<https://api.mailbox.org>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Medium.pm view on Meta::CPAN
use Module::Runtime 'use_module';
has 'server' => (
isa => 'Str',
is => 'ro',
default => 'https://api.medium.com/v1',
);
has 'access_token' => (
isa => 'Str',
is => 'rw',
lib/API/Medium.pm view on Meta::CPAN
sub _build__client {
my $self = shift;
return HTTP::Tiny->new(
agent => join( '/', __PACKAGE__, $VERSION ),
default_headers => {
'Authorization' => 'Bearer ' . $self->access_token,
'Accept' => 'application/json',
'Content-Type' => 'application/json',
}
);
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/MikroTik.pm view on Meta::CPAN
=head2 ioloop
my $loop = $api->ioloop;
$api = $api->loop(Mojo::IOLoop->new());
Event loop object to use for blocking operations, defaults to L<Mojo::IOLoop>
object.
=head2 password
my $pass = $api->password;
$api = $api->password('secret');
Password for authentication. Empty string by default.
=head2 port
my $port = $api->port;
$api = $api->port(8000);
lib/API/MikroTik.pm view on Meta::CPAN
=head2 tls
my $tls = $api->tls;
$api = $api->tls(1);
Use TLS for connection. Enabled by default.
=head2 user
my $user = $api->user;
$api = $api->user('admin');
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Name.pm view on Meta::CPAN
);
# DEFAULTS
has '+identifier' => (
default => 'API::Name (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Name.pm view on Meta::CPAN
my $url = $tx->req->url;
my $user = $self->user;
my $token = $self->token;
# default headers
$headers->header('Content-Type' => 'application/json');
$headers->header('Api-Username' => $user);
$headers->header('Api-Token' => $token);
}
lib/API/Name.pm view on Meta::CPAN
$name->retries;
$name->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 0.
=head2 timeout
$name->timeout;
$name->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$name->url;
$name->url(Mojo::URL->new('https://www.name.com'));
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Octopart.pm view on Meta::CPAN
=item * $o->has_stock($part, %opts) - Returns the number of items in stock
$part: The model number of the part
%opts: Optional filters. No defaults are specified, it will return all unless limited.
=over 4
=item * min_qty => <n> - Minimum stock quantity, per seller.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/ParallelsWPB.pm view on Meta::CPAN
=head2 B<f_request($self, $url_array_ref, $data)>
"Free" request. Now for internal usage only.
$data:
req_type : HTTP request type: get, post, put, delete. GET by default.
post_data: data for POST request. Must be hashref.
=head1 SEE ALSO
L<Parallels Presence Builder Guide|http://download1.parallels.com/WPB/Doc/11.5/en-US/online/presence-builder-standalone-installation-administration-guide>
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Plesk.pm view on Meta::CPAN
username
password
url
Additional params:
api_version - default 1.6.3.1
debug - default 0
timeout - default 30 sec.
=item send($operator, $operation, $data, %params)
This method prepare and sends request to Plesk API.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/PleskExpand.pm view on Meta::CPAN
=item new(%params)
Create new class instance.
Required params:
api_version -- default: 2.2.4.1
username -- Expand user name (root as default).
password -- Expand password.
url -- full url to Expand XML RPC gate (https://ip.ad.dr.ess::8442/webgate.php').
=cut
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Stripe.pm view on Meta::CPAN
);
# DEFAULTS
has '+identifier' => (
default => 'API::Stripe (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Stripe.pm view on Meta::CPAN
$content = 'application/x-www-form-urlencoded';
}
# default headers
$headers->header('Content-Type' => $content);
return $self;
}
lib/API/Stripe.pm view on Meta::CPAN
$stripe->retries;
$stripe->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 0.
=head2 timeout
$stripe->timeout;
$stripe->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$stripe->url;
$stripe->url(Mojo::URL->new('https://api.stripe.com'));
view all matches for this distribution
view release on metacpan or search on metacpan
lib/API/Trello.pm view on Meta::CPAN
);
# DEFAULTS
has '+casing' => (
default => 'camelcase',
required => 0,
);
has '+identifier' => (
default => 'API::Trello (Perl)',
required => 0,
);
has '+url' => (
default => $DEFAULT_URL,
required => 0,
);
has '+version' => (
default => 1,
required => 0,
);
# CONSTRUCTION
lib/API/Trello.pm view on Meta::CPAN
method PREPARE ($ua, $tx, %args) {
my $headers = $tx->req->headers;
my $url = $tx->req->url;
# default headers
$headers->header('Content-Type' => 'application/json');
}
method resource (@segments) {
lib/API/Trello.pm view on Meta::CPAN
$trello->retries;
$trello->retries(10);
The retries attribute determines how many times an HTTP request should be
retried if a 4xx or 5xx response is received. This attribute defaults to 0.
=head2 timeout
$trello->timeout;
$trello->timeout(5);
The timeout attribute determines how long an HTTP connection should be kept
alive. This attribute defaults to 10.
=head2 url
$trello->url;
$trello->url(Mojo::URL->new('https://api.trello.com'));
view all matches for this distribution