%PDF- %PDF-
Direktori : /proc/self/root/usr/local/share/man/man3/ |
Current File : //proc/self/root/usr/local/share/man/man3/cPanel::PublicAPI::WHM.3pm |
.\" Automatically generated by Pod::Man 2.22 (Pod::Simple 3.13) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .ie \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . nr % 0 . rr F .\} .el \{\ . de IX .. .\} .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "cPanel::PublicAPI::WHM 3" .TH cPanel::PublicAPI::WHM 3 "2011-03-04" "perl v5.10.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" cPanel::PublicAPI::WHM \- Legacy interface for querying WHM. .PP NOTE: This module is provided for legacy purposes, cPanel::PublicAPI should be used instead .SH "DESCRIPTION" .IX Header "DESCRIPTION" This module provides legacy compatibility support between cPanel::PublicAPI and Cpanel::Accounting (distributed with cPanel). This should never be used unless there is a very good reason to use it (such as having a script that uses Cpanel::Accounting). .SH "functions" .IX Header "functions" .ie n .SS """simple_get_whmreq()""" .el .SS "\f(CWsimple_get_whmreq()\fP" .IX Subsection "simple_get_whmreq()" This function makes a \s-1HTTP\s0 \s-1GET\s0 query to \s-1WHM\s0, an equivalent function within cPanel::PublicAPI is \f(CW\*(C`api_request()\*(C'\fR. This function uses two arrays to specify arguments to be passed to a specific \s-1URI\s0. This means that you would need to ensure that they both have the key/pair values in the same place in each array, f.ex: .PP .Vb 2 \& $argref = [\*(Aqvalue1\*(Aq, \*(Aqvalue2\*(Aq, \*(Aqvalue3\*(Aq]; \& $argnameref = [\*(Aqkey1\*(Aq, \*(Aqkey2\*(Aq, \*(Aqkey3\*(Aq]; .Ve .PP would be be specifying: .PP .Vb 1 \& key1=value1&key2=value2&key3=value3 .Ve .PP to be passed to the specified \s-1URI\s0. .PP Arguments .IP "\(bu" 4 \&\f(CW$uri\fR \- The \s-1URI\s0 you to be queried. .IP "\(bu" 4 \&\f(CW$argref\fR \- An array reference containing the values to be passed. .IP "\(bu" 4 \&\f(CW$argnameref\fR \- An array reference containing the keys to be passed. .IP "\(bu" 4 \&\f(CW$opts\fR \- An array reference containing strings like 'key1=value1' to be passed to the \s-1URI\s0. .PP This will return a scalar reference of the data returned by cpsrvd. .ie n .SS """simple_post_whmreq()""" .el .SS "\f(CWsimple_post_whmreq()\fP" .IX Subsection "simple_post_whmreq()" This function makes a \s-1HTTP\s0 \s-1POST\s0 query to \s-1WHM\s0, an equivalent function within cPanel::PublicAPI is \f(CW\*(C`api_request()\*(C'\fR. This function uses two arrays to specify arguments to be passed to a specific \s-1URI\s0. This means that you would need to ensure that they both have the key/pair values in the same place in each array, f.ex: .PP .Vb 2 \& $argref = [\*(Aqvalue1\*(Aq, \*(Aqvalue2\*(Aq, \*(Aqvalue3\*(Aq]; \& $argnameref = [\*(Aqkey1\*(Aq, \*(Aqkey2\*(Aq, \*(Aqkey3\*(Aq]; .Ve .PP would be be specifying: .PP .Vb 1 \& key1=value1&key2=value2&key3=value3 .Ve .PP to be passed to the specified \s-1URI\s0. .PP Arguments .IP "\(bu" 4 \&\f(CW$uri\fR \- The \s-1URI\s0 you to be queried. .IP "\(bu" 4 \&\f(CW$argref\fR \- An array reference containing the values to be passed. .IP "\(bu" 4 \&\f(CW$argnameref\fR \- An array reference containing the keys to be passed. .IP "\(bu" 4 \&\f(CW$opts\fR \- An array reference containing strings like 'key1=value1' to be passed to the \s-1URI\s0. .PP This will return a scalar containing the data returned by cpsrvd. .ie n .SS """whmreq()""" .el .SS "\f(CWwhmreq()\fP" .IX Subsection "whmreq()" This function is used to querying \s-1WHM\s0 with either \s-1GET\s0 or \s-1POST\s0 data. .IP "\(bu" 4 \&\f(CW$uri\fR \- The \s-1URI\s0 to be queried. .IP "\(bu" 4 \&\f(CW$method\fR \- The method of querying the \s-1URI\s0 (either \s-1GET\s0 or \s-1POST\s0). .IP "\(bu" 4 \&\f(CW$formdata\fR \- The data to be passed to the \s-1URI\s0 formatted as formdata (e.g. 'key1=value1&key2=value2'). .ie n .SS """api1()""" .el .SS "\f(CWapi1()\fP" .IX Subsection "api1()" This function is used to query cPanel's \s-1API1\s0. This will return the \s-1XML\s0 response from the \s-1XML\s0 \s-1API\s0's cpanel call. .IP "\(bu" 4 \&\f(CW$user\fR \- The user to execute an \s-1API\s0 call for. .IP "\(bu" 4 \&\f(CW$module\fR \- The module of the \s-1API\s0 call to be executed. .IP "\(bu" 4 \&\f(CW$func\fR \- The name of the \s-1API\s0 call to be executed. .IP "\(bu" 4 \&\f(CW@params\fR \- An array containing the parameters for the \s-1API\s0 call. .ie n .SS """api2()""" .el .SS "\f(CWapi2()\fP" .IX Subsection "api2()" This function is used to query cPanel's \s-1API1\s0. This will return the \s-1XML\s0 response from the \s-1XML\s0 \s-1API\s0's cpanel call. .IP "\(bu" 4 \&\f(CW$user\fR \- The user to execute an \s-1API\s0 call for. .IP "\(bu" 4 \&\f(CW$module\fR \- The module of the \s-1API\s0 call to be executed. .IP "\(bu" 4 \&\f(CW$func\fR \- The name of the \s-1API\s0 call to be executed. .IP "\(bu" 4 \&\f(CW%params\fR \- An hash containing the parameters for the \s-1API\s0 call. .SH "Bugs" .IX Header "Bugs" see http://rt.cpan.org to report and view bugs .SH "License" .IX Header "License" Copyright (c) 2011, cPanel, Inc. All rights reserved. http://cpanel.net .PP Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of cPanel, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. .PP \&\s-1THIS\s0 \s-1SOFTWARE\s0 \s-1IS\s0 \s-1PROVIDED\s0 \s-1BY\s0 \s-1THE\s0 \s-1COPYRIGHT\s0 \s-1HOLDERS\s0 \s-1AND\s0 \s-1CONTRIBUTORS\s0 \*(L"\s-1AS\s0 \s-1IS\s0\*(R" \s-1AND\s0 \&\s-1ANY\s0 \s-1EXPRESS\s0 \s-1OR\s0 \s-1IMPLIED\s0 \s-1WARRANTIES\s0, \s-1INCLUDING\s0, \s-1BUT\s0 \s-1NOT\s0 \s-1LIMITED\s0 \s-1TO\s0, \s-1THE\s0 \s-1IMPLIED\s0 \&\s-1WARRANTIES\s0 \s-1OF\s0 \s-1MERCHANTABILITY\s0 \s-1AND\s0 \s-1FITNESS\s0 \s-1FOR\s0 A \s-1PARTICULAR\s0 \s-1PURPOSE\s0 \s-1ARE\s0 \&\s-1DISCLAIMED\s0. \s-1IN\s0 \s-1NO\s0 \s-1EVENT\s0 \s-1SHALL\s0 \s-1BE\s0 \s-1LIABLE\s0 \s-1FOR\s0 \s-1ANY\s0 \&\s-1DIRECT\s0, \s-1INDIRECT\s0, \s-1INCIDENTAL\s0, \s-1SPECIAL\s0, \s-1EXEMPLARY\s0, \s-1OR\s0 \s-1CONSEQUENTIAL\s0 \s-1DAMAGES\s0 (\s-1INCLUDING\s0, \s-1BUT\s0 \s-1NOT\s0 \s-1LIMITED\s0 \s-1TO\s0, \s-1PROCUREMENT\s0 \s-1OF\s0 \s-1SUBSTITUTE\s0 \s-1GOODS\s0 \s-1OR\s0 \s-1SERVICES\s0; \&\s-1LOSS\s0 \s-1OF\s0 \s-1USE\s0, \s-1DATA\s0, \s-1OR\s0 \s-1PROFITS\s0; \s-1OR\s0 \s-1BUSINESS\s0 \s-1INTERRUPTION\s0) \s-1HOWEVER\s0 \s-1CAUSED\s0 \s-1AND\s0 \&\s-1ON\s0 \s-1ANY\s0 \s-1THEORY\s0 \s-1OF\s0 \s-1LIABILITY\s0, \s-1WHETHER\s0 \s-1IN\s0 \s-1CONTRACT\s0, \s-1STRICT\s0 \s-1LIABILITY\s0, \s-1OR\s0 \s-1TORT\s0 (\s-1INCLUDING\s0 \s-1NEGLIGENCE\s0 \s-1OR\s0 \s-1OTHERWISE\s0) \s-1ARISING\s0 \s-1IN\s0 \s-1ANY\s0 \s-1WAY\s0 \s-1OUT\s0 \s-1OF\s0 \s-1THE\s0 \s-1USE\s0 \s-1OF\s0 \s-1THIS\s0 \&\s-1SOFTWARE\s0, \s-1EVEN\s0 \s-1IF\s0 \s-1ADVISED\s0 \s-1OF\s0 \s-1THE\s0 \s-1POSSIBILITY\s0 \s-1OF\s0 \s-1SUCH\s0 \s-1DAMAGE\s0.