From 99f39c323e32832944de93449c99f68dcb063ac7 Mon Sep 17 00:00:00 2001 From: Jackson Date: Fri, 31 Jan 2025 10:59:53 +0100 Subject: [PATCH] rewrite return section of docs for query api --- synadm/api.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/synadm/api.py b/synadm/api.py index 05c8fe8..b6061f2 100644 --- a/synadm/api.py +++ b/synadm/api.py @@ -137,11 +137,10 @@ def query( values) and passed to Python's str.format. Returns: - string or None: Usually a JSON string containing - the response of the API; responses that are not 200(OK) (usally - error messages returned by the API) will also be returned as - JSON strings. On exceptions the error type and description are - logged and None is returned. + A dict, list or None. If it's a dict or list, it is a JSON + decoded response. Whether it is a dict or a list depends on what + the server responds with. It returns a None if any exceptions + are encountered. """ args = [urllib.parse.quote(arg, safe="") for arg in args] kwargs = {k: urllib.parse.quote(v, safe="") for k, v in kwargs.items()}