Documentation Error: GET /queries
Parameter Should Be length
, Not n
#2403
Labels
GET /queries
Parameter Should Be length
, Not n
#2403
Versions
/ # pihole -v Core version is v6.0.6 (Latest: v6.0.6) Web version is v6.1 (Latest: v6.1) FTL version is v6.1 (Latest: v6.1)
Platform
Debian GNU/Linux 12 (bookworm) x86_64
Expected behavior
The documentation for the "GET /queries" endpoint should indicate that the parameter controlling the number of queries returned is
length
.Actual behavior / bug
The current documentation incorrectly states that the parameter is
n
, even though the endpoint expectslength
. This discrepancy can lead to confusion when developers use the documented parameter.Steps to reproduce
Steps to reproduce the behavior:
n
.n
in a client, and observe that the endpoint requires the parameter to belength
.Screenshots
Additional context
I maintain a small Python client for the Pi-hole API. A user recently reported this issue to me. I patched my client to accept both
n
(deprecated) andlength
for backwards compatibility. Here is a link to the commit where the patch was applied.It would be great if the documentation could be updated to reflect the correct parameter name (
length
) to avoid further confusion.The text was updated successfully, but these errors were encountered: