summaryrefslogtreecommitdiffstats
path: root/Bugzilla/WebService.pm
diff options
context:
space:
mode:
authorDave Lawrence <dlawrence@mozilla.com>2013-07-15 22:29:01 +0200
committerDave Lawrence <dlawrence@mozilla.com>2013-07-15 22:29:01 +0200
commitcd2f1c38499004485e3a817e8835b2a0ed9266fd (patch)
treebf2da6db834ba19593dc9409e408b8eaa30549e0 /Bugzilla/WebService.pm
parentfb6ef2f23aeda0ba93d97a7e0abd6a21c952fa4f (diff)
downloadbugzilla-cd2f1c38499004485e3a817e8835b2a0ed9266fd.tar.gz
bugzilla-cd2f1c38499004485e3a817e8835b2a0ed9266fd.tar.xz
Bug 892601 - Port over upstream native REST patch (bug 866927) to bmo/4.2
r=glob
Diffstat (limited to 'Bugzilla/WebService.pm')
-rw-r--r--Bugzilla/WebService.pm25
1 files changed, 20 insertions, 5 deletions
diff --git a/Bugzilla/WebService.pm b/Bugzilla/WebService.pm
index 55df8124d..8f97a3a2f 100644
--- a/Bugzilla/WebService.pm
+++ b/Bugzilla/WebService.pm
@@ -52,15 +52,20 @@ This is the standard API for external programs that want to interact
with Bugzilla. It provides various methods in various modules.
You can interact with this API via
-L<XML-RPC|Bugzilla::WebService::Server::XMLRPC> or
-L<JSON-RPC|Bugzilla::WebService::Server::JSONRPC>.
+L<XML-RPC|Bugzilla::WebService::Server::XMLRPC>,
+L<JSON-RPC|Bugzilla::WebService::Server::JSONRPC> or
+L<REST|Bugzilla::WebService::Server::REST>.
=head1 CALLING METHODS
-Methods are grouped into "packages", like C<Bug> for
+Methods are grouped into "packages", like C<Bug> for
L<Bugzilla::WebService::Bug>. So, for example,
L<Bugzilla::WebService::Bug/get>, is called as C<Bug.get>.
+For REST, the "package" is more determined by the path
+used to access the resource. See each relevant method
+for specific details on how to access via REST.
+
=head1 PARAMETERS
The Bugzilla API takes the following various types of parameters:
@@ -142,7 +147,7 @@ There are various ways to log in:
=item C<User.login>
-You can use L<Bugzilla::WebService::User/login> to log in as a Bugzilla
+You can use L<Bugzilla::WebService::User/login> to log in as a Bugzilla
user. This issues standard HTTP cookies that you must then use in future
calls, so your client must be capable of receiving and transmitting
cookies.
@@ -172,13 +177,17 @@ not expire.
=back
The C<Bugzilla_restrictlogin> and C<Bugzilla_rememberlogin> options
-are only used when you have also specified C<Bugzilla_login> and
+are only used when you have also specified C<Bugzilla_login> and
C<Bugzilla_password>.
Note that Bugzilla will return HTTP cookies along with the method
response when you use these arguments (just like the C<User.login> method
above).
+For REST, you may also use the C<username> and C<password> variable
+names instead of C<Bugzilla_login> and C<Bugzilla_password> as a
+convenience.
+
=back
=head1 STABLE, EXPERIMENTAL, and UNSTABLE
@@ -273,6 +282,9 @@ would return something like:
{ users => [{ id => 1, name => 'user@domain.com' }] }
+Note for REST, C<include_fields> may instead be a comma delimited string
+for GET type requests.
+
=item C<exclude_fields>
C<array> An array of strings, representing the (case-sensitive) names of
@@ -302,6 +314,9 @@ would return something like:
{ users => [{ id => 1, real_name => 'John Smith' }] }
+Note for REST, C<exclude_fields> may instead be a comma delimited string
+for GET type requests.
+
=back
=head1 SEE ALSO