=====================================
Count Review Requests to Review Group
=====================================

:Path: ``api/json/reviewrequests/to/group/{group_name}/count/``


URL Parameters
==============

+----------------------------+---------+-------------------------------------+
| Parameter                  | Type    | Description                         |
+============================+=========+=====================================+
| group_name                 | String  | The name of the group.              |
+----------------------------+---------+-------------------------------------+


HTTP GET
========

Returns the number of public review requests on the server that have been sent
to the specified review group.


Request Parameters
------------------

+-------------+---------+--------------------------------------------------+
| Parameter   | Type    | Description                                      |
+=============+=========+==================================================+
| **status**  | String  | The status of the review requests to return.     |
| (optional)  |         | This can be one of: ``pending``, ``submitted``,  |
|             |         | ``discarded`` or ``all``. This defaults to       |
|             |         | ``pending``.                                     |
+-------------+---------+--------------------------------------------------+

Example Request
---------------

.. code-block:: none

    GET /api/json/reviewrequests/to/group/reviewboard/count/?status=pending


Responses
---------

HTTP 200: Success
~~~~~~~~~~~~~~~~~

+--------+---------+------------------------------------------------------+
| Field  | Type    | Description                                          |
+========+=========+======================================================+
| count  | Integer | The number of review requests.                       |
+--------+---------+------------------------------------------------------+


Example Response
^^^^^^^^^^^^^^^^

.. code-block:: javascript

    {
      stat: "ok",
      count: 50
    }


HTTP 401: Unauthorized
~~~~~~~~~~~~~~~~~~~~~~

Error 103: Not Logged In
^^^^^^^^^^^^^^^^^^^^^^^^

The client making the request is not logged in and the server disallows
anonymous access.

See :ref:`authenticating` for more information.


.. comment: vim: ft=rst et ts=3
