Merge pull request #602 from kiwix/zerocount_catalog_query_doc_update

This commit is contained in:
Matthieu Gautier 2023-02-10 19:46:51 +01:00 committed by GitHub
commit 0059c6a213
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -214,17 +214,17 @@ By default, no more than 10 first entries are returned from the library. To
obtain the remaining entries the URL query parameters ``start`` and/or obtain the remaining entries the URL query parameters ``start`` and/or
``count`` must be used. The output of ``/catalog/v2/entries?start=s&count=n`` ``count`` must be used. The output of ``/catalog/v2/entries?start=s&count=n``
will contain at most ``n`` (default value: 10) results starting from entry # will contain at most ``n`` (default value: 10) results starting from entry #
``s`` (default value: 0). ``count`` with a non-positive value (e.g. ``s`` (default value: 0). ``count`` with a negative value (e.g. ``count=-1``)
``count=0`` or ``count=-1``) removes the limit on the number of results in the removes the limit on the number of results in the output.
output.
.. note:: .. note::
Usage of ``count=0`` to designate an unbounded query is *DEPRECATED*. Soon Previously ``count=0`` also designated an unbounded query (i.e. worked
the response to a ``count=0`` query will be changed to consist of 0 results. similarly to ``count=-1``). The response to a ``count=0`` query was changed
Such a response is still useful since it contains information about the total to consist of 0 results, as such a query/response combination is a good way
number of results. to find out the total number of results (when only that information is
needed) with minimal consumption of resources.
Examples: Examples: