[Koha] API paging, userid patron query

Lari Taskula lari.taskula at hypernova.fi
Thu Aug 31 08:47:15 NZST 2023


Hi,

See https://api.koha-community.org/#tag/patrons/operation/listPatrons

Especially query parameters _page and _per_page.

If you suspect there may be more results than 12, you can find the total 
number of results in response headers. X-Total-Count header containing 
the total results count, and X-Base-Total-Count header containing the 
total of the non-filtered results count.

Lari Taskula
CEO, Hypernova Oy
PL 16
80101 Joensuu, Finland

On 30.8.2023 22.16, Eric Phetteplace wrote:
> Hi collective wisdom,
>
> Are there secret paging parameters for the Koha REST API? I don't see any
> in the documentation.
>
> Specifically, I'm using the list patrons route like
> /api/v1/patrons?userid={query} but I have a username that is short and a
> subset of many other usernames. The API returns 12 results and the user
> account, which I can see exists, is not included amongst them. I'm
> wondering if I need to page through more results, but blind guessing of
> parameters like "page", "offset", and "start" only leads to "malformed
> query string" errors.
>
> Best,
>
> ERIC PHETTEPLACE Systems Librarian, Libraries (he/him)
>
> ephetteplace at cca.edu
>
>
> *CCA is situated on the traditional unceded lands of the **Chochenyo and
> Ramaytush Ohlone** peoples.*
>
> Black-owned bookstores in Oakland: Ashay by the Bay
> <https://ashaybythebay.com/>, Marcus Books
> <https://www.facebook.com/marcus.books/>
>
> :(){ :|: & };:
> _______________________________________________
>
> Koha mailing list  http://koha-community.org
> Koha at lists.katipo.co.nz
> Unsubscribe: https://lists.katipo.co.nz/mailman/listinfo/koha

-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <https://lists.katipo.co.nz/pipermail/koha/attachments/20230830/057a1af1/attachment.sig>


More information about the Koha mailing list